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

docker-py fix: fix(store): warn on init instead of throw #581

Closed
wants to merge 2 commits into from

Conversation

felixfontein
Copy link
Collaborator

SUMMARY

Cherry-picked docker/docker-py#3080.

Using the proper ansible-core mechanisms for warnings instead of import warnings resulted in a lot of extra code.

Ref: #435

ISSUE TYPE
  • Bugfix Pull Request
COMPONENT NAME

vendored Docker SDK for Python

@kristianheljas
Copy link

I have a few issues with this one:

  1. warn argument is ambiguous - I was surprised when i discovered that it's a function, not a boolean.
  2. Mere presence of the warning function will suppress an exception in Store.__init().
  3. It's gonna fail with the same message in Store._execute() anyway so I can't see any advantage for the warning.

What are your thoughts about just silencing the InitializationError via explicit argument - validate_program_path=False for example?

@felixfontein
Copy link
Collaborator Author

Let's close this, as it isn't really needed anyway.

@felixfontein felixfontein deleted the docker-py branch October 15, 2023 11:18
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.

2 participants