Skip to content

Commit c8354d5

Browse files
authored
Merge pull request #130 from OpenSourceBrain/development
Use py3.10 for testing
2 parents 275bf3d + 6cfa63b commit c8354d5

File tree

8 files changed

+21
-19
lines changed

8 files changed

+21
-19
lines changed

.github/workflows/ci.yml

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,19 +15,17 @@ jobs:
1515
strategy:
1616
fail-fast: false
1717
matrix:
18-
python-version: [ 3.9 ]
18+
python-version: [ "3.10" ]
1919
engine:
2020
- Arbor
2121
- "Brian2:2.4"
2222
- Brian2
2323
- EDEN
24-
- "NEST:2.20.0"
2524
- "NEST:3.3"
2625
- PyNEST
27-
- PyNEST:2.20.0
2826
- PyNEST:3.1
29-
- "NEURON:7.8.2"
30-
- "PyNEURON:8.0.2"
27+
- "NEURON"
28+
- "PyNEURON:8.2.6"
3129
- PyNN
3230
- PyNN_Brian2
3331
- PyNN_NEURON

.github/workflows/ci_versions.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ jobs:
4343
- name: Run simple OMV tests
4444
run: |
4545
omv install pyNeuroML
46-
omv test -V utilities/tests/.test.ex9.jnmlbrian2.omt
46+
omv test -V utilities/tests/.test.exIzh.jnmlnetpyne.omt
4747
4848
4949
- name: OMV final version info

omv/engines/getnetpyne.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,6 @@ def install_netpyne(version=None):
3434

3535
with working_dir(path):
3636
if sys.version_info.major == 2:
37-
# pip_install([]'setuptools==42.0.1')
3837
pip_install(
3938
[
4039
"kiwisolver==1.0.1",

omv/engines/getnrn.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
import os
22
import sys
33
from subprocess import check_output as co
4-
from distutils.core import run_setup
54
from omv.common.inout import inform
65
from omv.common.inout import pip_install
76

@@ -11,7 +10,7 @@
1110
def install_neuron(version):
1211
if not version:
1312
if sys.version_info.major == 3:
14-
version = "8.2.2" # for pynn 0.11.0
13+
version = "8.2.6" # for pynn 0.11.0
1514
else:
1615
version = "7.6"
1716

@@ -57,4 +56,4 @@ def install_neuron(version):
5756
print(co(["make", "install"]))
5857

5958
os.chdir("src/nrnpython")
60-
run_setup("./setup.py", ["install"])
59+
print(co(["pip", "install", "."]))

omv/validation/rx_validator.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ def __init__(self):
88

99
def generate_schema(self, schema_src):
1010
schema = self.parse_yaml_file(schema_src)
11-
print("generating schema from %s" % schema)
11+
print("Generating schema from %s" % schema)
1212
return self.rx.make_schema(schema)
1313

1414
def parse_yaml_file(self, fname):
@@ -18,7 +18,7 @@ def parse_yaml_file(self, fname):
1818

1919
def validate(self, schema_src, doc_src):
2020
doc = self.parse_yaml_file(doc_src)
21-
print("validating document %s" % doc)
21+
print("Validating the document: %s" % doc)
2222
return self.generate_schema(schema_src).check(doc)
2323

2424

omv/validation/validate.py

Lines changed: 7 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
1-
from os.path import splitext, basename
1+
from os.path import splitext, basename, dirname
22
from omv.validation.rx_validator import RXSchemaValidator
33
from omv.validation.utils import topological_sort, all_types_in_schema
4-
from pkg_resources import resource_filename
54

65

76
class OMVValidator(RXSchemaValidator):
7+
88
def __init__(self):
99
super(OMVValidator, self).__init__()
1010
self.add_osb_prefix()
@@ -18,7 +18,11 @@ def register_osb_types(self):
1818
self.omv_types = {}
1919
from glob import glob
2020

21-
typedir = resource_filename("omv", "schemata/types/")
21+
#typedir = resource_filename("omv", "schemata/types/")
22+
typedir = dirname(dirname(__file__)) + "/schemata/types/"
23+
24+
print("Type directory: %s"%typedir)
25+
2226
for omv in glob(typedir + "*.yaml") + glob(typedir + "/base/*.yaml"):
2327
tag = self.prefix + splitext(basename(omv))[0]
2428
print("registering", tag)

omv/validation/validate_mep.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
11
#!/usr/bin/env python
22
import sys
33
from omv.validation.validate import OMVValidator
4-
from pkg_resources import resource_filename
4+
from os.path import dirname
55

66

77
def validate(mep_src):
88
s = OMVValidator()
99
print("Validating document againt mep schema: ")
10-
schema = resource_filename("omv", "schemata/mep.yaml")
10+
#schema = resource_filename("omv", "schemata/mep.yaml")
11+
schema = dirname(dirname(__file__)) + "/schemata/mep.yaml"
1112
print(s.validate(schema, mep_src))
1213

1314

setup.cfg

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[metadata]
22
name = OSBModelValidation
3-
version = 0.3.3
3+
version = 0.3.4
44
author = Boris Marin, Padraig Gleeson
55
author_email = [email protected]
66
url = https://github.com/OpenSourceBrain/osb-model-validation
@@ -29,7 +29,6 @@ install_requires =
2929
pathlib; python_version<'3.4'
3030
docopt
3131
importlib-metadata; python_version<'3.8'
32-
setuptools
3332

3433
packages = find:
3534

@@ -43,9 +42,11 @@ console_scripts =
4342

4443
[options.package_data]
4544
* =
45+
schemata/*
4646
*.yaml
4747
*.g
4848

4949

50+
5051
[flake8]
5152
ignore = E501, E502, F403, F405

0 commit comments

Comments
 (0)