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

azure service bus: add type annotations and use cached property #1640

Merged
merged 1 commit into from
Jan 4, 2023

Conversation

jasonwbarnett
Copy link
Contributor

Title is self explanatory.

I converted some instance methods from @property to @cached_property because it's less verbose and I assumed that was the actual intent.

There is one underlying change too which I can't tell if it was a bug or by design, I'd like someone else to review to make sure I'm not changing the intended behavior.

@@ -229,7 +227,7 @@ def _delete(self, queue: str, *args, **kwargs) -> None:
"""Delete queue by name."""
queue = self.entity_name(self.queue_name_prefix + queue)

self._queue_mgmt_service.delete_queue(queue)
self.queue_mgmt_service.delete_queue(queue)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is the change that I called out in the PR description. I'm not sure if this was accessing the variable instead of using the method intentionally or was an accident.

@jasonwbarnett jasonwbarnett marked this pull request as draft January 2, 2023 19:38
@auvipy
Copy link
Member

auvipy commented Jan 3, 2023

the additional changes here is causing service request error in the tests

@jasonwbarnett
Copy link
Contributor Author

jasonwbarnett commented Jan 3, 2023

the additional changes here is causing service request error in the tests

Thanks for bringing that to my attention. That's why this is marked as a draft. I am planning to refactor the tests sometime this week.

@jasonwbarnett jasonwbarnett force-pushed the annotate/azure-service-bus branch 3 times, most recently from 2b2aaed to 7eb0854 Compare January 3, 2023 23:02
@jasonwbarnett jasonwbarnett marked this pull request as ready for review January 3, 2023 23:04
@jasonwbarnett
Copy link
Contributor Author

@auvipy this is ready for review 👀

@jasonwbarnett jasonwbarnett force-pushed the annotate/azure-service-bus branch 3 times, most recently from 646bbdc to 9fc5e44 Compare January 4, 2023 15:01
@thedrow
Copy link
Member

thedrow commented Jan 4, 2023

Can you please rebase so that the tests would run?
We had a misconfiguration in our CI workflow because we renamed the master branch to main.

@jasonwbarnett
Copy link
Contributor Author

Can you please rebase so that the tests would run? We had a misconfiguration in our CI workflow because we renamed the master branch to main.

@thedrow this MR is already rebased off of main.

@jasonwbarnett
Copy link
Contributor Author

@thedrow I overlooked what your intent was. I just amended the commit and re-pushed.

@auvipy auvipy merged commit d3ca0d5 into celery:main Jan 4, 2023
@jasonwbarnett jasonwbarnett deleted the annotate/azure-service-bus branch January 4, 2023 18:51
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