-2

I am trying to build a project with scons on Eclipse. When I do, the command line outputs the following:

Traceback (most recent call last):
  File "<<<scons-location>>>/scons", line 5, in <module>
    from SCons.Script.Main import main
ModuleNotFoundError: No module named 'SCons'

I noticed that the SCons folder is installed somewhere else in the system, but I just don't know how to tell Eclipse where to find it. I tried putting its location onto the path.

Thanks in Advance!

pscarpati
  • 48
  • 1
  • 9
  • Does this answer your question? [Adding python modules to pydev in eclipse results in import error?](https://stackoverflow.com/questions/6070423/adding-python-modules-to-pydev-in-eclipse-results-in-import-error) – Thyrus Dec 07 '21 at 11:31
  • None of the suggestions in that post helped, unfortunately :( – pscarpati Dec 07 '21 at 12:52
  • How did you install SCons on your system? Which Python? Which version of SCons? What Distro/Release? What command line is Eclipse trying to run to run SCons? – bdbaddog Dec 07 '21 at 22:35
  • @bdbaddog , SCons was installed with Pip (Python3.6). The version of SCons is 4.3.0. – pscarpati Dec 08 '21 at 09:11
  • What's the command line eclipse is using to run scons? Is eclipse pointing at the python you installed scons with? – bdbaddog Dec 09 '21 at 20:33

1 Answers1

0

The answer I found that worked with my specific case had to do with the PYTHONUSERBASE environment variable being modified at the wrong time, and in the wrong way. Fixing that also fixed the issue. Thanks to anyone who helped!

pscarpati
  • 48
  • 1
  • 9