Comments (16)
Yes, but if that is all you have in your Python file then the behaviour is undefined. You are opening PyRep and then the python program is quitting because it reached the end of the program. Each launch
should eventually be followed by a shutdown
.
Have you tried running the example in the examples folder?
from pyrep.
Yes you are right, I did not understand that the use of shutdown is mandatory, so I did not include it.
Thank you for helping me though.
from pyrep.
Hi.
Could you try: sudo apt-get install qt5-default
If that doesn't work, could you give me some more info about when you get this error? And do you still get it when launching V-REP without using PyRep?
from pyrep.
Hi Stephen,
Thank you for your quick reply.
The error occurs once I launch the .ttt file:
pr = PyRep()
pr.launch(SCENE_FILE, headless=False)
If I don't use PyRep then I don't get this error.
from pyrep.
Is it possible that is related with the fact that I am using Wayland ?
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway
But I don't get any error when using the V-REP without PyRep.
If it is related do you know how to fix this warning.
Thank you
from pyrep.
Is it possible that is related with the fact that I am using Wayland ?
Yes it could be. Can you tell me the output of echo $QT_QPA_PLATFORM_PLUGIN_PATH
please?
from pyrep.
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04
from pyrep.
OK. I'm not sure what is happening.
Could you try running PyRep in blocking mode and see if that launches?
pr = PyRep()
pr.launch(blocking=True, headless=False)
from pyrep.
I get following message:
File "/home/george/.local/lib/python3.6/site-packages/pyrep/pyrep.py", line 162, in start
raise PyRepError('V-REP has not been launched. Call launch first.')
pyrep.errors.PyRepError: V-REP has not been launched. Call launch first.
QObject::~QObject: Timers cannot be stopped from another thread
from pyrep.
That can't be right. When launching pyrep in blocking mode, the launch function does not return, so how are you calling start?
from pyrep.
Everything is running on one thread/process, right?
from pyrep.
pr = PyRep()
print('hello2')
pr.launch(SCENE_FILE, blocking=True, headless=False)
print('hello1')
pr.start()
When running the above code, then it is stuck on the 3rd line. However, when closing the v-rep manually, then I get the above posted message in the terminal.
Can you please tell me how do I check whether it is running on one thread ?
from pyrep.
When you launch in blocking mode, it is as if you are launching V-REP from the terminal as normal. So calling start after closing in 'blocking' mode doesn't make sense (as you have already killed V-REP).
So after running launch (in blocking mode), V-REP appears with no errors?
from pyrep.
Yes V-REP appears with no errors, however some methods that are later defined, for example add object to the scene, are not getting executed,
from pyrep.
however some methods that are later defined, for example add object to the scene, are not getting executed
Yes that is expected behaviour when running in blocking mode. The function will never return (until you close V-REP).
Your error is very strange in that case; I would have expected it to crash in the same way (with the error signal 11).
Going back to running in non-blocking mode: you are certain that it is crashing during the call to launch?
from pyrep.
well I run the below segment of code:
SCENE_FILE = join(dirname(abspath(file)), 'my_scene3.ttt')
pr = PyRep()
pr.launch(SCENE_FILE, headless=False)
And at the traceback I have either:
QObject::~QObject: Timers cannot be stopped from another thread
QMutex: destroying locked mutex
or
Error: signal 11:
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libv_rep.so.1(_Z11_segHandleri+0x2b)[0x7ff87b2810eb]
/lib/x86_64-linux-gnu/libc.so.6(+0x3ef20)[0x7ff89cc8cf20]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Core.so.5(_ZN6QMutex4lockEv+0x15)[0x7ff878d7b0b5]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Gui.so.5(+0x379f7e)[0x7ff879da0f7e]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Gui.so.5(+0x37183f)[0x7ff879d9883f]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Gui.so.5(_ZN18QRasterPaintEngine11updateBrushERK6QBrush+0x87)[0x7ff879d9bcd7]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Gui.so.5(_ZN18QRasterPaintEngine8fillRectERK6QRectFRK6QBrush+0x2a)[0x7ff879d9c7aa]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Gui.so.5(_ZN8QPainter8fillRectERK5QRectRK6QBrush+0xc5)[0x7ff879daf5d5]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Widgets.so.5(_ZNK12QFusionStyle18drawComplexControlEN6QStyle14ComplexControlEPK19QStyleOptionComplexP8QPainterPK7QWidget+0x31a7)[0x7ff87a488ea7]
/home/george/Desktop/V-REP_PRO_EDU_V3_6_2_Ubuntu18_04/libQt5Widgets.so.5(+0x202bdb)[0x7ff87a44fbdb]
QMutex: destroying locked mutex
I am not sure why there are 2 different error messages but I am sure that is provoked during the launch.
from pyrep.
Related Issues (20)
- No module named 'pyrep.backend._sim_cffi' HOT 2
- Error when I install package HOT 1
- Broken download URLs HOT 2
- Where is my_pyrep_app.py?
- Can I run PyRep on Ubuntu 22.04 HOT 3
- Get some problems when adding my own robot
- How to call the child script in CoppeliaSim
- krb5 error
- import cv2 HOT 1
- Scene launch with absolute path is empty HOT 1
- all zero action fed in get_linear_path, output a non-stationary path HOT 1
- set_joint_target_positions()
- errors happen when running the example
- errors happen when running the example HOT 1
- Inverse kinematics solving failed.
- fatal error LNK1181: Unable to open the input file “coppeliaSim.lib” error:
- 在运行Running Headless中Ubuntu20.04重启失败,黑屏
- terminate called after throwing an instance of 'std::length_error' what(): basic_string::_M_replace
- ImportError: cannot import name 'PyRep' from 'pyrep'
- PR for RuntimeWarning: divide by zero encountered in scalar divide HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pyrep.