changeset a570d463aad3 in modules/account_invoice_line_standalone:default details: https://hg.tryton.org/modules/account_invoice_line_standalone?cmd=changeset;node=a570d463aad3 description: Manage local version in tox and do not set local_version when no CI
issue9928 diffstat: .drone.yml | 2 +- setup.py | 10 ++++++++-- 2 files changed, 9 insertions(+), 3 deletions(-) diffs (39 lines): diff -r c1a4c3c90f22 -r a570d463aad3 .drone.yml --- a/.drone.yml Thu Dec 10 23:05:55 2020 +0100 +++ b/.drone.yml Fri Dec 11 13:51:51 2020 +0100 @@ -12,7 +12,7 @@ environment: - CFLAGS=-O0 - DB_CACHE=/cache - - TOX_TESTENV_PASSENV=CFLAGS DB_CACHE + - TOX_TESTENV_PASSENV=CFLAGS DB_CACHE CI_BUILD_NUMBER CI_JOB_NUMBER CI_JOB_ID - POSTGRESQL_URI=postgresql://postgres@postgresql:5432/ commands: - echo "[extensions]" >> /root/.hgrc diff -r c1a4c3c90f22 -r a570d463aad3 setup.py --- a/setup.py Thu Dec 10 23:05:55 2020 +0100 +++ b/setup.py Fri Dec 11 13:51:51 2020 +0100 @@ -49,7 +49,11 @@ local_version.append(os.environ['CI_JOB_ID']) else: for build in ['CI_BUILD_NUMBER', 'CI_JOB_NUMBER']: - local_version.append(os.environ.get(build, '')) + if os.environ.get(build): + local_version.append(os.environ[build]) + else: + local_version = [] + break if local_version: version += '+' + '.'.join(local_version) @@ -61,7 +65,9 @@ dependency_links = [] if minor_version % 2: - dependency_links.append('https://trydevpi.tryton.org/') + dependency_links.append( + 'https://trydevpi.tryton.org/?local_version=' + + '.'.join(local_version)) setup(name=name, version=version,