Skip to content

Commit

Permalink
makepanda: locate setup.cfg using __file__, not working directory.
Browse files Browse the repository at this point in the history
This fixes the buildbots, which import makewheel from inside the makepanda directory.
  • Loading branch information
rdb committed Nov 3, 2017
1 parent 3f0ab1d commit 0343dbc
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion makepanda/makepandacore.py
Expand Up @@ -2858,7 +2858,8 @@ def GetMetadataValue(key):
if not cfg_parser:
# Parse the metadata from the setup.cfg file.
cfg_parser = configparser.ConfigParser()
cfg_parser.read('setup.cfg')
path = os.path.join(os.path.dirname(__file__), '..', 'setup.cfg')
assert cfg_parser.read(path), "Could not read setup.cfg file."

value = cfg_parser.get('metadata', key)
if key == 'classifiers':
Expand Down

0 comments on commit 0343dbc

Please sign in to comment.