-
Notifications
You must be signed in to change notification settings - Fork 66
chore: moving diverged states from error to completed #3022
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull request overview
This PR reclassifies the "diverge" and "diverged" simulation states from error states to completed states, treating diverged simulations as successfully completed runs rather than errors.
Key Changes
- Moved "diverge" and "diverged" from ERROR_STATES to COMPLETED_STATES in the state management system
- Updated progress percentage for diverged states from 0% to 100% to reflect completion
- Added new notebooks to the exclusion list and updated the notebook inventory comment date
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| tidy3d/web/api/states.py | Reclassifies "diverge" and "diverged" states from ERROR_STATES to COMPLETED_STATES and updates their progress percentage from 0 to 100 |
| tests/_test_notebooks/full_test_notebooks.py | Adds notebooks to skip list, updates comment date, and expands the notebook inventory list |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
2 files reviewed, no comments
aa3125b to
6b5928c
Compare
6b5928c to
8b5618c
Compare
Diff CoverageDiff: origin/develop...HEAD, staged and unstaged changes
Summary
|
8b5618c to
d95c80b
Compare
Opening a new PR to pass the linting.
Also piggy-backing a small update to the notebook test script.
Greptile Overview
Greptile Summary
This PR reclassifies simulation divergence from an error state to a completed state, reflecting that diverged simulations still produce usable data and complete execution.
Key Changes
divergeanddivergedfromERROR_STATEStoCOMPLETED_STATESintidy3d/web/api/states.pyImpact
The reclassification is semantically correct since diverged simulations:
tidy3d/web/api/tidy3d_stub.py:221-222)The change affects display logic in
container.pywhere diverged states will now show as green (completed) instead of red (error).Confidence Score: 5/5
Important Files Changed
File Analysis
divergeanddivergedstates fromERROR_STATEStoCOMPLETED_STATESand updated progress percentage to 100%Sequence Diagram
sequenceDiagram participant User participant WebAPI participant Container participant States participant SimData User->>WebAPI: Submit simulation WebAPI->>States: Check state progression alt Simulation diverges States->>States: Set status = "diverged" Note over States: Previously in ERROR_STATES<br/>Now in COMPLETED_STATES States->>States: Progress = 100% States-->>Container: Return status Container->>Container: Check status in COMPLETED_STATES Container->>User: Display green (completed) WebAPI->>SimData: Retrieve data SimData->>SimData: diverged=True flag set SimData-->>User: Return data with warning else Normal completion States->>States: Set status = "success" States-->>Container: Return status Container->>User: Display green (completed) WebAPI->>SimData: Retrieve data SimData-->>User: Return data end