Python 3.10: launch_testing has a warning of "There is no current event loop"

Aperta
#613 1 commento 1 reazione 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
35/100
Tipo di issue
Bug
Chiarezza
Abbastanza chiara
Stato di attività
Ferma
Stack tecnologico
python

Direzione di ricerca

Riproduci l’avviso con il checkout di joint_state_publisher fornito e i comandi colcon test. Esamina la gestione del ciclo degli eventi in launch, launch_ros e osrf_pycommon, quindi verifica che i test interessati continuino ad avere esito positivo senza l’avviso “There is no current event loop”.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

help wanted

Bug report

Required Info:

  • Operating System:
    • Ubuntu 22.04 arm64
  • Installation type:
    • source
  • Version or commit hash:
    • d2935d6fd85636ace62699eec106cd56f5e9c6a4
  • DDS implementation:
    • Fast-RTPS
  • Client library (if applicable):
    • rclpy
Steps to reproduce issue
$ . /opt/ros/humble/setup.bash
$ mkdir -p jsp_ws/src
$ cd jsp_ws
$ git clone https://github.com/ros/joint_state_publisher -b ros2 src/joint_state_publisher
$ colcon build
$ colcon test
Expected behavior

Tests run and succeed without warning

Actual behavior

Tests run, and succeed, but have warnings like:

=============================== warnings summary ===============================
test/test_64_joint_robot.py: 2 warnings
test/test_mimic_chain.py: 2 warnings
test/test_mimic_cycle.py: 2 warnings
test/test_multi_joints.py: 2 warnings
test/test_zero_joints.py: 2 warnings
  Warning: There is no current event loop
Additional information

This seems to be a change in Python 3.10. In particular, I think that calling get_event_loop without a loop running is now an error. See https://github.com/pytest-dev/pytest-asyncio/issues/212 for some explanation of this. We probably need fixes in launch, launch_ros, and osrf_pycommon (at least).

Lingua principale
Python
Stelle
156
Fork
200
Merge medio
2g 11h
PR unite (30g)
11

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di ros2/launch

Tutte le issue di ros2/launch

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.