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

Warn if result backend is unset #430

Merged
merged 4 commits into from
Mar 24, 2025
Merged

Conversation

igor-gorohovsky
Copy link
Contributor

@igor-gorohovsky igor-gorohovsky commented Mar 21, 2025

@igor-gorohovsky
Copy link
Contributor Author

@s3rius Maybe we should add a warning for other task methods if the result backend is not set. What do you think?

Copy link
Member

@s3rius s3rius left a comment

Choose a reason for hiding this comment

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

In my opinion the isinstance method is quite expensive to call. We can just add raise in the DummyBackend itself.

Because this isinstance call will be triggered for any ResultBackend. Which might decrease performance.

s3rius
s3rius previously approved these changes Mar 24, 2025
@s3rius
Copy link
Member

s3rius commented Mar 24, 2025

I'm wondering. Maybe it'd be better to use warn module to make warnings appear even if you haven't configured logging.

@s3rius s3rius merged commit c0374eb into taskiq-python:master Mar 24, 2025
33 checks passed
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