-
Notifications
You must be signed in to change notification settings - Fork 165
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
flake8: DeprecationWarning: SelectableGroups dict interface is deprec… #868
Conversation
…ated. Ref: #867 Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
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.
since we cannot control flake8
implementation, this suppresses the warning in our test code. this makes all package test green.
root@tomoyafujita:~/ros2_ws/colcon_ws# colcon test --event-handlers console_direct+ --packages-select ros2component
Starting >>> ros2component
============================= test session starts ==============================
platform linux -- Python 3.10.12, pytest-6.2.5, py-1.10.0, pluggy-0.13.0
cachedir: /root/ros2_ws/colcon_ws/build/ros2component/.pytest_cache
rootdir: /root/ros2_ws/colcon_ws/src/ros2/ros2cli, configfile: pytest.ini
plugins: ament-xmllint-0.16.0, ament-copyright-0.16.0, ament-pep257-0.16.0, ament-flake8-0.16.0, ament-lint-0.16.0, rerunfailures-10.2, cov-3.0.0, mock-3.6.1, repeat-0.9.1, colcon-core-0.15.0, timeout-2.1.0
timeout: 900.0s
timeout method: thread
timeout func_only: False
collecting ...
collected 6 items
test/test_api.py .. [ 33%]
test/test_copyright.py . [ 50%]
test/test_flake8.py . [ 66%]
test/test_pep257.py . [ 83%]
test/test_xmllint.py . [100%]
-- generated xml file: /root/ros2_ws/colcon_ws/build/ros2component/pytest.xml --
============================== 6 passed in 1.54s ===============================
Finished <<< ros2component [2.24s]
Summary: 1 package finished [3.12s]
How about updating the diff --git a/pytest.ini b/pytest.ini
index 2fb26a8..9d367c8 100644
--- a/pytest.ini
+++ b/pytest.ini
@@ -2,3 +2,5 @@
junit_family=xunit2
timeout=900
timeout_method=thread
+filterwarnings=ignore:SelectableGroups:DeprecationWarning
|
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.
I have no idea if the python3-flake8
in the jammy will remove the warning or not.
(Maybe it's the deprecation cycle for the jammy, and the warning will be removed in the latter Ubuntu distribution.)
This PR will fix the warning issue, so I'd like to aprrove it.
I suspect not. It's been there for 2 years, so I don't think that it is going to be fixed in Ubuntu until 24.04. |
I think we should try doing this to see if it works. That will just make it easier to remove the filter for Ubuntu 24.04. |
…s deprecated." This reverts commit c22551f. Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com>
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com> Co-authored-by: Chen Lihui <lihui.chen@sony.com>
@iuhilnehc-ynos @clalancette |
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.
Overall I like this approach. I left one thing to fix inline.
Signed-off-by: Tomoya Fujita <Tomoya.Fujita@sony.com> Co-authored-by: Chris Lalancette <clalancette@gmail.com>
…ated.
address #867