Skip to content
Chris Barker edited this page Aug 13, 2021 · 10 revisions

Here are some common questions and solutions contributed by our users, to help troubleshoot the installation.

I did a pull and PyGnome fails when importing oil_library - how do I install?

  1. If you have all other dependencies met, rebuilding PyGnome ($python setup.py develop) will install the missing package.

  2. Or you can manually install it by navigating to oil_library and running $python setup.py install. Can also be build in develop mode - it'll install the package and build the oil library database.

I did a pull and tests related to substance that previously passed are now failing?

If oil_library has previously been installed, but some tests related to substance object are failing. Try rebuilding the database as the schema likely updated. This can be done by either running the py_gnome/setup.py or the oil_library/setup.py with the remake_oil_db command: $python setup.py remake_oil_db

Python 2 build notes: PyGNOME uses Python 3 (>=3.8) now -- these notes are obsolete.

On Windows with Visual Studio 2008, why does build fail with 'basetsd.h' file not found error?

If you get the following error, then the Visual Studio 2008 environment is not correctly setup.

C:\Python27\include\pyconfig.h(227) : fatal error C1083: Cannot open include file: 'basetsd.h': No such file or directory

You'll need to manually define the INCLUDE and LIB environment variables:

INCLUDE=“C:\Program Files\Microsoft SDKs\Windows\v6.0A\Include”
LIB=“C:\Program Files\Microsoft SDKs\Windows\v6.0A\Lib”

This problem was seen when user had multiple Visual Studio IDEs installed so the environment was set up for the newer version.

On Windows with Visual Studio 2008, how do I manually set the target compiler environment?

cd to "C:\Program Files (x86)\Microsoft Visual Studio 9.0\VC" and run

> vcvarsall x86 

Again, this problem was seen if user couldn't start with clean 32-bit install of [Python 2.7.5] (http://www.python.org/download/). In this case, there might be a python install with distutils that is perhaps configured for a 64-bit environment.