Black rolls out style changes every year, and using "stable" means that
the check run on PRs might start formatting differently than we do
locally, or require a reformat of the codebase to make a PR submittable.
Pin to the version that we've been using. We should update to 23 at some
point, but we want to do that deliberately.
This is the first step toward bundling all assets related to a save game
into a single item. That makes it easier to avoid clobbering "temporary"
assets from other games like the state.json, but also makes it easier
for players to file bug reports, since there's only a single asset to
upload.
This is only the first step because so far it only includes the various
save files: start of turn, end of last turn before results processing,
and "latest" (the game saved explicitly by the player).
It sounds like PySide2 will not be moving to Python 3.11, so we're stuck
on 3.10 without this. Upgrading to a newer Qt also fixes some high DPI
bugs (the file browser dialog for save/load is no longer tiny on 4k).
https://github.com/pyinstaller/pyinstaller/issues/5414 previously
blocked this, but the bug appears to be fixed now.
We often get save games uploaded with bug reports that are already in a
broken state with nothing we can do about it. This saves that turn to
`last_turn.liberation` so users are less likely to have clobbered the
useful data before filing the report.
The workflow UI works best if there's only a single main workflow in a
PR. We can keep things organized similarly by turning the test workflow
into a reusable workflow. Same code (mostly), better UI.
This is just the first step to prove the concept. Most of the work done
in our workflows can be split into separate jobs to parallelize the
workflow. This will also make the checks page more readable.
This change alone probably won't speed up CI much.
Shapely doesn't have a Windows wheel on pypi yet, but we can get them
from https://www.lfd.uci.edu/~gohlke/pythonlibs/#shapely. This unblocks
(and because wheels are matched to python versions, *requires*)
upgrading to Python 3.10.
GitHub has limits on the number of files that can be used with
upload-artifact, and it sounds like it will also be faster to compress
locally before uploading.
The upload-artifact version 2.3 has problems with 0byte files and prevent the build action from beeing completed.
This temporary fix should be reverted when they fixed the bug.
This appears to be incompatible with pyinstaller. I get the following
when trying to run the executable generated with pyside6:
```
Traceback (most recent call last):
File "qt_ui\main.py", line 29, in <module>
File "PyInstaller\loader\pyimod03_importers.py", line 476, in exec_module
File "qt_ui\windows\QLiberationWindow.py", line 28, in <module>
File "PyInstaller\loader\pyimod03_importers.py", line 476, in exec_module
File "qt_ui\widgets\map\QLiberationMap.py", line 11, in <module>
ImportError: could not import module 'PySide6.QtPrintSupport'
```
* Use TACAN channels more selectively
* Increase tacan range to 126
* Use pytest and add workflow
* Skip faction tests due to outdated test data
* Run mypy on tests directory also
* Use iterators for bands AND usages, add tests