Skip to content

Fully overwrite values in MillingStep entry upon update#832

Closed
tieneupin wants to merge 1 commit into
mainfrom
milling-progress-fix
Closed

Fully overwrite values in MillingStep entry upon update#832
tieneupin wants to merge 1 commit into
mainfrom
milling-progress-fix

Conversation

@tieneupin

Copy link
Copy Markdown
Contributor

Now that the FIB milling progress registration logic is live, we have been able to start detecting bugs that weren't caught during testing.

In the FIB AutoTEM metadata, once a step is complete, the is_enabled field is set back to False. However, the current ISPyB insertion logic only supports the insertion and updating of truth-y values. Once the field is set to True, it can't be set back to False again based on current logic.

This PR fixes that by fully overwriting all values in an existing MillingStep database entry when updating it, instead of updating the value only when it's truth-y.

@codecov

codecov Bot commented Jun 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 53.11%. Comparing base (df053f5) to head (146a09b).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #832   +/-   ##
=======================================
  Coverage   53.11%   53.11%           
=======================================
  Files         100      100           
  Lines       10834    10834           
  Branches     1434     1434           
=======================================
  Hits         5754     5754           
  Misses       4775     4775           
  Partials      305      305           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@tieneupin tieneupin self-assigned this Jun 18, 2026
@tieneupin tieneupin added fib Part of the FIB pipeline extension bug Something isn't working server Relates to the server component labels Jun 18, 2026
@tieneupin

Copy link
Copy Markdown
Contributor Author

Discussed and not needed. It's more practical to have a record of steps that were previously enabled than it is to fully follow the metadata.

@tieneupin tieneupin closed this Jun 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working fib Part of the FIB pipeline extension server Relates to the server component

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant