Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
767c79d
Merge pull request #112 from xmos/master
mbanth Mar 31, 2020
9f6bea4
Pin pytest to v6 and make work
BrennanGit Jul 31, 2020
88e95af
Few typos
BrennanGit Jul 31, 2020
133f66b
Hard pin pytest including patch releases
BrennanGit Aug 3, 2020
54dcced
Merge pull request #115 from BrennanGit/feature/pin_pytest
chrisc-xmos Aug 3, 2020
a30c61b
Switch out Pipfile for requirements.txt
BrennanGit Aug 17, 2020
055178e
Switch out legacy Pipfile for req.txt as well
BrennanGit Aug 17, 2020
7a5bf7f
Add python version to requirements
BrennanGit Aug 17, 2020
f612e10
Use updated Jenkins library
BrennanGit Aug 17, 2020
f27bcd7
Remove Pipfiles from index
BrennanGit Aug 17, 2020
d41362a
Hard pin pip dependencies in legacy tests
BrennanGit Aug 17, 2020
9e6664e
Update pytest patch to 6.0.1
BrennanGit Aug 17, 2020
571d01a
Merge pull request #116 from BrennanGit/feature/requirements
BrennanGit Aug 17, 2020
20e1b9d
Update requirements.txt and setup.py
xluciano Sep 15, 2020
31f21ab
Update requirements.txt and setup.py
xluciano Sep 15, 2020
ef0646f
Remove lib_dsp python dependency
xluciano Sep 16, 2020
8a838da
Run waf with venv activated
xluciano Sep 16, 2020
0a77891
Move setup.py into python folder
xluciano Sep 16, 2020
68aacdb
Add dependencies in requirements.txt
xluciano Sep 16, 2020
f85e70a
Merge pull request #117 from lucianomartin/feature/update_requirements
xluciano Sep 16, 2020
69e6b82
Use numpy version 1.18.5
xluciano Sep 21, 2020
b90f5c0
Add "packages=setuptools.find_packages()" in setup.py
xluciano Sep 21, 2020
ee013bb
Add comment
xluciano Sep 21, 2020
5262db5
Merge pull request #120 from lucianomartin/feature/numpy_version
mbanth Sep 21, 2020
86a71f8
Update pinned version of xmos_jenkins_shared_library
xluciano Oct 2, 2020
7feb014
Merge pull request #121 from xmos/feature/update_jsl
mbanth Oct 2, 2020
35d9282
Bump version for infrastructure changes
xluciano Oct 5, 2020
8658a25
Merge pull request #122 from lucianomartin/feature/bump_version
mbanth Oct 6, 2020
1f3ba37
Remove not necessary cpanfile
xluciano Oct 7, 2020
a55bb6e
Merge pull request #123 from xmos/feature/remove_cpan_file
xluciano Oct 7, 2020
0bc1879
Merge pull request #124 from xmos/develop
xluciano Oct 7, 2020
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions CHANGELOG.rst
Original file line number Diff line number Diff line change
@@ -1,6 +1,12 @@
lib_mic_array change log
========================

4.2.2
-----

* CHANGED: Pin Python package versions
* REMOVED: not necessary cpanfile

4.2.1
-----

Expand Down
7 changes: 3 additions & 4 deletions Jenkinsfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
@Library('xmos_jenkins_shared_library@v0.10.0') _

@Library('xmos_jenkins_shared_library@v0.14.2') _
getApproval()

pipeline {
Expand Down Expand Up @@ -27,8 +26,8 @@ pipeline {
stage('Unit tests') {
steps {
dir("${REPO}/tests/unit_tests") {
runWaf('.')
viewEnv() {
runWaf('.')
runPytest()
}
}
Expand All @@ -38,7 +37,7 @@ pipeline {
steps {
dir("${REPO}/legacy_tests") {
viewEnv() {
// Use Pipfile in legacy_tests, not lib_mic_array/Pipfile
// Use requirements.txt in legacy_tests, not lib_mic_array/requirements.txt
installPipfile(true)
runPython("./runtests.py --junit-output=${REPO}_tests.xml")
}
Expand Down
11 changes: 0 additions & 11 deletions Pipfile

This file was deleted.

2 changes: 0 additions & 2 deletions cpanfile

This file was deleted.

14 changes: 0 additions & 14 deletions legacy_tests/Pipfile

This file was deleted.

5 changes: 5 additions & 0 deletions legacy_tests/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# python_version 2.7

numpy==1.16.6
scipy==1.2.3
soundfile==0.10.3.post1
2 changes: 1 addition & 1 deletion lib_mic_array/module_build_info
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
VERSION = 4.2.1
VERSION = 4.2.2

DEPENDENT_MODULES = lib_xassert(>=4.0.0) \
lib_logging(>=3.0.0) \
Expand Down
30 changes: 30 additions & 0 deletions python/setup.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# Copyright (c) 2020, XMOS Ltd, All rights reserved
import setuptools

# Another repository might depend on python code defined in this one. The
# procedure to set up a suitable python environment for that repository may
# pip-install this one as editable using this setup.py file. To minimise the
# chance of version conflicts while ensuring a minimal degree of conformity,
# the 3rd-party modules listed here require the same major version and at
# least the same minor version as specified in the requirements.txt file.
# The same modules should appear in the requirements.txt file as given below.
setuptools.setup(
name='lib_mic_array',
packages=setuptools.find_packages(),
install_requires=[
"flake8~=3.8",
"matplotlib~=3.3",
"numpy~=1.18",
"pylint~=2.5",
"pytest~=6.0",
"pytest-xdist~=1.34",
"scipy~=1.4",
"lib_logging",
"lib_xassert",
],

dependency_links=[
'./../lib_logging#egg=lib_logging',
'./../lib_xassert#egg=lib_xassert',
],
)
44 changes: 44 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
# python_version 3.7.6
#
# The parse_version_from_requirements() function in the installPipfile.groovy
# file of the Jenkins Shared Library uses the python_version comment to set
# the version of python used.

# Distributed (released) dependencies
#
# The python modules listed below specify a known working combination required
# by the python code in this repository. The procedure used to set up a
# suitable python environment for it installs the version of each module in
# the list. Using a specific version ensures a controlled infrastructure for
# development, testing and release of this repository.
#
# Another repository might depend on python code defined in this one. The
# procedure to set up a suitable python environment for that repository may
# pip-install this one as editable using this repository's setup.py file. The
# same modules should appear in the setup.py list as given below.
flake8==3.8.3
matplotlib==3.3.1

# Pin numpy to 1.18.5 due to tensorflow v2.1.1 hard pinning it to that version.
numpy==1.18.5
pylint==2.5.3
pytest==6.0.0
pytest-xdist==1.34.0

# Pin scipy to 1.4.1 due to tensorflow v2.1.1 hard pinning it to that version.
scipy==1.4.1

# Development dependencies
#
# Each link listed below specifies the path to a setup.py file which are
# installed in editable mode with '-e $PATH' (without the quotes).
#
# If python code in this repository depends on python code under development
# in another repository, then an entry for that other respository should
# appear in this list instead of the released dependencies list.
#
# If this repository uses the setup functionality (e.g., script entry points)
# of its own setup.py file, then this list must include an entry for that
# setup.py file, e.g., '-e .' or '-e ./python' (without the quotes).
-e ./../lib_logging
-e ./../lib_xassert
8 changes: 4 additions & 4 deletions tests/unit_tests/conftest.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Copyright (c) 2018-2019, XMOS Ltd, All rights reserved
# Copyright (c) 2018-2020, XMOS Ltd, All rights reserved
import os.path
import pytest
import subprocess
Expand All @@ -10,7 +10,7 @@ def pytest_collect_file(parent, path):
if ((path.ext == ".c" or path.ext == ".xc")
and (path.basename.startswith("test_")
and "_Runner" not in path.basename)):
return UnityTestSource(path, parent)
return UnityTestSource.from_parent(parent, fspath=path)


class UnityTestSource(pytest.File):
Expand All @@ -32,13 +32,13 @@ def collect(self):
test_src_name + '_single_issue.xe')
test_bin_path_si = os.path.join('bin',
test_bin_name_si)
yield UnityTestExecutable(test_bin_path_si, self)
yield UnityTestExecutable.from_parent(self, name=test_bin_path_si)

test_bin_name_di = os.path.join(
test_src_name + '_dual_issue.xe')
test_bin_path_di = os.path.join('bin',
test_bin_name_di)
yield UnityTestExecutable(test_bin_path_di, self)
yield UnityTestExecutable.from_parent(self, name=test_bin_path_di)


class UnityTestExecutable(pytest.Item):
Expand Down