From 9deae601f3bbc590b23181e18e21434d17ba268c Mon Sep 17 00:00:00 2001 From: Heberto Mayorquin Date: Tue, 17 Sep 2024 20:21:22 -0600 Subject: [PATCH 1/4] add macos latest to test --- .github/workflows/all-tests.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/all-tests.yml b/.github/workflows/all-tests.yml index e12cf6805d..80bada7bb4 100644 --- a/.github/workflows/all-tests.yml +++ b/.github/workflows/all-tests.yml @@ -25,7 +25,7 @@ jobs: fail-fast: false matrix: python-version: ["3.9", "3.12"] # Lower and higher versions we support - os: [macos-13, windows-latest, ubuntu-latest] + os: [macos-latest, windows-latest, ubuntu-latest] steps: - uses: actions/checkout@v4 - name: Setup Python ${{ matrix.python-version }} From 1462f9251873c2a94f0c2fb0832b4746f4555fa7 Mon Sep 17 00:00:00 2001 From: Heberto Mayorquin Date: Tue, 17 Sep 2024 21:03:02 -0600 Subject: [PATCH 2/4] add condition to run everything if workflow files are changed --- .github/scripts/determine_testing_environment.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/scripts/determine_testing_environment.py b/.github/scripts/determine_testing_environment.py index 95ad0afc49..518591fb9c 100644 --- a/.github/scripts/determine_testing_environment.py +++ b/.github/scripts/determine_testing_environment.py @@ -31,6 +31,7 @@ sortingcomponents_changed = False generation_changed = False stream_extractors_changed = False +github_actions_changed = False for changed_file in changed_files_in_the_pull_request_paths: @@ -78,9 +79,12 @@ sorters_internal_changed = True else: sorters_changed = True + elif ".github" in changed_file.parts: + if "workflows" in changed_file.parts: + github_actions_changed = True -run_everything = core_changed or pyproject_toml_changed or neobaseextractor_changed +run_everything = core_changed or pyproject_toml_changed or neobaseextractor_changed or github_actions_changed run_generation_tests = run_everything or generation_changed run_extractor_tests = run_everything or extractors_changed or plexon2_changed run_preprocessing_tests = run_everything or preprocessing_changed From 63310759d931d01767acb66a574c9a769eb31f1b Mon Sep 17 00:00:00 2001 From: Heberto Mayorquin Date: Tue, 17 Sep 2024 21:22:13 -0600 Subject: [PATCH 3/4] add checks --- .github/scripts/determine_testing_environment.py | 2 +- src/spikeinterface/extractors/tests/test_neoextractors.py | 5 +++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/scripts/determine_testing_environment.py b/.github/scripts/determine_testing_environment.py index 518591fb9c..aa85aa2b91 100644 --- a/.github/scripts/determine_testing_environment.py +++ b/.github/scripts/determine_testing_environment.py @@ -100,7 +100,7 @@ run_sorters_test = run_everything or sorters_changed run_internal_sorters_test = run_everything or run_sortingcomponents_tests or sorters_internal_changed -run_streaming_extractors_test = stream_extractors_changed +run_streaming_extractors_test = stream_extractors_changed or github_actions_changed install_plexon_dependencies = plexon2_changed diff --git a/src/spikeinterface/extractors/tests/test_neoextractors.py b/src/spikeinterface/extractors/tests/test_neoextractors.py index acd7ebe8ad..ed588149ba 100644 --- a/src/spikeinterface/extractors/tests/test_neoextractors.py +++ b/src/spikeinterface/extractors/tests/test_neoextractors.py @@ -278,8 +278,8 @@ class Spike2RecordingTest(RecordingCommonTestSuite, unittest.TestCase): @pytest.mark.skipif( - version.parse(platform.python_version()) >= version.parse("3.10"), - reason="Sonpy only testing with Python < 3.10!", + version.parse(platform.python_version()) >= version.parse("3.10") or platform.system() == "Darwin", + reason="Sonpy only testing with Python < 3.10 and not supported on macOS!", ) class CedRecordingTest(RecordingCommonTestSuite, unittest.TestCase): ExtractorClass = CedRecordingExtractor @@ -293,6 +293,7 @@ class CedRecordingTest(RecordingCommonTestSuite, unittest.TestCase): ] +@pytest.mark.skipif(platform.system() == "Darwin", reason="Maxwell plugin not supported on macOS") class MaxwellRecordingTest(RecordingCommonTestSuite, unittest.TestCase): ExtractorClass = MaxwellRecordingExtractor downloads = ["maxwell"] From c3e52520d61ef0ffb468aa7167c68e040681f9e3 Mon Sep 17 00:00:00 2001 From: Heberto Mayorquin Date: Tue, 17 Sep 2024 21:26:19 -0600 Subject: [PATCH 4/4] add sampling frequency to blackrock to avoid warning --- src/spikeinterface/extractors/tests/test_neoextractors.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/spikeinterface/extractors/tests/test_neoextractors.py b/src/spikeinterface/extractors/tests/test_neoextractors.py index ed588149ba..3f73161218 100644 --- a/src/spikeinterface/extractors/tests/test_neoextractors.py +++ b/src/spikeinterface/extractors/tests/test_neoextractors.py @@ -234,7 +234,7 @@ class BlackrockSortingTest(SortingCommonTestSuite, unittest.TestCase): ExtractorClass = BlackrockSortingExtractor downloads = ["blackrock"] entities = [ - "blackrock/FileSpec2.3001.nev", + dict(file_path=local_folder / "blackrock/FileSpec2.3001.nev", sampling_frequency=30_000.0), dict(file_path=local_folder / "blackrock/blackrock_2_1/l101210-001.nev", sampling_frequency=30_000.0), ]