micro-ROS / micro-ROS/system_modes
UserWarning: Unknown distribution option: 'tests_require'
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- C++
- Estrellas
- 45
- Forks
- 13
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
-
ROS Version: Humble
-
OS Version: Ubuntu22.04
-
Python Version: 3.10.12
-
setuptools Version: 75.2.0
Hello, when I build this project from source, some warnings occurred.
Hers is the output of the command colcon build:
Starting >>> launch_system_modes
/home/qiguanxiao/.local/lib/python3.10/site-packages/setuptools/_distutils/dist.py:261: UserWarning: Unknown distribution option: 'tests_require'
warnings.warn(msg)
--- stderr: launch_system_modes
/home/qiguanxiao/.local/lib/python3.10/site-packages/setuptools/_distutils/dist.py:261: UserWarning: Unknown distribution option: 'tests_require'
warnings.warn(msg)
---
Finished <<< launch_system_modes [1.53s]
These warnings show the tests_require option is expired. But the python is the default package with ubuntu 22.04 and setuptools is installed by pip.
And then I use colcon test to test this project, there were also some warnings.
Here is the output about the command colcon test:
Starting >>> launch_system_modes
/home/qiguanxiao/.local/lib/python3.10/site-packages/setuptools/_distutils/dist.py:261: UserWarning: Unknown distribution option: 'tests_require'
warnings.warn(msg)
--- stderr: launch_system_modes
----------------------------------------------------------------------
Ran 0 tests in 0.000s
OK
---
Finished <<< launch_system_modes [0.72s]
It seems like that there were no python testing programs to run and no result file pytest.xml was generated in build directory.
Then I tried to modify the setup.py file in package launch_system_modes and replaced the option tests_require with extras_require.
Finally it can be built and test correctly.
Here is the modified content in setpu.py file:
tests_require=['pytest'], # remove
extras_require={
'test': ['pytest'],
}, # add
But there are some format errors after running colcon test. Here is the result:
Now the python and setuptools version are updated very quickly, could you tell me if it is necessary to replace the tests_require option to adapt to the current environment.
Thanks!
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Comience con setup.py en el paquete launch_system_modes y reproduzca la salida reportada de colcon build y colcon test utilizando las versiones indicadas de ROS, Ubuntu, Python y setuptools. Compare la configuración actual de tests_require con el cambio reportado en extras_require y, a continuación, use launch_system_modes.log y el directorio build para determinar si se han resuelto la advertencia, la ejecución de las pruebas y la salida de pytest.xml.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- python
- Área
- build-system, testing
- Tipo de issue
- Error
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 45/100