-
Notifications
You must be signed in to change notification settings - Fork 4
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
Fixed row converter to properly handle nullable values #53
Merged
Conversation
This file contains 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
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #53 +/- ##
==========================================
- Coverage 83.17% 82.95% -0.22%
==========================================
Files 7 7
Lines 529 534 +5
Branches 105 105
==========================================
+ Hits 440 443 +3
- Misses 54 55 +1
- Partials 35 36 +1 ☔ View full report in Codecov by Sentry. |
✅ 18/18 passed, 1 skipped, 25m42s total Running from acceptance #17 |
nfx
added a commit
that referenced
this pull request
Mar 13, 2024
* Fixed row converter to properly handle nullable values ([#53](#53)). In this release, the row converter in the `databricks.labs.lsql.core` module has been updated to handle nullable values correctly. A new method `StatementExecutionExt` has been added, which manages the handling of nullable values during SQL statement execution. The `Row` class has also been modified to include nullable values, improving the robustness and flexibility of SQL execution in dealing with various data types, including null values. These enhancements increase the overall reliability of the system, making it more production-ready. * Improved integration test coverage ([#52](#52)). In this release, the project's integration test coverage has been significantly improved through several changes. A new function, `make_random()`, has been added to the `conftest.py` file to generate a random string of fixed length, aiding in the creation of more meaningful and readable random strings for integration tests. A new file, `test_deployment.py`, has been introduced, containing a test function for deploying a database schema and verifying successful data retrieval via a view. The `test_integration.py` file has been renamed to `test_core.py`, with updates to the `test_fetch_one` function to test the `fetch_one` method using a SQL query with an aliased value. Additionally, a new `Foo` dataclass has been added to the `tests/integration/views/__init__.py` file, supporting integration test coverage. Lastly, a new SQL query has been added to the integration test suite, located in the `some.sql` file, which retrieves data from a table named `foo` in the `inventory` schema. These changes aim to enhance the overall stability, reliability, and coverage of the project's integration tests. Note: The changes to the `.gitignore` file and the improvements to the `StatementExecutionBackend` class in the `backends.py` file are not included in this summary, as they were described in the opening statement. * Rely on `hatch` being present on the build machine ([#54](#54)). In this release, we have made significant changes to how we manage our build process and toolchain configuration. We have removed the need to manually install `hatch` version 1.7.0 in the build machine, and instead, rely on its presence, adding it to the list of required tools in the toolchain configuration. The command to create a virtual environment using `hatch` has also been added, and the `pre_setup` section no longer includes installing `hatch`, assuming its availability. We have also updated the `hatch` package version from 1.7.0 to 1.9.4, which may include bug fixes, performance improvements, or new features. This change may impact the behavior of any existing functionality that relies on `hatch`. The `pyproject.toml` file has been modified to update the `fmt` and `verify` sections, with `ruff check . --fix` replacing `ruff . --fix` and the removal of `black --check .` and `isort . --check-only`. A new configuration for `isort` has also been added to specify the `databricks.labs.blueprint` package as a known first-party package, enabling more precise management of imports related to that package. These changes simplify the build process and ensure that the project is using a more recent version of the `hatch` package for packaging and distributing Python projects. * Updated sqlglot requirement from ~=22.3.1 to >=22.3.1,<22.5.0 ([#51](#51)). In this release, we have updated the version constraint for the `sqlglot` package in our project's `pyproject.toml` file. Previously, we had set the constraint to `~=22.3.1`, allowing for any version with the same major and minor numbers but different patch numbers. With this update, we have changed the constraint to `>=22.3.1,<22.5.0`. This change enables our project to utilize bug fixes and improvements made in the latest patch versions of `sqlglot`, while still preventing it from inadvertently using any breaking changes introduced in version 22.5.0 or later versions. This modification allows us to take advantage of the latest features and improvements in `sqlglot` while maintaining compatibility and stability in our project. Dependency updates: * Updated sqlglot requirement from ~=22.3.1 to >=22.3.1,<22.5.0 ([#51](#51)).
Merged
nfx
added a commit
that referenced
this pull request
Mar 13, 2024
* Fixed row converter to properly handle nullable values ([#53](#53)). In this release, the row converter in the `databricks.labs.lsql.core` module has been updated to handle nullable values correctly. A new method `StatementExecutionExt` has been added, which manages the handling of nullable values during SQL statement execution. The `Row` class has also been modified to include nullable values, improving the robustness and flexibility of SQL execution in dealing with various data types, including null values. These enhancements increase the overall reliability of the system, making it more production-ready. * Improved integration test coverage ([#52](#52)). In this release, the project's integration test coverage has been significantly improved through several changes. A new function, `make_random()`, has been added to the `conftest.py` file to generate a random string of fixed length, aiding in the creation of more meaningful and readable random strings for integration tests. A new file, `test_deployment.py`, has been introduced, containing a test function for deploying a database schema and verifying successful data retrieval via a view. The `test_integration.py` file has been renamed to `test_core.py`, with updates to the `test_fetch_one` function to test the `fetch_one` method using a SQL query with an aliased value. Additionally, a new `Foo` dataclass has been added to the `tests/integration/views/__init__.py` file, supporting integration test coverage. Lastly, a new SQL query has been added to the integration test suite, located in the `some.sql` file, which retrieves data from a table named `foo` in the `inventory` schema. These changes aim to enhance the overall stability, reliability, and coverage of the project's integration tests. Note: The changes to the `.gitignore` file and the improvements to the `StatementExecutionBackend` class in the `backends.py` file are not included in this summary, as they were described in the opening statement. * Rely on `hatch` being present on the build machine ([#54](#54)). In this release, we have made significant changes to how we manage our build process and toolchain configuration. We have removed the need to manually install `hatch` version 1.7.0 in the build machine, and instead, rely on its presence, adding it to the list of required tools in the toolchain configuration. The command to create a virtual environment using `hatch` has also been added, and the `pre_setup` section no longer includes installing `hatch`, assuming its availability. We have also updated the `hatch` package version from 1.7.0 to 1.9.4, which may include bug fixes, performance improvements, or new features. This change may impact the behavior of any existing functionality that relies on `hatch`. The `pyproject.toml` file has been modified to update the `fmt` and `verify` sections, with `ruff check . --fix` replacing `ruff . --fix` and the removal of `black --check .` and `isort . --check-only`. A new configuration for `isort` has also been added to specify the `databricks.labs.blueprint` package as a known first-party package, enabling more precise management of imports related to that package. These changes simplify the build process and ensure that the project is using a more recent version of the `hatch` package for packaging and distributing Python projects. * Updated sqlglot requirement from ~=22.3.1 to >=22.3.1,<22.5.0 ([#51](#51)). In this release, we have updated the version constraint for the `sqlglot` package in our project's `pyproject.toml` file. Previously, we had set the constraint to `~=22.3.1`, allowing for any version with the same major and minor numbers but different patch numbers. With this update, we have changed the constraint to `>=22.3.1,<22.5.0`. This change enables our project to utilize bug fixes and improvements made in the latest patch versions of `sqlglot`, while still preventing it from inadvertently using any breaking changes introduced in version 22.5.0 or later versions. This modification allows us to take advantage of the latest features and improvements in `sqlglot` while maintaining compatibility and stability in our project. Dependency updates: * Updated sqlglot requirement from ~=22.3.1 to >=22.3.1,<22.5.0 ([#51](#51)).
Sign up for free
to 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.
No description provided.