-
Notifications
You must be signed in to change notification settings - Fork 18
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
Fixes for tests to run under python 311 #23
Fixes for tests to run under python 311 #23
Conversation
3 tests will show as broken in this branch: test_Simulator__init__creates_Vehicle_and_AdapterDataSource_from_parsed_data_and_Agent_with_vehicle_when_SBN_Flag_resolves_to_True test_ExecutionEngine_parse_data_argument_subsystems_breakdown_optional_default_is_False test_ExecutionEngine_parse_data_sets_the_processedSimData_to_the_TimeSynchronizer_which_was_given_the_sim_data_received_from_parsed_data
If a single header is passed, it is passed a MagicMock object, so we are casting it to a list
@kokroo, are you able to run the unit tests locally? |
Yes, I'm using this command from the readme: I hope I didn't do it wrong. I actually tried Python 3.9, 3.11.2 (like you did, to get ride of a few failed tests) and 3.11.4. There's just one extra failed test on 3.11.4 which I've already fixed. I believe we should be running the testing in a 3.11.4 environment since I've already brought it to parity with the failed tests in 3.11.2 I did a really deep dive into why these errors are happening to begin with. Between Python 3.10 and Python 3.11 there were a lot of changes under the hood concerning how objects are stored and represented in memory and how methods and attributes paths are accessed. Even after using a debugger I haven't been able to get rid of 2 tests that are still failing. I suggest we should also update all the dependences to their latest versions, since the versions pinned in the requirements do not support Python 3.11, but the latest versions of the dependencies do support everything including 3.8, 3.9,3.10 and 3.11 and even support for 3.12. |
780698e
to
df01dec
Compare
df01dec
to
346c295
Compare
…te-pytests-to-run-under-python-311
Codecov Report
@@ Coverage Diff @@
## 14-update-pytests-to-run-under-python-311 #23 +/- ##
===========================================================================
Coverage 100.00% 100.00%
===========================================================================
Files 21 21
Lines 917 917
Branches 130 130
===========================================================================
Hits 917 917 |
@kokroo, thank you for the assistance. We wouldn't have understood the problem as well without it. The code has superseded the original issues we were encountering (code and tests changed) and branch 14 was rebased with these changes. I am closing this PR because of those updates. An additional problem was found after the rebase but fixed and noted in #14 with new PR #57. |
@asgibson Thank you, good catch with the str and IDs there. I'm a bit confused now, are there any tests that are still failing after these fixes? If not, I'd even like to test 3.11.x versions as well as 3.12! |
@kokroo, 3.11.2 is now being used with the "unit test run" workflow and all tests are passing. I would definitely like to know what happens when running with 3.12. Thanks for your continued interest! |
Resolve "put coverage into gitignore" Closes nasa#23 See merge request cFS_lab/raisr_nos3/raisr-2.0!9
Ongoing fixes for tests under Python 3.11 are included in this PR.
I will add more commits until all tests are fixed.