in reply to running a backticks command behaves different in command line and browser
Try running the env command in the script and at your shell prompt. Any variables matching m/^LD_/ are particularly interesting.
Also try which python3 or which python in both contexts. Are they using the same Python installation?
Also try ldd python3 or ldd python in both cases to see what libraries are being loaded. Your error suggests that the httpd is somehow running Python with a different version of the C++ runtime.
It is very suspicious that the error mentions libstc++ under /opt/lampp/lib but a Python module under /usr/local/lib/python3.7.
If you were having a similar issue with Perl, I would ask if you are using mod_perl, but Perl tends to have better backwards compatibility than this.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: running a backticks command behaves different in command line and browser
by derion (Sexton) on Aug 10, 2019 at 09:32 UTC | |
by haukex (Archbishop) on Aug 10, 2019 at 11:37 UTC | |
by jcb (Parson) on Aug 10, 2019 at 21:17 UTC | |
by haukex (Archbishop) on Aug 11, 2019 at 20:32 UTC | |
by jcb (Parson) on Aug 11, 2019 at 22:44 UTC | |
by haukex (Archbishop) on Aug 12, 2019 at 10:16 UTC |