-
Notifications
You must be signed in to change notification settings - Fork 367
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
Don't depend on distutils #1121
base: master
Are you sure you want to change the base?
Conversation
Docs/CHANGELOG.md
Outdated
@@ -15,6 +15,7 @@ | |||
## Upcoming | |||
* Improvements to the CarlaDataProvider: | |||
- Added `spawn_actor` for a blueprint based actor creation similar to `World.spawn_actor` | |||
* Allow using with Python 3.12 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* Allow using with Python 3.12 | |
* Implement `strtobool` formerly included in `distutils`, which is removed in Python 3.12. |
I am certain you checked it with 3.12, however I think its not yet 100% 3.12 ready, e.g. the requirements.txt
file, and the core team should make this stement.
Therefore, I think we should adjust this statement to be more precise on this PR.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, this is better. I'm using this with 3.12, but without the requirements.txt
file, so its content might need some update.
srunner/util.py
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There is a tools
and utilities
folder. I suggest to move this to a tools/strtobool.py
or another fitting file.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Makes sense. Moved.
distutils are no longer available in Python 3.12. Therefore, we copy the strtobool function from distutils to our own module. This is in line with https://peps.python.org/pep-0632/#migration-advice.
272eda3
to
750978e
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 4 of 5 files at r2, all commit messages.
Reviewable status: 4 of 5 files reviewed, 2 unresolved discussions
I tried this branch, but I still get an error during installing of the requirements:
I am under Ubuntu 22.04 and I tried it in a venv with Python 3. |
Can you send the full backtrace? I don't see any occurrence of |
Here is the full output:
|
Checklist:
master
branch and tested with latest changesDescription
distutils are no longer available in Python 3.12. Therefore, we copy the strtobool function from distutils to our own module. This is in line with https://peps.python.org/pep-0632/#migration-advice.
Where has this been tested?
Possible Drawbacks
Hopefully none.
This change is