Skip to main content
````
Source Link
gsmafra
  • 183
  • 2
  • 7

Weird behaviour when setting Setting environment variables with .bash_profile: only last export works properly

I am trying to export some environment variables in Unix using the .bash_profile.bash_profile

Then I exit python, re-run manually the first line of .bash_profile.bash_profile and it works.

Which indicates that export LD_LIBRARY_PATHLD_LIBRARY_PATH didn't work. I do the same procedure as before, exit python re-run the first line and then it imports correctly.

I've actually solved this issue by re-setting the PATHPATH variable inside the python script, but it bothers me that I can't find the reason why this is happening

Weird behaviour when setting environment variables with .bash_profile: only last export works properly

I am trying to export some environment variables in Unix using the .bash_profile

Then I exit python, re-run manually the first line of .bash_profile and it works.

Which indicates that export LD_LIBRARY_PATH didn't work. I do the same procedure as before, exit python re-run the first line and then it imports correctly.

I've actually solved this issue by re-setting the PATH variable inside the python script, but it bothers me that I can't find the reason why this is happening

Setting environment variables with .bash_profile: only last export works properly

I am trying to export some environment variables in Unix using .bash_profile

Then I exit python, re-run manually the first line of .bash_profile and it works.

Which indicates that export LD_LIBRARY_PATH didn't work. I do the same procedure as before, exit python re-run the first line and then it imports correctly.

I've actually solved this issue by re-setting the PATH variable inside the python script, but it bothers me that I can't find the reason why this is happening

edited tags
Link
Gilles 'SO- stop being evil'
  • 865.3k
  • 205
  • 1.8k
  • 2.3k
edited body
Source Link
gsmafra
  • 183
  • 2
  • 7

Then I exit python, and re-run manually the first line of .bash_profile and it works.

I've tried doing echo commmands on the variables and it was printing normally as if they were correctly set, but I'm unable to use them with python. Also, when re-setting them manually that doesn't double export them, but re-re-setting does:

Then I exit python, and re-run manually the first line of .bash_profile it works.

I've tried doing echo commmands on the variables and it was printing normally as if they were correctly set, but I'm unable to use them with python. Also, when re-setting them manually doesn't double export them, but re-re-setting does:

Then I exit python, re-run manually the first line of .bash_profile and it works.

I've tried doing echo commmands on the variables and it was printing normally as if they were correctly set, but I'm unable to use them with python. Also, when re-setting them manually that doesn't double export them, but re-re-setting does:

deleted 1 character in body
Source Link
gsmafra
  • 183
  • 2
  • 7
Loading
Source Link
gsmafra
  • 183
  • 2
  • 7
Loading