Skip to content
This repository has been archived by the owner on Jan 13, 2024. It is now read-only.

Commit

Permalink
avoid uploading with a wrong subversion number
Browse files Browse the repository at this point in the history
  • Loading branch information
sdpython committed Oct 22, 2016
1 parent 73a7ac0 commit d94ef88
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions setup.py
Expand Up @@ -162,6 +162,16 @@ def write_version():
# when the module is installed, no commit number is displayed
subversion = ""

if "upload" in sys.argv and not subversion:
# avoid uploading with a wrong subversion number
try:
import pyquickhelper
pyq = True
except ImportError:
pyq = False
raise Exception(
"subversion is empty, cannot upload, is_local()={0}, pyquickhelper={1}".format(is_local(), pyq))

##############
# common part
##############
Expand Down

0 comments on commit d94ef88

Please sign in to comment.