Comments (14)
By default I don't have dcsdkgen
in my path and I always need to do:
export PATH=$PATH:$HOME/.local/bin
which dcsdkgen
~/.local/bin/dcsdkgen
from mavsdk-python.
Thanks for the feedback @IeiuniumLux.
@JonasVautherin I think we should add that to the docs.
from mavsdk-python.
I don't install it system wide, I install it as a user, and that path is not added by default.
from mavsdk-python.
Did you install the prerequisites before running ./other/tools/run_protoc.sh
?
I just ran the following successfully on my computer:
cd /tmp
git clone https://github.com/dronecode/dronecodesdk-python --recursive
cd dronecodesdk-python
pip3 install -r requirements.txt -r requirements-dev.txt
./other/tools/run_protoc.sh
from mavsdk-python.
@JonasVautherin, thank you for creating this a new issue. Yes, I ran successfully all those steps, except for the last one (./other/tools/run_protoc.sh). I'm using Python 3.6.8 and pip 18.1. In the instructions, it's not clear if DronecodeSDK-Python needs to be cloned underneath the DronecodeSDK repo or parallel to it. I did both, and run_protoc.sh still fails.
git clone https://github.com/dronecode/dronecodesdk-python --recursive
cd dronecodesdk-python
pip3 install -r requirements.txt -r requirements-dev.txt
from mavsdk-python.
In the instructions, it's not clear if DronecodeSDK-Python needs to be cloned underneath the DronecodeSDK repo or parallel to it.
It is a separate repo, and should be treated as such. Otherwise I guess it would either be part of DronecodeSDK, or at least a submodule :-). Just clone them separately, that's better 👍.
From your screenshot, I see that jmavsim is running, the backend succeeded in discovering it, and the python module is not there (obviously, because run_protoc.sh
failed).
I did both, and run_protoc.sh still fails.
Do you always get exactly the same message as you pasted above? Did pip install
run successfully?
from mavsdk-python.
Do you always get exactly the same message as you pasted above? Did
pip install
run successfully?
Yes, I do always get exactly the same message and 'pip install' ran successfully without reporting any issues. I tried to run 'python -m grpc_tools.protoc' from the prompt, but it fails since files were not generated by run_protoc.sh
One extra note, I'm not running DronecodeSDK out of master. Instead, I checked out v0.14.2 (git checkout v0.14.2).
from mavsdk-python.
It's a good idea to checkout the latest release v0.14.2
instead of master
👍.
I tried to run 'python -m grpc_tools.protoc' from the prompt, but it fails since files were not generated by run_protoc.sh
So this runs protoc
, which requires some arguments (including input files). So this error message is normal (you could run e.g. python3 -m grpc_tools.protoc -h
).
The error message says:
: program not found or is not executable
I am wondering if $(which dcsdkgen) just does not find our plugin (dcsdkgen
, in proto/pb_plugins
), and results in ""
, which then gets executed by protoc
. So the error message says that ""
is not executable, which makes sense. And dcsdkgen
is supposed to be installed by run_protoc.sh
(here).
What do you think?
from mavsdk-python.
dcsdkgen was indeed installed:
from mavsdk-python.
dcsdkgen was indeed installed:
This doesn't mean it was installed. It means that the submodule is there. I guess which dcsdkgen
says something like dcsdkgen not found
, doesn't it?
Are you installing stuff on the system or in a venv? If installing on the system, you could try the following:
cd proto/pb_plugins
pip install -r requirements.txt
pip install -e .
which dcsdkgen
from mavsdk-python.
you could try the following:
cd proto/pb_plugins pip install -r requirements.txt pip install -e . which dcsdkgen
I'm installing on the system, outputs below:
[abencomo: pb_plugins]$ pip install -r requirements.txt
Requirement already satisfied: protobuf in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from -r requirements.txt (line 1)) (3.7.0)
Requirement already satisfied: jinja2 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from -r requirements.txt (line 2)) (2.10)
Requirement already satisfied: setuptools in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->-r requirements.txt (line 1)) (40.8.0)
Requirement already satisfied: six>=1.9 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->-r requirements.txt (line 1)) (1.12.0)
Requirement already satisfied: MarkupSafe>=0.23 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from jinja2->-r requirements.txt (line 2)) (1.1.0)
pip install -e .
Obtaining file:///Users/abencomo/git/DronecodeSDK/DronecodeSDK-Python/proto/pb_plugins
Requirement already satisfied: protobuf in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from dcsdkgen==0.1a0) (3.7.0)
Requirement already satisfied: jinja2 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from dcsdkgen==0.1a0) (2.10)
Requirement already satisfied: six>=1.9 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->dcsdkgen==0.1a0) (1.12.0)
Requirement already satisfied: setuptools in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->dcsdkgen==0.1a0) (40.8.0)
Requirement already satisfied: MarkupSafe>=0.23 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from jinja2->dcsdkgen==0.1a0) (1.1.0)
Installing collected packages: dcsdkgen
Found existing installation: dcsdkgen 0.1a0
Uninstalling dcsdkgen-0.1a0:
Successfully uninstalled dcsdkgen-0.1a0
Running setup.py develop for dcsdkgen
Successfully installed dcsdkgen
[abencomo: pb_plugins]$ which dcsdkgen
nothing when I enter 'which dcsdkgen'
from mavsdk-python.
Hmm. And can you find it on your system somewhere? You are on the master branch of DronecodeSDK-Python, right?
Maybe you could also try to install it in a venv instead of the system?
from mavsdk-python.
By default I don't have
dcsdkgen
in my path and I always need to do:export PATH=$PATH:$HOME/.local/bin
That did it. Thanks @julianoes
@JonasVautherin, feel free to close this issue and thank you.
Requirement already satisfied: protobuf in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from dcsdkgen==0.1a0) (3.7.0)
Requirement already satisfied: jinja2 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from dcsdkgen==0.1a0) (2.10)
Requirement already satisfied: setuptools in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->dcsdkgen==0.1a0) (40.8.0)
Requirement already satisfied: six>=1.9 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from protobuf->dcsdkgen==0.1a0) (1.12.0)
Requirement already satisfied: MarkupSafe>=0.23 in /opt/local/Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from jinja2->dcsdkgen==0.1a0) (1.1.0)
Installing collected packages: dcsdkgen
Running setup.py install for dcsdkgen ... done
Successfully installed dcsdkgen-0.1a0
[+] Done
[+] Generating plugins from
-> [+] Generated protobuf and gRPC bindings for action
-> [+] Generated plugin for action
-> [+] Generated protobuf and gRPC bindings for calibration
-> [+] Generated plugin for calibration
-> [+] Generated protobuf and gRPC bindings for camera
-> [+] Generated plugin for camera
-> [+] Generated protobuf and gRPC bindings for core
-> [+] Generated plugin for core
-> [+] Generated protobuf and gRPC bindings for discovery
-> [+] Generated plugin for discovery
-> [+] Generated protobuf and gRPC bindings for gimbal
-> [+] Generated plugin for gimbal
-> [+] Generated protobuf and gRPC bindings for info
-> [+] Generated plugin for info
-> [+] Generated protobuf and gRPC bindings for mission
-> [+] Generated plugin for mission
-> [+] Generated protobuf and gRPC bindings for telemetry
-> [+] Generated plugin for telemetry
[+] Done
from mavsdk-python.
@julianoes: Thanks a lot!
So installing a python package system-wide doesn't put it in the PATH? What's the point of installing it on the system then?
from mavsdk-python.
Related Issues (20)
- How to detect offboard command completion HOT 3
- One `mavsdk_server`, multiple drones HOT 2
- install mavsdk on py zero HOT 6
- "import_qgroundcontrol_mission_from_string" function not parsing the altitude correctly HOT 1
- drone.info.get_version() INFORMATION_NOT_RECEIVED_YET HOT 8
- FILE_DOES_NOT_EXIST on calling the drone.ftp.list_directory() to fetch internal directories file HOT 13
- The use of drone.offboard.set_position_ned HOT 9
- Unable to upload rally_items through MAVSDK HOT 10
- Error when uploading mission: INVALID_PARAM1 HOT 6
- `aiogrpc` RuntimeError HOT 35
- Running missions in ArduPilot HOT 12
- How to use mavsdk-python to takeoff without GPS HOT 4
- How do I use `telemetry_server` correctly? HOT 4
- Analyzing log files or Distance travelled data from mavsdk python HOT 5
- Geofence crashes with the only information being "Error" HOT 1
- connectivity HOT 5
- Support custom COMMAND_LONG listeners and be able to ACK HOT 6
- can't connect to QGC via UDP connection using mavsdk HOT 3
- Get HEARTBEAT message from MAVSDK HOT 5
- How to use Mavsdk to call Led_control to control LED lights? HOT 2
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 mavsdk-python.