From f9e35884818222ef3bde2c49748d65010f04b376 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 12:39:45 +0100 Subject: [PATCH 01/34] add test for the validator --- .circleci/config.yml | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 75fc62839..1148d4a36 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -202,6 +202,40 @@ jobs: path: /tmp/src/coverage - codecov/upload: file: /tmp/src/coverage/coverage.xml +bids_validate: + docker: + - image: bids/validator + working_directory: /tmp/src/phys2bids + steps: + - checkout + - restore_cache: + key: conda-py37-v1-{{ checksum "setup.cfg" }} + - run: + name: Generate enviroment + command: | + if [[ -e /opt/conda/envs/py36_env ]]; then + echo "Restoring environment from cache" + source activate phys2bids_py37 + else + conda create -yq -n phys2bids_py37 python=3.7 + source activate phys2bids_py37 + pip install -e ".[test,doc]" + fi + - run: + name: dowload data and execute pipeline + command: | + source activate phys2bids_py37 + curl -o tutorial_file.txt https://osf.io/j842e/download + curl -o heur_tutorial.py https://osf.io/qnrdt/download + phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur C:\Users\sento\phys2bids/phys2bids/heuristics/heur_tutorial.py -sub 006 -ses 01 + - run: + name: run_validator + command: | + bids_validator physio_bids + - persist_to_workspace: + root: /tmp + paths: + - src/coverage/.coverage.py37 workflows: version: 2.1 From 6439262f671f69a8cafd06701fc3a7bd7485ce6f Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 12:45:31 +0100 Subject: [PATCH 02/34] add bids_validate job to the workflow --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1148d4a36..ddc380ae0 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -243,6 +243,7 @@ workflows: jobs: - makeenv_37 - unittest_36 + - bids_validate - unittest_37: requires: - makeenv_37 From 9edf33dd9ec6570f9dda9cbe1e0ba80b7c17f9ad Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 12:47:06 +0100 Subject: [PATCH 03/34] correct identation --- .circleci/config.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ddc380ae0..572444616 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -202,7 +202,8 @@ jobs: path: /tmp/src/coverage - codecov/upload: file: /tmp/src/coverage/coverage.xml -bids_validate: + + bids_validate: docker: - image: bids/validator working_directory: /tmp/src/phys2bids From 80324e3be9c368dc514130d9d6a8f6ecc7f870c9 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 12:52:24 +0100 Subject: [PATCH 04/34] try installing phys2bids from zero --- .circleci/config.yml | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 572444616..5453ad0a9 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,14 +214,12 @@ jobs: - run: name: Generate enviroment command: | - if [[ -e /opt/conda/envs/py36_env ]]; then - echo "Restoring environment from cache" - source activate phys2bids_py37 - else - conda create -yq -n phys2bids_py37 python=3.7 - source activate phys2bids_py37 - pip install -e ".[test,doc]" - fi + python --v + git clone https://github.com/physiopy/phys2bids.git + cd phys2bids + pip install -e ".[test,doc]" + cd .. + - run: name: dowload data and execute pipeline command: | From c2e06ded9aa904c39d03b352c185dfe3e106190e Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 12:55:30 +0100 Subject: [PATCH 05/34] try to install python --- .circleci/config.yml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5453ad0a9..940f68a41 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,6 +214,8 @@ jobs: - run: name: Generate enviroment command: | + apt install python3 + apt install python3-pip python --v git clone https://github.com/physiopy/phys2bids.git cd phys2bids From b35e99f743700e65f38465086fde02e00f680650 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:11:55 +0100 Subject: [PATCH 06/34] change container and try bids_validator install --- .circleci/config.yml | 15 ++++++--------- 1 file changed, 6 insertions(+), 9 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 940f68a41..7f6c99afa 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -205,7 +205,7 @@ jobs: bids_validate: docker: - - image: bids/validator + - image: continuumio/miniconda3 working_directory: /tmp/src/phys2bids steps: - checkout @@ -214,18 +214,15 @@ jobs: - run: name: Generate enviroment command: | - apt install python3 - apt install python3-pip - python --v - git clone https://github.com/physiopy/phys2bids.git - cd phys2bids - pip install -e ".[test,doc]" - cd .. + curl -sL https://deb.nodesource.com/setup_15.x | sudo -E bash - + apt-get install -yqq nodejs + npm install -g bids-validator + source activate phys2bids_py37 # depends on makeenv37 - run: name: dowload data and execute pipeline command: | - source activate phys2bids_py37 + source activate phys2bids_py37 # depends on makeenv37 curl -o tutorial_file.txt https://osf.io/j842e/download curl -o heur_tutorial.py https://osf.io/qnrdt/download phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur C:\Users\sento\phys2bids/phys2bids/heuristics/heur_tutorial.py -sub 006 -ses 01 From 7d44a6a11fe3437cf39248a0383c107dde1054ad Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:14:57 +0100 Subject: [PATCH 07/34] add curl install --- .circleci/config.yml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 7f6c99afa..2a6a54c52 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,7 +214,8 @@ jobs: - run: name: Generate enviroment command: | - curl -sL https://deb.nodesource.com/setup_15.x | sudo -E bash - + apt-get install -yqq curl + curl -sL https://deb.nodesource.com/setup_15.x | -E bash - apt-get install -yqq nodejs npm install -g bids-validator source activate phys2bids_py37 # depends on makeenv37 From 18ebd27d89eec934ccc86e3f6efe24322ac71c88 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:16:38 +0100 Subject: [PATCH 08/34] eliminate command --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2a6a54c52..77b21f9a6 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -215,7 +215,7 @@ jobs: name: Generate enviroment command: | apt-get install -yqq curl - curl -sL https://deb.nodesource.com/setup_15.x | -E bash - + curl -sL https://deb.nodesource.com/setup_15.x apt-get install -yqq nodejs npm install -g bids-validator source activate phys2bids_py37 # depends on makeenv37 From 1ab4a8bce41668ea2f5a7275e92c5f167df09ced Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:18:39 +0100 Subject: [PATCH 09/34] add bash command --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 77b21f9a6..45eba6297 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -215,7 +215,7 @@ jobs: name: Generate enviroment command: | apt-get install -yqq curl - curl -sL https://deb.nodesource.com/setup_15.x + curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs npm install -g bids-validator source activate phys2bids_py37 # depends on makeenv37 From 2fbaa3511e24ce66307d41ce31cff57eeb38203f Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:24:06 +0100 Subject: [PATCH 10/34] do the phys2bids install in the test --- .circleci/config.yml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 45eba6297..73c6920c3 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -215,22 +215,20 @@ jobs: name: Generate enviroment command: | apt-get install -yqq curl + pip install -e ".[test,doc]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs npm install -g bids-validator - source activate phys2bids_py37 # depends on makeenv37 - - run: name: dowload data and execute pipeline command: | - source activate phys2bids_py37 # depends on makeenv37 curl -o tutorial_file.txt https://osf.io/j842e/download curl -o heur_tutorial.py https://osf.io/qnrdt/download phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur C:\Users\sento\phys2bids/phys2bids/heuristics/heur_tutorial.py -sub 006 -ses 01 - run: name: run_validator command: | - bids_validator physio_bids + bids-validator physio_bids - persist_to_workspace: root: /tmp paths: From 2f9cdc0d4241840cdc3406db89f7b9a3506fce77 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 13:26:50 +0100 Subject: [PATCH 11/34] correct heur_tutorial path --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 73c6920c3..e9a29b768 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -224,7 +224,7 @@ jobs: command: | curl -o tutorial_file.txt https://osf.io/j842e/download curl -o heur_tutorial.py https://osf.io/qnrdt/download - phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur C:\Users\sento\phys2bids/phys2bids/heuristics/heur_tutorial.py -sub 006 -ses 01 + phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur heur_tutorial.py -sub 006 -ses 01 - run: name: run_validator command: | From a9621b9cbbd3581bba6f0b2807d57a40a999d318 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:22:58 +0100 Subject: [PATCH 12/34] change testing file --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index e9a29b768..ecd950b95 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -222,9 +222,9 @@ jobs: - run: name: dowload data and execute pipeline command: | - curl -o tutorial_file.txt https://osf.io/j842e/download - curl -o heur_tutorial.py https://osf.io/qnrdt/download - phys2bids -in tutorial_file.txt -chtrig 1 -ntp 158 -tr 1.2 -outdir physio_bids -heur heur_tutorial.py -sub 006 -ses 01 + curl -o Test1_multifreq_onescan.txt https://osf.io/7se4t/download + cp phys2bids/phys2bids/heuristics/heur_test_multifreq.py + phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator command: | From 09cc294e4fb250475875e8ffc65e13e292f78f0d Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:25:54 +0100 Subject: [PATCH 13/34] correct copy command --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ecd950b95..f4b2d3233 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -223,7 +223,7 @@ jobs: name: dowload data and execute pipeline command: | curl -o Test1_multifreq_onescan.txt https://osf.io/7se4t/download - cp phys2bids/phys2bids/heuristics/heur_test_multifreq.py + cp phys2bids/phys2bids/heuristics/heur_test_multifreq.py . phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator From e3ee7dab57a3fc4856c2e767360b0233e49e27f6 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:28:34 +0100 Subject: [PATCH 14/34] tmp dir --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index f4b2d3233..5c4120e6e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -223,7 +223,7 @@ jobs: name: dowload data and execute pipeline command: | curl -o Test1_multifreq_onescan.txt https://osf.io/7se4t/download - cp phys2bids/phys2bids/heuristics/heur_test_multifreq.py . + cp /tmp/src/phys2bids/phys2bids/phys2bids/heuristics/heur_test_multifreq.py . phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator From 7fe1ed8d273bacef22522ca4892f7f64131182ec Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:32:46 +0100 Subject: [PATCH 15/34] download heuristic --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5c4120e6e..1d2126e81 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -223,7 +223,7 @@ jobs: name: dowload data and execute pipeline command: | curl -o Test1_multifreq_onescan.txt https://osf.io/7se4t/download - cp /tmp/src/phys2bids/phys2bids/phys2bids/heuristics/heur_test_multifreq.py . + curl -o heur_test_multifreq.py https://osf.io/ehx6j/download phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator From b5f6df44c35b35ac6814ac413c505d7467d8a2d4 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:37:00 +0100 Subject: [PATCH 16/34] use wget instead of curl --- .circleci/config.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 1d2126e81..912a6f6f1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,7 +214,7 @@ jobs: - run: name: Generate enviroment command: | - apt-get install -yqq curl + apt-get install -yqq curl wget pip install -e ".[test,doc]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs @@ -222,8 +222,8 @@ jobs: - run: name: dowload data and execute pipeline command: | - curl -o Test1_multifreq_onescan.txt https://osf.io/7se4t/download - curl -o heur_test_multifreq.py https://osf.io/ehx6j/download + wget -O Test1_multifreq_onescan.txt https://osf.io/7se4t/download + wget -O heur_test_multifreq.py https://osf.io/ehx6j/download phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator From 9f467310cd66e78a99c62352c27bf4922e40ed5e Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:51:08 +0100 Subject: [PATCH 17/34] add tree command --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 912a6f6f1..6e496d619 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -228,6 +228,7 @@ jobs: - run: name: run_validator command: | + tree physio_bids bids-validator physio_bids - persist_to_workspace: root: /tmp From 5edb839c69be836d52299a4c19d5089b756005d5 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 14:54:14 +0100 Subject: [PATCH 18/34] add tree install --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6e496d619..2ec4cbd04 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,7 +214,7 @@ jobs: - run: name: Generate enviroment command: | - apt-get install -yqq curl wget + apt-get install -yqq curl wget tree pip install -e ".[test,doc]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs From 971679d6260077db1dd4f43fc8a4f7713d466c8d Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 15:15:06 +0100 Subject: [PATCH 19/34] now bids_validate requires makeenv37 --- .circleci/config.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2ec4cbd04..2b7038c34 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -224,6 +224,7 @@ jobs: command: | wget -O Test1_multifreq_onescan.txt https://osf.io/7se4t/download wget -O heur_test_multifreq.py https://osf.io/ehx6j/download + source activate phys2bids_py37 # depends on makeenv_37 phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator @@ -241,7 +242,9 @@ workflows: jobs: - makeenv_37 - unittest_36 - - bids_validate + - bids_validate: + requires: + - makeenv_37 - unittest_37: requires: - makeenv_37 From 474e9188a129757a2219c44b692ff5d24cddb831 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 15:21:29 +0100 Subject: [PATCH 20/34] delete pip command --- .circleci/config.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 2b7038c34..3b0d3ed73 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -215,7 +215,6 @@ jobs: name: Generate enviroment command: | apt-get install -yqq curl wget tree - pip install -e ".[test,doc]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs npm install -g bids-validator From 1246acbea83dc329dfc6e8309b9321b3ff790cff Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 15:50:56 +0100 Subject: [PATCH 21/34] do source at the beggining --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 3b0d3ed73..8cadf7b1d 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,6 +214,7 @@ jobs: - run: name: Generate enviroment command: | + source activate phys2bids_py37 # depends on makeenv_37 apt-get install -yqq curl wget tree curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs @@ -223,7 +224,6 @@ jobs: command: | wget -O Test1_multifreq_onescan.txt https://osf.io/7se4t/download wget -O heur_test_multifreq.py https://osf.io/ehx6j/download - source activate phys2bids_py37 # depends on makeenv_37 phys2bids -in Test1_multifreq_onescan.txt -chtrig 1 -ntp 30 -tr 1.2 -outdir physio_bids -heur heur_test_multifreq.py -sub 006 -ses 01 - run: name: run_validator From 74e478b96fd26ed2d0bcc30f3693a59d736f6a18 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 15:56:59 +0100 Subject: [PATCH 22/34] go back to pip install --- .circleci/config.yml | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 8cadf7b1d..ed76b1d2e 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -214,8 +214,8 @@ jobs: - run: name: Generate enviroment command: | - source activate phys2bids_py37 # depends on makeenv_37 apt-get install -yqq curl wget tree + pip install -e ".[test]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs npm install -g bids-validator @@ -232,8 +232,6 @@ jobs: bids-validator physio_bids - persist_to_workspace: root: /tmp - paths: - - src/coverage/.coverage.py37 workflows: version: 2.1 @@ -242,8 +240,6 @@ workflows: - makeenv_37 - unittest_36 - bids_validate: - requires: - - makeenv_37 - unittest_37: requires: - makeenv_37 From 8fa68f9a61b42ad09d56b4b53714451de7985215 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 15:59:26 +0100 Subject: [PATCH 23/34] delete : --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ed76b1d2e..fc26c93b1 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -239,7 +239,7 @@ workflows: jobs: - makeenv_37 - unittest_36 - - bids_validate: + - bids_validate - unittest_37: requires: - makeenv_37 From 1b149bcafeaa671ccbd3b0b531ec0caccca2c4bd Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 16:01:22 +0100 Subject: [PATCH 24/34] add path: --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index fc26c93b1..6da2fa0ff 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -232,6 +232,7 @@ jobs: bids-validator physio_bids - persist_to_workspace: root: /tmp + path: /tmp/src/coverage workflows: version: 2.1 From f4e0834b7280f585f5dc1a30a292d5ad414c4339 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 16:02:31 +0100 Subject: [PATCH 25/34] add path: --- .circleci/config.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 6da2fa0ff..599e428e4 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -215,7 +215,6 @@ jobs: name: Generate enviroment command: | apt-get install -yqq curl wget tree - pip install -e ".[test]" curl -sL https://deb.nodesource.com/setup_15.x | bash - apt-get install -yqq nodejs npm install -g bids-validator @@ -232,7 +231,8 @@ jobs: bids-validator physio_bids - persist_to_workspace: root: /tmp - path: /tmp/src/coverage + paths: + - src/coverage/.coverage.py37 workflows: version: 2.1 From 51e063b97d36c7a7d4534659199e49f120da0aa7 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 16:03:44 +0100 Subject: [PATCH 26/34] add unit test --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index 599e428e4..cd9fb97b7 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -232,7 +232,7 @@ jobs: - persist_to_workspace: root: /tmp paths: - - src/coverage/.coverage.py37 + - src/coverage/.coverage.bids_37 workflows: version: 2.1 From 6ea8c16c9298b4597893629a9aaefd6f1a6d1f1a Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 16:06:38 +0100 Subject: [PATCH 27/34] forgot pip --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index cd9fb97b7..c43f39698 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -216,6 +216,7 @@ jobs: command: | apt-get install -yqq curl wget tree curl -sL https://deb.nodesource.com/setup_15.x | bash - + pip install -e ".[test]" apt-get install -yqq nodejs npm install -g bids-validator - run: From 2c4b6bfaf8cf4010a14aafa87a157711cf9cbc34 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 17:12:00 +0100 Subject: [PATCH 28/34] add my test badge --- .all-contributorsrc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.all-contributorsrc b/.all-contributorsrc index 3c9e275b5..b107af774 100644 --- a/.all-contributorsrc +++ b/.all-contributorsrc @@ -64,7 +64,8 @@ "bug", "code", "doc", - "review" + "review", + "test" ] }, { From e170dd612d1b74c003686327aa1625d35261e601 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Thu, 3 Dec 2020 17:16:38 +0100 Subject: [PATCH 29/34] add test badge --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 9dd5962fe..08e2e81a9 100644 --- a/README.md +++ b/README.md @@ -76,8 +76,8 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
Cesar Caballero Gaudes

πŸ–‹ πŸ”£ πŸ€” -
Vicente Ferrer

πŸ› πŸ’» πŸ“– πŸ‘€ -
Soichi Hayashi

πŸ› +
Vicente Ferrer

πŸ› πŸ’» πŸ“– πŸ‘€ ⚠️ +
Soichi Hayashi

πŸ›
François Lespinasse

πŸ’» ⚠️
Ross Markello

πŸ› πŸ’» πŸ–‹ πŸ€” πŸš‡ πŸ‘€ ⚠️ From 023e4427f9ae1ea1033ac8f4820630282f9a5b00 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Fri, 4 Dec 2020 09:54:59 +0100 Subject: [PATCH 30/34] add dummy bold file with corresponding json --- .circleci/config.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index c43f39698..cb9df6656 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -228,6 +228,9 @@ jobs: - run: name: run_validator command: | + wget -O sub-006_ses-01_task-test_rec-biopac_run-01_bold.json https://osf.io/6j8f7/download + wget -O sub-006_ses-01_task-test_rec-biopac_run-01_bold.nii.gz https://osf.io/wus2p/download + mv sub-006_ses-01_task-test_rec-biopac_run-01_bold* physio_bids/sub-006/ses-01/func tree physio_bids bids-validator physio_bids - persist_to_workspace: From 8b7a33ff5ef72063b09320c0d552b9d7dd2d18bf Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Fri, 4 Dec 2020 10:00:08 +0100 Subject: [PATCH 31/34] now README doesn't have file extension, according to BIDS specification --- phys2bids/bids.py | 2 +- phys2bids/tests/test_bids.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/phys2bids/bids.py b/phys2bids/bids.py index f0136e155..ccaa8d386 100644 --- a/phys2bids/bids.py +++ b/phys2bids/bids.py @@ -284,7 +284,7 @@ def readme_file(outdir): Full path to the output directory. """ - file_path = os.path.join(outdir, 'README.md') + file_path = os.path.join(outdir, 'README') if not os.path.exists(file_path): text = 'Empty README, please fill in describing the dataset in more detail.' LGR.warning('phys2bids could not find README,' diff --git a/phys2bids/tests/test_bids.py b/phys2bids/tests/test_bids.py index 6c062ee1e..c6f3c8f39 100644 --- a/phys2bids/tests/test_bids.py +++ b/phys2bids/tests/test_bids.py @@ -65,8 +65,8 @@ def test_use_heuristic(tmpdir, test_sub, test_ses): @pytest.mark.parametrize('outdir', '.') def test_README_file(outdir): bids.readme_file(outdir) - assert os.path.join(outdir, "README.md") - os.remove(os.path.join(outdir, "README.md")) + assert os.path.join(outdir, "README") + os.remove(os.path.join(outdir, "README")) @pytest.mark.parametrize('outdir', '.') From a16db519aa94ff54b5e5e29a4f7c61a86da5db20 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Fri, 4 Dec 2020 10:04:34 +0100 Subject: [PATCH 32/34] delete root dir --- .circleci/config.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cb9df6656..5296c441b 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -234,7 +234,6 @@ jobs: tree physio_bids bids-validator physio_bids - persist_to_workspace: - root: /tmp paths: - src/coverage/.coverage.bids_37 From c85213f1ee6b4e1473e21b3edce743dc14544b97 Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Fri, 4 Dec 2020 10:05:50 +0100 Subject: [PATCH 33/34] undo commit --- .circleci/config.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.circleci/config.yml b/.circleci/config.yml index 5296c441b..cb9df6656 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -234,6 +234,7 @@ jobs: tree physio_bids bids-validator physio_bids - persist_to_workspace: + root: /tmp paths: - src/coverage/.coverage.bids_37 From 8febea1488340b2f6bd11da71a20cafcd80bea1d Mon Sep 17 00:00:00 2001 From: Vicente Ferrer Date: Fri, 4 Dec 2020 10:07:33 +0100 Subject: [PATCH 34/34] change path --- .circleci/config.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index cb9df6656..374e09ad5 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -236,7 +236,7 @@ jobs: - persist_to_workspace: root: /tmp paths: - - src/coverage/.coverage.bids_37 + - src/phys2bids workflows: version: 2.1