Mentions légales du service

Skip to content
Snippets Groups Projects
Commit bc53a014 authored by hhakim's avatar hhakim
Browse files

Fix ctest_python gilab job failing on setup.py because of empty cpack version...

Fix ctest_python gilab job failing on setup.py because of empty cpack version variable, undo workaround e1209bc9.

e1209bc9 said the failure was because of false-negative unit test results but it's not. In fact, it was the empty value for the version provoking a PEP440 error.
parent 92cbad19
No related branches found
No related tags found
No related merge requests found
...@@ -22,7 +22,7 @@ ctest_python: ...@@ -22,7 +22,7 @@ ctest_python:
- schedules - schedules
- tags - tags
stage: test_wrapper stage: test_wrapper
allow_failure: true allow_failure: false
ctest_matlab: ctest_matlab:
<<: *ctest_script <<: *ctest_script
......
...@@ -44,6 +44,13 @@ from Cython.Build import cythonize ...@@ -44,6 +44,13 @@ from Cython.Build import cythonize
import numpy import numpy
import sys import sys
version = '@CPACK_PACKAGE_VERSION@'
if(version == ''):
version = '0.0.0' # typically when compiling just for testing
# (not for packaging with a proper version)
# it avoids error PEP440
if sys.platform == 'win32': if sys.platform == 'win32':
# binary libs are compiled manually from cython and then integrated in # binary libs are compiled manually from cython and then integrated in
# wheel/egg pkgs here # wheel/egg pkgs here
...@@ -64,7 +71,7 @@ if sys.platform == 'win32': ...@@ -64,7 +71,7 @@ if sys.platform == 'win32':
copyfile(lib, 'pyfaust'+sep+lib) copyfile(lib, 'pyfaust'+sep+lib)
setup( setup(
name = 'pyfaust', name = 'pyfaust',
version = '@CPACK_PACKAGE_VERSION@', version = version, # cf. header
#ext_modules = cythonize(PyFaust), #ext_modules = cythonize(PyFaust),
distclass = BinaryDistribution, # forces setup-tools to set the arch in distclass = BinaryDistribution, # forces setup-tools to set the arch in
# pkg name # pkg name
...@@ -73,7 +80,7 @@ if sys.platform == 'win32': ...@@ -73,7 +80,7 @@ if sys.platform == 'win32':
description = 'TODO', description = 'TODO',
long_description = 'TODO', long_description = 'TODO',
classifiers = [ 'TODO' ], classifiers = [ 'TODO' ],
install_requires = [ 'scipy', 'numpy', 'matplotlib' ], #ENOTE: order matters (last pkg installed first) install_requires = [ 'scipy', 'numpy', 'matplotlib' ],
license = "GNU AFFERO GPL", license = "GNU AFFERO GPL",
package_data = { package_data = {
'pyfaust': [ 'data/*.mat', lib, 'license*.txt' ] 'pyfaust': [ 'data/*.mat', lib, 'license*.txt' ]
...@@ -92,7 +99,7 @@ else: # linux and mac ...@@ -92,7 +99,7 @@ else: # linux and mac
setup( setup(
name = 'pyfaust', name = 'pyfaust',
version = '@CPACK_PACKAGE_VERSION@', version = version, # cf. header
ext_modules = cythonize(PyFaust), ext_modules = cythonize(PyFaust),
packages = [ 'pyfaust' ], packages = [ 'pyfaust' ],
url = 'http://faust.inria.fr', url = 'http://faust.inria.fr',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment