Enable Python test GitHub actions workflow on the windows-latest runner and fix several Windows compatibility issues: - #500
Merged
Conversation
…nner and fix several Windows compatibility issues: * Rename the `cp437` renderer constants to `utf-8-basic`. The old constants were actually Unicode, and not actually code page 437, so they weren't working as advertised. This removes code page 437 support, since nobody seems to be using it. * Make `render_trace`'s platform detection code more reliable. * Fix `test_examples.py`'s path handling so it works on Windows. * Don't use `render_trace` in doctests outside of `Simulation`, and disable `Simulation` doctests when Unicode is not supported. `Simulation` doctest examples expect Unicode output for `render_trace`. * Fix `examples` so they don't require Unicode. * Fix `justfile` to work on Windows. * Add doctests for `Simulation` and `Simulation.step`.
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## development #500 +/- ##
=============================================
- Coverage 93.8% 93.8% -0.0%
=============================================
Files 30 30
Lines 7138 7141 +3
=============================================
+ Hits 6690 6692 +2
- Misses 448 449 +1 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
…PYRTL_RENDERER=utf-8-basic`.
Contributor
Author
|
I also tested this PR manually by running |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rename the
cp437renderer constants toutf-8-basic. The old constants were actually Unicode, and not actually code page 437, so they weren't working as advertised. This removes code page 437 support, since nobody seems to be using it.Make
render_trace's platform detection code more reliable.Fix
test_examples.py's path handling so it works on Windows.Don't use
render_tracein doctests outside ofSimulation, and disableSimulationdoctests when Unicode is not supported.Simulationdoctest examples expect Unicode output forrender_trace.Fix
examplesso they don't require Unicode.Fix
justfileto work on Windows.Add doctests for
SimulationandSimulation.step.