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

Fixed Enemy Picker Logic And Added Faction Validation #6278

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

IllianiCBT
Copy link
Collaborator

  • Updated conditional logic to consistently exclude the ROS faction after the FORTRESS_REPUBLIC date.
  • Added error handling in AtBDynamicScenarioFactory:
    • Logged an error and set a fallback faction if the faction code is blank.
    • Logged an error and aborted force generation if the faction is null.

Dev Notes

I stumbled onto this completely by accident. But basically, ROS isn't a valid employer or enemy once the Wall goes up. However, there was a single missed instance where the Republic could still be chosen as an enemy. However, because it wasn't valid the faction would be null resulting in a bunch of unfortunate weirdness.

While investigating this I also added some null faction protection to force generation.

Marking this as 'high' as this issue is most prevalent in ilClan, the current era.

- Updated conditional logic to consistently exclude the ROS faction after the FORTRESS_REPUBLIC date.
- Added error handling in `AtBDynamicScenarioFactory`:
  - Logged an error and set a fallback faction if the faction code is blank.
  - Logged an error and aborted force generation if the faction is null.
@IllianiCBT IllianiCBT added Bug Severity: High Issues described as high severity as per the new issue form labels Mar 14, 2025
@IllianiCBT IllianiCBT self-assigned this Mar 14, 2025
@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 10.88%. Comparing base (0433438) to head (cd733e9).
Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff            @@
##             master    #6278   +/-   ##
=========================================
  Coverage     10.87%   10.88%           
- Complexity     6261     6263    +2     
=========================================
  Files          1065     1065           
  Lines        141018   141028   +10     
  Branches      21021    21025    +4     
=========================================
+ Hits          15339    15346    +7     
- Misses       124138   124141    +3     
  Partials       1541     1541           

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

🚀 New features to boost your workflow:
  • Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Severity: High Issues described as high severity as per the new issue form
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants