Closed santiagorg2401 closed 3 years ago
I just tested it and it seems to work. Did you forget to call source devel/setup.bash
in the terminal that you use to launch the script from?
Hi, I sourced in the terminals when I got the error, it only happens in non-simulations execution, in other words, when running with --sim it doesn't happen.
I had this issue on Ubunut 16.04 with Python 2. It might be related to this, tl;dr, python confuses the file name and the ros package name.
I solved it by renaming pycrazyswarm/crazyswarm.py
to pycrazyswarm/crazyswarm_py.py
, and editing pycrazyswarm/__init__.py
: instead of from .crazyswarm import *
use from .crazyswarm_py import *
.
I did test with real flight. The --sim
option actually doesn't use ROS at all and therefore doesn't try to import the service description. I tested on Ubuntu 20.04, ROS Noetic, Python 3.
I forgot to tell you my Ubuntu version (my bad), I have Ubuntu 18.04, ROS Melodic & Python 2.
Yes, this seems to be a Python 2 issue.
Well, I installed Ubuntu 20 but now I have trouble installing, however, I'll open another issue for that.
I had this issue on Ubunut 16.04 with Python 2. It might be related to this, tl;dr, python confuses the file name and the ros package name. I solved it by renaming
pycrazyswarm/crazyswarm.py
topycrazyswarm/crazyswarm_py.py
, and editingpycrazyswarm/__init__.py
: instead offrom .crazyswarm import *
usefrom .crazyswarm_py import *
.
Using Melodic on Ubuntu 18.04 with python 2 I was having this same "No module named srv" import error. Renaming these files and removing pycrazyswarm.pyp fixed it for me.
I saw this today too. I am guessing this bug was introduced by 9037a25c8390fbc68f1dc335f8131545d6cb6012. We should rename the file, I think.
It would be nice if we could catch bugs like this in CI. In descending order of usefulness (and effort), we could...
Crazyswarm
objectfailing test for option 3 (see previous comment) added in https://github.com/USC-ACTLab/crazyswarm/tree/rosCI_rebase
Fixed and tested on u16 and u20.
Hi, I hope you're all doing well, I am having trouble with the latest update, I re-installed everything related to crazyswarm on my PC but now when I try to run a script (even with the provided ones) I get:
I already tried re-installing again several times but that didn't work.
Thank you for your time.