-
-
Notifications
You must be signed in to change notification settings - Fork 261
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
ENH: Declare Sprint Qualifying as a quali-like session #572
Conversation
Sprint Qualifying for 2024 is now a Quali-Like session (not Race-Like like before)
Hi, this needs to be defined dependent on the season and can't just be changed globally. Else, we are breaking support for 2018. My solution for this isn't perfect but ok, making these constants instance variables of the Session that are set in init, depending on the year. If you have a better suggesting, I'll gladly take that. Also, there is Norris' reinstated lap, which isn't working as well. So this will take a bit to fix overall, maybe. |
And apparently, there is a keyboard shortcut to close PRs? 😅 |
My bad, I thought this was a situation like with driver/color support where we only target the current year. For now I also think the best solution is to change the behaviour depending on the year. There's not much else to do unfortunately if they reuse the same session name to mean different things in different years...
Yes, a quick fix if anyone has problems is to use |
I think I have both things fixed. Need to check that all tests are still passing and that I haven't missed anything.
I'd prefer not to do that. And it seems straight forward enough to make it season dependent.
I don't remember another event, either. But I'd appreciate it if someone remembers, so I can use it for testing as well. |
I just have an update: see SessionInfo.json, where I've tried with the 2023 Austrian GP, another sprint weekend with the old format: the Sprint Shootout was of type "Qualifying", and the Sprint Race was of type "Race". This seems promising I think, should it be a property of Session, and then instead of using QUALI_LIKE and RACE_LIKE we directly check for that value? |
That's not a bad idea, but I think I'd delay that. It would be great for cleaning up the code a bit and having less hard-coded values. But there are some things that need to be considered additionally.
I'd prefer to not make a change like that right now, as it's more involved, and I don't have the time right now to properly ensure that it works as intended in all scenarios. I'll go with the quick and dirty fix. But I'd really want to consider your suggestion for the future. |
I'll close this PR as the immediate problem was resolved. Regarding the discussion about using the information from SessionInfo.json, I opened #581 so that this idea won't get lost. |
Sprint Qualifying for 2024 is now a Quali-Like session (not Race-Like like before).
Also fixes
Laps.split_qualifying_sessions()
for the Sprint Qualifying