Skip to content

PYTHON-2287 Improve error message for invalid boolean option #1236

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

Merged
merged 4 commits into from
Jun 15, 2023

Conversation

sleepyStick
Copy link
Contributor

@sleepyStick sleepyStick changed the title PYTHON-2287 fixed validate boolean message PYTHON-2287 fix validate boolean message Jun 14, 2023
@@ -19,6 +19,13 @@
from pymongo.errors import ConfigurationError


def validate_boolean(option: str, value: Any) -> bool:
Copy link
Member

Choose a reason for hiding this comment

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

Could you add a comment above this that says:

# Moved here to avoid a circular import.

@sleepyStick sleepyStick requested a review from NoahStapp as a code owner June 15, 2023 18:12
Copy link
Member

@ShaneHarvey ShaneHarvey left a comment

Choose a reason for hiding this comment

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

LGTM!

              |    |    |                 
             )_)  )_)  )_)              
            )___))___))___)\            
           )____)____)_____)\\
         _____|____|____|____\\\__
---------\                   /---------
  ^^^^^ ^^^^^^^^^^^^^^^^^^^^^
    ^^^^      ^^^^     ^^^    ^^
         ^^^^      ^^^

@sleepyStick sleepyStick changed the title PYTHON-2287 fix validate boolean message PYTHON-2287 Improve error message for invalid boolean option Jun 15, 2023
@sleepyStick sleepyStick merged commit f7874fb into mongodb:master Jun 15, 2023
@sleepyStick sleepyStick deleted the PYTHON-2287 branch June 15, 2023 18:55
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