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

Handle empty string passed to Query condition #1774

Conversation

Shelnutt2
Copy link
Member

This treats an empty string "" the same as None when applying a query condition. This is useful as users are passing strings for query condition and avoids the user needing to validate they've successfully built a condition before passing it in.

@shortcut-integration
Copy link

This pull request has been linked to Shortcut Story #29592: Handle empty string from user in query conditions.

@Shelnutt2 Shelnutt2 force-pushed the sethshelnutt/sc-29592/handle-empty-string-from-user-in-query-conditions branch 2 times, most recently from 9aebd77 to f8a16cd Compare May 26, 2023 20:58
Copy link
Member

@ihnorton ihnorton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm as long as @nguyenv is ok with it.

Copy link
Member

@ihnorton ihnorton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Lgtm as long as @nguyenv is ok with it.

@nguyenv
Copy link
Collaborator

nguyenv commented May 26, 2023

I am still seeing FAILED tiledb/tests/test_query_condition.py::QueryDeleteTest::test_qc_dense_empty - AttributeError: 'list' object has no attribute 'nbytes'

This treats an empty string `""` the same as None when applying a query
condition. This is useful as users are passing strings for query
condition and avoids the user needing to validate they've successfully
built a condition before passing it in.
@Shelnutt2 Shelnutt2 force-pushed the sethshelnutt/sc-29592/handle-empty-string-from-user-in-query-conditions branch from f8a16cd to 5e2eb14 Compare May 26, 2023 21:37
@Shelnutt2 Shelnutt2 merged commit 36a1843 into dev May 27, 2023
@Shelnutt2 Shelnutt2 deleted the sethshelnutt/sc-29592/handle-empty-string-from-user-in-query-conditions branch May 27, 2023 00:19
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

Successfully merging this pull request may close these issues.

3 participants