Commit 14cf702
authored
SNOW-1491199 Generate Protobuf Python code for IR (#2518)
<!---
Please answer these questions before creating your pull request. Thanks!
--->
1. Which Jira issue is this PR addressing? Make sure that there is an
accompanying issue to your PR.
<!---
In this section, please add a Snowflake Jira issue number.
Note that if a corresponding GitHub issue exists, you should still
include
the Snowflake Jira issue number. For example, for GitHub issue
#1400, you should
add "SNOW-1335071" here.
--->
Fixes SNOW-1491199
2. Fill out the following pre-review checklist:
- [ ] I am adding a new automated test(s) to verify correctness of my
new code
- [ ] If this test skips Local Testing mode, I'm requesting review from
@snowflakedb/local-testing
- [ ] I am adding new logging messages
- [ ] I am adding a new telemetry message
- [ ] I am adding new credentials
- [ ] I am adding a new dependency
- [ ] If this is a new feature/behavior, I'm adding the Local Testing
parity changes.
- [x] I acknowledge that I have ensured my changes to be thread-safe.
Follow the link for more information: [Thread-safe Developer
Guidelines](https://docs.google.com/document/d/162d_i4zZ2AfcGRXojj0jByt8EUq-DrSHPPnTa4QvwbA/edit#bookmark=id.e82u4nekq80k)
3. Please describe how your code solves the related issue.
Please write a short description of how your code change solves the
related issue.
This PR removed Protobuf generated code from source and add logic to
generate them when it is need.
This pull request includes the addition of a script to install `protoc`
and updates to multiple GitHub Actions workflows to use this script.
Additionally, there is an update to the `CODEOWNERS` file.
### Installation and usage of `protoc`:
* Added a new script `install_protoc.sh` to install `protoc` on GitHub
Actions runners. This script handles downloading and installing the
appropriate version of `protoc` based on the operating system and
architecture.
### Code ownership:
* Updated the `CODEOWNERS` file to add ownership for the
`tests/unit/ast/` directory to the `@snowflakedb/snowpark-ir` team.
### Test passed
Daily pandas precommit test:
https://github.com/snowflakedb/snowpark-python/actions/runs/11645868643/job/32429396169
Daily notebook precommit test:
https://github.com/snowflakedb/snowpark-python/actions/runs/11645871020
Daily precommit test:
https://github.com/snowflakedb/snowpark-python/actions/runs/11645600647/job/32428853317
pandas Sproc precommit test:
https://ci-dev-142.int.snowflakecomputing.com/job/SnowparkPandasStoredProcPrecommitTest/185/console
### Development Behavior Change
After this PR, when developers try to pip install source code or use
tox, they need to make sure `protoc` is installed. When pip install from
wheel file, no `protoc` is required since the generated code should
exist in the wheel file.1 parent 6e95d34 commit 14cf702
File tree
18 files changed
+321
-744
lines changed- .github
- scripts
- workflows
- ci
- recipe
- scripts
- src/snowflake/snowpark/_internal/proto
- generated
- tests
- unit/ast
18 files changed
+321
-744
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| 5 | + | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
20 | 20 | | |
21 | 21 | | |
22 | 22 | | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
23 | 26 | | |
24 | 27 | | |
25 | 28 | | |
| |||
40 | 43 | | |
41 | 44 | | |
42 | 45 | | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
43 | 49 | | |
44 | 50 | | |
45 | 51 | | |
| |||
82 | 88 | | |
83 | 89 | | |
84 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
85 | 98 | | |
86 | 99 | | |
87 | 100 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
28 | 28 | | |
29 | 29 | | |
30 | 30 | | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
31 | 34 | | |
32 | 35 | | |
33 | 36 | | |
| |||
44 | 47 | | |
45 | 48 | | |
46 | 49 | | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
47 | 53 | | |
48 | 54 | | |
49 | 55 | | |
| |||
67 | 73 | | |
68 | 74 | | |
69 | 75 | | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
70 | 79 | | |
71 | 80 | | |
72 | 81 | | |
| |||
91 | 100 | | |
92 | 101 | | |
93 | 102 | | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
94 | 106 | | |
95 | 107 | | |
96 | 108 | | |
| |||
129 | 141 | | |
130 | 142 | | |
131 | 143 | | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
132 | 151 | | |
133 | 152 | | |
134 | 153 | | |
| |||
201 | 220 | | |
202 | 221 | | |
203 | 222 | | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
204 | 226 | | |
205 | 227 | | |
206 | 228 | | |
| |||
262 | 284 | | |
263 | 285 | | |
264 | 286 | | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
265 | 290 | | |
266 | 291 | | |
267 | 292 | | |
| |||
331 | 356 | | |
332 | 357 | | |
333 | 358 | | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
334 | 362 | | |
335 | 363 | | |
336 | 364 | | |
| |||
392 | 420 | | |
393 | 421 | | |
394 | 422 | | |
| 423 | + | |
| 424 | + | |
| 425 | + | |
395 | 426 | | |
396 | 427 | | |
397 | 428 | | |
| |||
440 | 471 | | |
441 | 472 | | |
442 | 473 | | |
| 474 | + | |
| 475 | + | |
| 476 | + | |
443 | 477 | | |
444 | 478 | | |
445 | 479 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
31 | 31 | | |
32 | 32 | | |
33 | 33 | | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
34 | 37 | | |
35 | 38 | | |
36 | 39 | | |
| |||
63 | 66 | | |
64 | 67 | | |
65 | 68 | | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
66 | 72 | | |
67 | 73 | | |
68 | 74 | | |
| |||
106 | 112 | | |
107 | 113 | | |
108 | 114 | | |
| 115 | + | |
| 116 | + | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
| 121 | + | |
109 | 122 | | |
110 | 123 | | |
111 | 124 | | |
| |||
218 | 231 | | |
219 | 232 | | |
220 | 233 | | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
221 | 237 | | |
222 | 238 | | |
223 | 239 | | |
| |||
287 | 303 | | |
288 | 304 | | |
289 | 305 | | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
290 | 309 | | |
291 | 310 | | |
292 | 311 | | |
| |||
349 | 368 | | |
350 | 369 | | |
351 | 370 | | |
| 371 | + | |
| 372 | + | |
| 373 | + | |
| 374 | + | |
| 375 | + | |
| 376 | + | |
| 377 | + | |
352 | 378 | | |
353 | 379 | | |
354 | 380 | | |
| |||
410 | 436 | | |
411 | 437 | | |
412 | 438 | | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
413 | 442 | | |
414 | 443 | | |
415 | 444 | | |
| |||
477 | 506 | | |
478 | 507 | | |
479 | 508 | | |
| 509 | + | |
| 510 | + | |
| 511 | + | |
480 | 512 | | |
481 | 513 | | |
482 | 514 | | |
| |||
534 | 566 | | |
535 | 567 | | |
536 | 568 | | |
| 569 | + | |
| 570 | + | |
| 571 | + | |
537 | 572 | | |
538 | 573 | | |
539 | 574 | | |
| |||
582 | 617 | | |
583 | 618 | | |
584 | 619 | | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
585 | 623 | | |
586 | 624 | | |
587 | 625 | | |
| |||
0 commit comments