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: select only valid train by default (for the selected train and for the train used for the projection) #8879

Merged
merged 1 commit into from
Sep 20, 2024

Conversation

clarani
Copy link
Contributor

@clarani clarani commented Sep 16, 2024

closes #8535

To test, create a scenario which contains invalid and valid trains (the first train must be invalid). By default, the train used for the projection should not be the first one

@codecov-commenter
Copy link

codecov-commenter commented Sep 16, 2024

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

Codecov Report

Attention: Patch coverage is 0% with 67 lines in your changes missing coverage. Please review.

Project coverage is 37.13%. Comparing base (fbf8e3e) to head (8b35bd9).
Report is 4 commits behind head on dev.

Files with missing lines Patch % Lines
...perationalStudies/hooks/useAutoUpdateProjection.ts 0.00% 59 Missing and 1 partial ⚠️
...ations/operationalStudies/hooks/useScenarioData.ts 0.00% 7 Missing ⚠️

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

Additional details and impacted files
@@             Coverage Diff              @@
##                dev    #8879      +/-   ##
============================================
- Coverage     37.14%   37.13%   -0.02%     
  Complexity     2211     2211              
============================================
  Files          1260     1260              
  Lines        115060   115084      +24     
  Branches       3230     3230              
============================================
- Hits          42738    42733       -5     
- Misses        70389    70418      +29     
  Partials       1933     1933              
Flag Coverage Δ
core 74.67% <ø> (ø)
editoast 72.55% <ø> (-0.02%) ⬇️
front 15.20% <0.00%> (-0.01%) ⬇️
gateway 2.20% <ø> (ø)
osrdyne 2.60% <ø> (ø)
railjson_generator 87.49% <ø> (ø)
tests 86.46% <ø> (ø)

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.

@clarani clarani force-pushed the cni/8535-select-only-valid-train-by-default branch from c4f3b17 to 5e7aa97 Compare September 18, 2024 08:13
@clarani clarani marked this pull request as ready for review September 18, 2024 08:13
@clarani clarani requested a review from a team as a code owner September 18, 2024 08:13
@louisgreiner
Copy link
Contributor

It works fine for a moment, then if we go back and forth on the valid / invalid train path, it get stuck on the invalid path again (that it what i understand, see following screenshot)

image

@anisometropie
Copy link
Contributor

It works fine for a moment, then if we go back and forth on the valid / invalid train path, it get stuck on the invalid path again (that it what i understand, see following screenshot)

isn’t this this issue ?
https://github.com/orgs/osrd-project/projects/15/views/11?pane=issue&itemId=79584469

By default, we select the first train for the selected train and the path used for the projection,
even if it is invalid. However, we should only select a valid train.
@clarani clarani force-pushed the cni/8535-select-only-valid-train-by-default branch 2 times, most recently from af880ac to 8b35bd9 Compare September 19, 2024 09:50
@clarani clarani enabled auto-merge September 19, 2024 09:50
@louisgreiner
Copy link
Contributor

Question: do we still allow to select a path for an invalid train schedule ? I would imagine disabling the button for invalid train schedules

Enregistrement.de.l.ecran.2024-09-19.120427.mp4

@clarani
Copy link
Contributor Author

clarani commented Sep 20, 2024

@louisgreiner I've created a new issue (#8922) to tackle what you have raised, since we don't agree on how to do it :)
I will do it later in another PR

Copy link
Contributor

@SharglutDev SharglutDev left a comment

Choose a reason for hiding this comment

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

Lgtm and tested, good job !

@clarani clarani added this pull request to the merge queue Sep 20, 2024
@github-merge-queue github-merge-queue bot removed this pull request from the merge queue due to failed status checks Sep 20, 2024
@clarani clarani added this pull request to the merge queue Sep 20, 2024
Merged via the queue into dev with commit b448226 Sep 20, 2024
23 checks passed
@clarani clarani deleted the cni/8535-select-only-valid-train-by-default branch September 20, 2024 12:03
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.

GET doens't show when there is invalid train in the timetable
6 participants