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

front: stdcm consist form validation #9574

Merged
merged 2 commits into from
Jan 8, 2025
Merged

Conversation

Wadjetz
Copy link
Member

@Wadjetz Wadjetz commented Nov 5, 2024

fix #9529
fix #9374

  • Add validation to consist form
  • Disable start simulation button with errors
  • Waiting for PR
  • Add tooltips status messages for inputs

@Wadjetz Wadjetz self-assigned this Nov 5, 2024
@codecov-commenter
Copy link

codecov-commenter commented Nov 5, 2024

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 81.50%. Comparing base (cae4d30) to head (5fb08e4).
Report is 6 commits behind head on dev.

❗ Your organization needs to install the Codecov GitHub app to enable full functionality.

Additional details and impacted files
@@            Coverage Diff             @@
##              dev    #9574      +/-   ##
==========================================
+ Coverage   81.49%   81.50%   +0.01%     
==========================================
  Files        1058     1059       +1     
  Lines      104270   104424     +154     
  Branches      722      722              
==========================================
+ Hits        84973    85111     +138     
- Misses      19256    19272      +16     
  Partials       41       41              
Flag Coverage Δ
editoast 73.69% <ø> (-0.06%) ⬇️
front 89.23% <100.00%> (+0.02%) ⬆️
gateway 2.18% <ø> (ø)
osrdyne 3.28% <ø> (ø)
railjson_generator 87.50% <ø> (ø)
tests 87.05% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 2 times, most recently from a4b4fc8 to f0edf0f Compare November 6, 2024 16:11
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 2 times, most recently from 10e5c5f to 969c2c7 Compare November 7, 2024 10:14
@Wadjetz Wadjetz marked this pull request as ready for review November 7, 2024 10:37
@Wadjetz Wadjetz requested a review from a team as a code owner November 7, 2024 10:37
Copy link
Member

@emersion emersion left a comment

Choose a reason for hiding this comment

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

Thanks for the patch! Here are a few comments.

front/src/utils/physics.ts Outdated Show resolved Hide resolved
front/src/applications/stdcm/utils/consistValidation.ts Outdated Show resolved Hide resolved
front/src/applications/stdcm/utils/consistValidation.ts Outdated Show resolved Hide resolved
@Wadjetz Wadjetz added area:front Work on Standard OSRD Interface modules module:stdcm Short-Term DCM labels Nov 8, 2024
@clarani
Copy link
Contributor

clarani commented Nov 8, 2024

It would be nice to have the min length and weight of the rolling stock in the error text. What do you think ?

@github-actions github-actions bot removed the area:front Work on Standard OSRD Interface modules label Nov 8, 2024
@emersion emersion self-requested a review November 12, 2024 11:01
@axrolld axrolld linked an issue Nov 14, 2024 that may be closed by this pull request
1 task
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 3 times, most recently from 37f1cc8 to 488604b Compare November 18, 2024 16:15
@Wadjetz Wadjetz requested a review from SarahBellaha November 18, 2024 16:16
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from 488604b to ea9b2ba Compare November 18, 2024 16:22
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from ea9b2ba to b0387e6 Compare November 19, 2024 15:42
@Wadjetz Wadjetz requested a review from emersion November 19, 2024 15:43
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from b0387e6 to 028bbda Compare November 21, 2024 09:02
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 2 times, most recently from 8643c88 to 9708dce Compare January 3, 2025 16:14
@Wadjetz Wadjetz requested a review from emersion January 3, 2025 16:15
@Wadjetz Wadjetz marked this pull request as ready for review January 3, 2025 16:16
@Wadjetz Wadjetz removed the postponed Postponed task due to other priorities or waiting for dependencies label Jan 3, 2025
front/package.json Outdated Show resolved Hide resolved
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from 9708dce to f85b804 Compare January 6, 2025 13:34
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from 19d4fd2 to 2be774c Compare January 6, 2025 14:08
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 3 times, most recently from a36702e to 005d0e0 Compare January 7, 2025 10:08
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch 3 times, most recently from cbdf62e to 688df93 Compare January 7, 2025 16:15
@Wadjetz Wadjetz force-pushed the ebe/front/stdcm/consist-validation branch from 688df93 to 858b862 Compare January 7, 2025 19:40
@Maymanaf Maymanaf requested a review from a team as a code owner January 8, 2025 13:03
@Wadjetz Wadjetz added this pull request to the merge queue Jan 8, 2025
Merged via the queue into dev with commit 68c10f1 Jan 8, 2025
27 checks passed
@Wadjetz Wadjetz deleted the ebe/front/stdcm/consist-validation branch January 8, 2025 13:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:front Work on Standard OSRD Interface modules module:stdcm Short-Term DCM
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Handle invalid values in stdcm inputs Add front check for mass and length consistency
7 participants