forked fromdatabricks/databricks-sql-python
- Notifications
You must be signed in to change notification settings - Fork1
visit_create_table method added to dialect#3
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Merged
Uh oh!
There was an error while loading.Please reload this page.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.Learn more about bidirectional Unicode characters
PeterDKay pushed a commit that referenced this pull requestOct 3, 2024
* move py.typed to correct placeshttps://peps.python.org/pep-0561/ says 'For namespace packages (see PEP 420), the py.typed file should be in the submodules of the namespace, to avoid conflicts and for clarity.'. Previously, when I added the py.typed file to this project,databricks#382 , I was unaware this was a namespace package (although, curiously, it seems I had done it right initially and then changed to the wrong way). As PEP 561 warns us, this does create conflicts; other libraries in the databricks namespace package (such as, in my case, databricks-vectorsearch) are then treated as though they are typed, which they are not. This commit moves the py.typed file to the correct places, the submodule folders, fixing that problem.Signed-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* change target of mypy to src/databricks instead of src.I think this might fix the CI code-quality checks failure, but unfortunately I can't replicate that failure locally and the error message is unhelpfulSigned-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* Possible workaround for bad error message 'error: --install-types failed (no mypy cache directory)'; seepython/mypy#10768 (comment)Signed-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* fix invalid yaml syntaxSigned-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* Best fix (#3)Fixes the problem by cding and supplying a flag to mypy (that mypy needs this flag is seemingly fixed/changed in later versions of mypy; but that's another pr altogether...). Also fixes a type error that was somehow in the arguments of the program (?!) (I guess this is because you guys are still using implicit optional)---------Signed-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* return the old result_links default (#5)Return the old result_links default, make the type optional, & I'm pretty sure the original problem is that add_file_links can't take a None, so these statements should be in the body of the if-statement that ensures it is not NoneSigned-off-by: wyattscarpenter <wyattscarpenter@gmail.com>* Update src/databricks/sql/utils.py"self.download_manager is unconditionally used later, so must be created. Looks this part of code is totally not covered with tests 🤔"Co-authored-by: Levko Kravets <levko.ne@gmail.com>Signed-off-by: wyattscarpenter <wyattscarpenter@gmail.com>---------Signed-off-by: wyattscarpenter <wyattscarpenter@gmail.com>Co-authored-by: Levko Kravets <levko.ne@gmail.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Added create_table method to dialect to include 'IF NOT EXISTS' as default, preventing failed alembic upgrades.