psr_21-22 icon indicating copy to clipboard operation
psr_21-22 copied to clipboard

ImportError: cannot import name '**' from '**' (unknown location)

Open MartinRivadeneira opened this issue 3 years ago • 3 comments

Good afternoon!

Today I was trying to develop some functionalities and for that I cloned some ros packages from the internet, but some of them weren't working and gave problems. In the end, I erased all these packages, but when I tried to run my code I'm getting a new error.

So I developed a ROS msg called "detection_info.msg", and it is recognize by rosmsg list and the catkin_ws also compile when I run the command "catkin_make", but then, when I try to run the node that uses this message, it shows the following error: image

I've been trying to solve this, but I really don't know how. The message is also recognized by pycharm: image

I don't know if the problem has something to do with the fact that I tried to compile some packages that weren't working, but now it's in fact compiling but still doesn't recognize the message.

Thank you for your help!

Martin

MartinRivadeneira avatar Feb 21 '22 18:02 MartinRivadeneira

@miguelriemoliveira

MartinRivadeneira avatar Feb 21 '22 18:02 MartinRivadeneira

Hi @MartinRivadeneira ,

not sure what is going on ... can you compile with catkin_make?

Do you have the message listed when you run

ros msg list

miguelriemoliveira avatar Feb 22 '22 15:02 miguelriemoliveira

Yes, I can compile without problem and the message does appear in roosmsg list…. I can’t understand what the problem is…

MartinRivadeneira avatar Feb 22 '22 15:02 MartinRivadeneira