Read version file directly from setup.py

Before raising this MR, consider whether the following are required, and complete if so:

  • Unit tests
  • Metrics
  • Documentation update(s)

Just a change to setup.py to be more robust/correct.

Description

The current way setup.py gets the version for BuildGrid is to import the _version.py file directly and use that. However this approach is a bit backwards, importing something from the module setup.py is actively trying to install. It also doesn't work if PYTHONPATH doesn't include the location of BuildGrid's source. Instead of worrying about that, just read the file directly which is easier and more likely to work in various situations.

Merge request reports

Loading