Comments (7)
I use virtualenv as well and it is a known problem how to handle these. The work around however, is to set the PYTHON_BASE to your desired Python interpreter (e.g. your virtualenv one) and that will override the Makefile system set one. It becomes a little more work if your doing multiple environments.
Also you can try using virtualenvwrapper tool which allows controlling the environmental variables on a per virtual env occurance. See https://realpython.com/python-virtual-environments-a-primer/#managing-virtual-environments-with-virtualenvwrapper. I have not tried this but if it helps and works out let me know.
from fprime.
Do you have any idea about the problem we had when we just to run python
, assuming that users has properly set up their environment?
from fprime.
Currently, PYTHON_BASE is embedded in our sample shell scripts. It should be fairly simple to fix this, and we have it in the works. However for the time being, setting PYTHON_BASE to your virtual environment should work. This is how I work, and it functions pretty well.
I have found a few corner cases where this does break, and fixes are underway for those too.
from fprime.
Any easy fix I was able to implement was to edit the "activate" script in my virtual environment "bin" with the following:
export PYTHON_BASE=$VIRTUAL_ENV
I use python virtualenv, which sets this VIRTUAL_ENV variable. I simply leverage that by setting PYTHON_BASE to it. Currently it looks like the make scripts check for PYTHON_BASE, and use a default value of "/usr" if it's not found. Perhaps it can also check for virtualenvs signature "VIRTUAL_ENV" variable?
from fprime.
Yes, I use that fix for the time-being too. I am working on patch that will remove the dependency on PYTHON_BASE. I will comment here when it is being delivered.
from fprime.
This should be fixed in the latest devel.
from fprime.
Closing.
from fprime.
Related Issues (20)
- Create example fpp-to-dict JSON output based on spec
- add support for building documentation locally
- Add version flag to new --project HOT 2
- Add `fprime-util` version check command HOT 2
- Add Hotfix CI Branches HOT 2
- `register_fprime_executable(NAME)` Fails
- FPRIME_PLATFORM Not Used in `restrict_platforms`
- Remove Dead CMake Targets
- `refresh_cache` Is a UTIL target and should be labeled as such
- JAR Packages Are Broken as-of v3.4.0 HOT 2
- `manylinux_X_Y` Packages Don't Install With Older PIP Versions HOT 2
- _check Targets Miss-Named
- Update PIP Requirements in INSTALL.md HOT 1
- Install Upgraded PIP in new Project
- Add ERT to log files
- Record packet headers
- LinuxGpioDriver Minor Bug HOT 1
- Remove `master` branch
- FIT Framework Assumes CommandDispatcher Name
- FPRIME_PROJECT_ROOT/cmake Not Added to CMake Path
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 fprime.