-
Notifications
You must be signed in to change notification settings - Fork 36
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
fix: fail to save results to the database on subsequent calls in scheduling and reporting #709
Conversation
…Error Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
I will want to backport this PR, which brings up the question of where to add the changelog entry. Normally I backport one version, so this would become a bugfix entry for 0.13.2. But in this case, we may want to backport further, for example, to 0.12.4. The changelog entry would then be duplicated. Any other suggestion? If not, please add the changelog entry to 0.13.2, and I'll copy it down when backporting further. Any idea which version this bug started occurring? |
…save-the-results-to-the-database-on-subsequent-calls
Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
Agree. I feel like we should also mention in which version we actually introduce this fix. That way, users can choose to upgrade to that new version (v0.13.2 in this case) or to the backport of the issue in their corresponding minor version. |
No idea when this started happening. It might be quite old. |
…save-the-results-to-the-database-on-subsequent-calls
…uent calls in scheduling and reporting (#709) * fix: get fresh sensor instance to avoid sqlalchemy.exc.InvalidRequestError Signed-off-by: Victor Garcia Reolid <victor@seita.nl> * fx: handle the case of not finding the sensor in the datbase Signed-off-by: Victor Garcia Reolid <victor@seita.nl> * fix: fetch only when the object is detached Signed-off-by: Victor Garcia Reolid <victor@seita.nl> * style: combine if's Signed-off-by: Victor Garcia Reolid <victor@seita.nl> * docs: add changelog entry Signed-off-by: Victor Garcia Reolid <victor@seita.nl> * docs: move entry from v0.14.0 to v0.13.2 Signed-off-by: Victor Garcia Reolid <victor@seita.nl> --------- Signed-off-by: Victor Garcia Reolid <victor@seita.nl>
This PR introduces a workaround to get a sensor instance attached to the database session. For more details on this issue, please refer to #683.
Closes #683