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

editoast: update args for train_schedule/results #6234

Merged
merged 2 commits into from
Jan 22, 2024

Conversation

younesschrifi
Copy link
Contributor

@younesschrifi younesschrifi commented Dec 28, 2023

Close #6095

Front part :

  • remove displaySimulation from the store (wasn't relevant on the only spot where it was used)
  • add a state in Scenario.tsx to control which trains we want the results for
  • optimize the fetching of train results when adding/updating/deleting train(s)

⚠️ There is still one non optimize case when deleting the last projected train of its path on a large timetable, the (long) fetching of train results is launched 2 times but that should be fixed with #6385

Copy link

codecov bot commented Dec 28, 2023

Codecov Report

Attention: 256 lines in your changes are missing coverage. Please review.

Comparison is base (572a549) 27.78% compared to head (17e95ce) 27.72%.

Files Patch % Lines
...src/applications/stdcm/views/StdcmRequestModal.tsx 0.00% 46 Missing ⚠️
...hedule/components/Timetable/TimetableTrainCard.tsx 0.00% 40 Missing ⚠️
...s/trainschedule/components/Timetable/Timetable.tsx 0.00% 37 Missing ⚠️
...tudies/components/Scenario/getSimulationResults.ts 0.00% 32 Missing ⚠️
editoast/src/views/train_schedule/mod.rs 31.11% 31 Missing ⚠️
...esult/components/SpaceTimeChart/SpaceTimeChart.tsx 0.00% 25 Missing ⚠️
...applications/operationalStudies/views/Scenario.tsx 0.00% 21 Missing ⚠️
...ons/operationalStudies/views/SimulationResults.tsx 0.00% 6 Missing ⚠️
editoast/src/models/train_schedule.rs 0.00% 5 Missing ⚠️
...ManageTrainSchedule/SubmitConfAddTrainSchedule.tsx 0.00% 4 Missing ⚠️
... and 3 more
Additional details and impacted files
@@             Coverage Diff              @@
##                dev    #6234      +/-   ##
============================================
- Coverage     27.78%   27.72%   -0.06%     
  Complexity     2165     2165              
============================================
  Files          1003     1003              
  Lines        126467   126598     +131     
  Branches       2580     2580              
============================================
- Hits          35134    35098      -36     
- Misses        89843    90010     +167     
  Partials       1490     1490              
Flag Coverage Δ
core 78.58% <ø> (ø)
editoast 75.48% <28.00%> (-0.23%) ⬇️
front 8.36% <6.38%> (-0.01%) ⬇️
gateway 2.50% <ø> (ø)
railjson_generator 87.44% <ø> (ø)
tests 81.95% <100.00%> (-0.07%) ⬇️

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.

@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch 6 times, most recently from f0dcdd4 to 0163a98 Compare January 8, 2024 10:14
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch 2 times, most recently from 327097e to 3c6de40 Compare January 12, 2024 13:04
@SharglutDev SharglutDev marked this pull request as ready for review January 12, 2024 13:05
@SharglutDev SharglutDev requested review from a team as code owners January 12, 2024 13:05
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch 2 times, most recently from 6efc220 to 34ce707 Compare January 12, 2024 13:21
@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch from 34ce707 to d465913 Compare January 12, 2024 13:41
@younesschrifi younesschrifi requested a review from a team as a code owner January 12, 2024 14:16
@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch 3 times, most recently from e6733c3 to 7111bcd Compare January 12, 2024 14:42
tests/tests/test_train_schedule.py Show resolved Hide resolved
tests/tests/test_train_schedule.py Show resolved Hide resolved
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch from 7111bcd to 4173b42 Compare January 12, 2024 18:49
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch from f76f689 to cd8f350 Compare January 16, 2024 11:18
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch from cd8f350 to 79ef676 Compare January 16, 2024 11:27
@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch 2 times, most recently from 1caaa90 to 2bed00e Compare January 17, 2024 08:45
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch 2 times, most recently from b38b6c5 to 58c8d30 Compare January 18, 2024 13:07
Copy link
Contributor

@leovalais leovalais left a comment

Choose a reason for hiding this comment

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

A few comments to apply, but besides that: 🚀 (tested)

editoast/src/views/train_schedule/mod.rs Outdated Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Show resolved Hide resolved
editoast/src/views/train_schedule/mod.rs Show resolved Hide resolved
@SharglutDev SharglutDev force-pushed the yci/update-get_simulation_results_arg branch from a322d78 to 782db10 Compare January 18, 2024 18:52
@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch from 782db10 to cbe6605 Compare January 19, 2024 10:24
Copy link
Contributor

@Math-R Math-R left a comment

Choose a reason for hiding this comment

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

lgtm

@younesschrifi younesschrifi force-pushed the yci/update-get_simulation_results_arg branch from cbe6605 to 17e95ce Compare January 22, 2024 09:31
@younesschrifi younesschrifi added this pull request to the merge queue Jan 22, 2024
Merged via the queue into dev with commit 0eb6323 Jan 22, 2024
20 checks passed
@younesschrifi younesschrifi deleted the yci/update-get_simulation_results_arg branch January 22, 2024 10:20
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.

Moving a train on GET shouldn't refresh all simulation
6 participants