Skip to content

preserve consumer-provided "runOnJobQueue" value when set to True#23

Merged
nicolettaaddimando merged 2 commits into
meteoblue:masterfrom
huwylphimet:patch-2
Jan 8, 2025
Merged

preserve consumer-provided "runOnJobQueue" value when set to True#23
nicolettaaddimando merged 2 commits into
meteoblue:masterfrom
huwylphimet:patch-2

Conversation

@huwylphimet

Copy link
Copy Markdown
Contributor

Previously, the "runOnJobQueue" parameter was always overwritten with False, even if a consumer explicitly passed True. This behavior prevented consumers from skipping the initial attempt without the job queue, even when it was certain their query would go to the job queue.

By using setdefault(), the parameter is only set to False if it is not already provided. This change allows consumers who know their query requires the job queue to bypass the first attempt and directly push the job to the queue.

Previously, the "runOnJobQueue" parameter was always overwritten with False, even if a consumer explicitly passed True. This behavior prevented consumers from skipping the initial attempt without the job queue, even when it was certain their query would go to the job queue.

By using setdefault(), the parameter is only set to False if it is not already provided. This change allows consumers who know their query requires the job queue to bypass the first attempt and directly push the job to the queue.
@nicolettaaddimando nicolettaaddimando merged commit fa95cc5 into meteoblue:master Jan 8, 2025
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