Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SNOW-1269784: Snow Snowpark Build/Deploy Issues (can't manually zip folder) #936

Closed
fletchertyler914 opened this issue Mar 25, 2024 · 3 comments
Assignees

Comments

@fletchertyler914
Copy link

SnowCLI version

2.1.1

Python version

3.11.7

Platform

macOS-10.16-x86_64-i386-64bit

What happened

This is a bit weird, but I have a need to build my snowpark project, unzip the package, and make a modification to a sub-module. I found a bug in the process, which I have isolated the issue down to simply unzipping and zipping the package, no changes necessary.

  1. if you build the package with snow build, and deploy it with snow deploy, it works fine.
  2. if you build the package with snow build, open the zipped package, re-zip the folder, and then deploy it with snow deploy, it ends up not being able to find modules that are clearly in the package. The deploy does not fail, the procedure being called just fails at runtime.

The screen recording walks through these two paths above, illustrating the breaking point is simply opening and re-zipping the folder generated by snow build.

Screen.Recording.2024-03-25.at.14.39.58.mov

Console output

Python Interpreter Error:
ModuleNotFoundError: No module named 'procedures' in function HELLO_PROCEDURE with handler procedures.hello_procedure

How to reproduce

  1. Init a snowpark project
  2. run snow build to build the project zip
  3. open/extract the project zip, delete existing zip file
  4. compress the expanded project folder to create a new zip
  5. run snow deploy for the new zip
  6. call procedure
@github-actions github-actions bot changed the title Snow Snowpark Build/Deploy Issues (can't manually zip folder) SNOW-1269784: Snow Snowpark Build/Deploy Issues (can't manually zip folder) Mar 25, 2024
@fletchertyler914
Copy link
Author

I did go back and test v2.0.0 and v2.1.0 as well, and they have the same issue.

@sfc-gh-mraba
Copy link
Contributor

Hi,

It looks like your manually created zip contains extra app 2/ due to compressing folder and not only its content.
Can you compare content and paths of both archives using unzip -l <name_of_archive>.zip ?

@sfc-gh-mraba sfc-gh-mraba self-assigned this Mar 26, 2024
@fletchertyler914
Copy link
Author

Oh! you're right, compressing the folder does nest everything in the parent folder. Consider this a non-issue, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants