Skip to content

Commit

Permalink
Merge pull request #610 from autopkg/python2-warning
Browse files Browse the repository at this point in the history
Generate useful output if AutoPkg detects a Python 2 wrapper
  • Loading branch information
nmcspadden committed Feb 7, 2020
2 parents c859f43 + c137276 commit 5106597
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions Code/autopkg
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ if sys.platform != "darwin":
"""
)

# Catch Python 2 wrappers with an early f-string. Message must be on a single line.
_ = f"""{sys.version_info.major} It looks like you're running the autopkg tool with an incompatible version of Python. Please update your script to use autopkg's included Python (/usr/local/autopkg/python). AutoPkgr users please note that AutoPkgr 1.5.1 and earlier is NOT compatible with autopkg 2. """ # noqa

# If any recipe fails during 'autopkg run', return this exit code
RECIPE_FAILED_CODE = 70

Expand Down

0 comments on commit 5106597

Please sign in to comment.