-
Notifications
You must be signed in to change notification settings - Fork 117
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-1227759: ambiguous overload typing causing typing error false positives with DataFrameWriter.save_as_table() #1296
Comments
Hello @TedCha , Thank you raising the issue.
Regards, |
Hello @sfc-gh-sghosh. No error is thrown at runtime, the error is thrown during static type checking. Please see the attached screenshot. |
Hello @TedCha , I tried using snowflake-connector-python 3.7.0 and Snowpark python 1.11.1, there is no static type checking error. Its running successfully at run time as well. Could you please paste the full message and could you try fresh from another IDE such as Jupyter? Regards, |
Hello Sujan, Thank you for looking into this issue. The issue is not an error happening at runtime, it is an error happening during static type checking before runtime. Jupyter can not perform static type checking without having a language server installed. I was able to recreate the described issue in Jupyter Labs by installing the LSP integration for Jupyter and then installing the Pyright LSP. Pyright is the LSP that I am using in my IDE (VSCode) but this error could be in multiple Python language server protocols. Please see attached screenshots for reference. |
I believe #1058 is the same issue. |
Hello @TedCha , Thanks for the update, we are checking. Regards, |
Please answer these questions before submitting your issue. Thanks!
Python 3.8.10 (tags/v3.8.10:3d8993a, May 3 2021, 11:48:03) [MSC v.1928 64 bit (AMD64)]
Windows-10-10.0.19045-SP0
pip freeze
)?When the
DataFrameWriter.save_as_table()
method is called without theclustering_keys
parameter, the pylance type checker will report the following error when trying to call the function:Snippet:
No type checking error when using
save_as_table
method as described in documentation.NA; static type checking.
Note:
I think this issue could be resolved by making the
clustering_keys
parameter optional on all overloads:Ex:
The text was updated successfully, but these errors were encountered: