diff --git a/odml/section.py b/odml/section.py
index 407bf31..2086b0b 100644
--- a/odml/section.py
+++ b/odml/section.py
@@ -26,13 +26,16 @@ class BaseSection(base.sectionable, Section):
 
     _format = format.Section
 
-    def __init__(self, name, type=None, parent=None,
-                 definition=None, reference=None):
+    def __init__(self, name, type=None, parent=None, definition=None, reference=None,
+                 repository=None, link=None, include=None):
         self._parent = None
         self._name = name
         self._props = base.SmartList()
         self._definition = definition
         self._reference = reference
+        self._repository = repository
+        self._link = link
+        self._include = include
         super(BaseSection, self).__init__()
         # this may fire a change event, so have the section setup then
         self.type = type
diff --git a/odml/tools/odmlparser.py b/odml/tools/odmlparser.py
index eb0ac3f..31093b6 100644
--- a/odml/tools/odmlparser.py
+++ b/odml/tools/odmlparser.py
@@ -7,8 +7,8 @@ Parses odML files and documents.
 
 """
 
-import yaml
 import json
+import yaml
 from .. import format
 from . import xmlparser
 
@@ -20,13 +20,13 @@ allowed_parsers = ['XML', 'YAML', 'JSON']
 
 
 class ODMLWriter:
-    '''
+    """
         A generic odML document writer, for XML, YAML and JSON.
 
         Usage:
             xml_writer = ODMLWriter(parser='XML')
             xml_writer.write_file(odml_document, filepath)
-    '''
+    """
 
     def __init__(self, parser='XML'):
         self.doc = None  # odML document
@@ -55,7 +55,6 @@ class ODMLWriter:
         self.parsed_doc = parsed_doc
 
     def get_sections(self, section_list):
-
         section_seq = []
 
         for section in section_list:
@@ -81,7 +80,6 @@ class ODMLWriter:
         return section_seq
 
     def get_properties(self, props_list):
-
         props_seq = []
 
         for prop in props_list:
@@ -96,11 +94,10 @@ class ODMLWriter:
                         prop_dict[attr] = t
 
             props_seq.append(prop_dict)
-        
+
         return props_seq
 
     def write_file(self, odml_document, filename):
-
         file = open(filename, 'w')
         file.write(self.to_string(odml_document))
         file.close()
@@ -108,7 +105,7 @@ class ODMLWriter:
     def to_string(self, odml_document):
         string_doc = ''
 
-        if self.parser == 'XML' or self.parser == 'ODML':
+        if self.parser == 'XML':
             string_doc = str(xmlparser.XMLWriter(odml_document))
         else:
             self.to_dict(odml_document)
@@ -129,8 +126,8 @@ class ODMLReader:
     based on the given data exchange format, like XML, YAML or JSON.
 
     Usage:
-        yaml_odml_doc = ODMLReader(parser='YAML').fromFile(open("odml_doc.yaml"))
-        json_odml_doc = ODMLReader(parser='JSON').fromFile(open("odml_doc.json"))
+        yaml_odml_doc = ODMLReader(parser='YAML').from_file("odml_doc.yaml")
+        json_odml_doc = ODMLReader(parser='JSON').from_file("odml_doc.json")
     """
 
     def __init__(self, parser='XML'):
@@ -151,7 +148,6 @@ class ODMLReader:
         return None
 
     def to_odml(self):
-
         self.odml_version = self.parsed_doc['odml-version']
         self.parsed_doc = self.parsed_doc['Document']
 
@@ -172,7 +168,6 @@ class ODMLReader:
         return self.doc
 
     def parse_sections(self, section_list):
-        
         odml_sections = []
 
         for section in section_list:
@@ -197,7 +192,6 @@ class ODMLReader:
 
         return odml_sections
 
-
     def parse_properties(self, props_list):
         odml_props = []
 
@@ -218,7 +212,6 @@ class ODMLReader:
 
         return odml_props
 
-
     def from_file(self, file):
 
         if self.parser == 'XML':
@@ -227,25 +220,24 @@ class ODMLReader:
             return odml_doc
 
         elif self.parser == 'YAML':
-            try:
-                self.parsed_doc = yaml.load(file)
-            except yaml.parser.ParserError as e:
-                print(e)
-                return
-            finally:
-                file.close()
+            with open(file) as yaml_data:
+                try:
+                    self.parsed_doc = yaml.load(yaml_data)
+                except yaml.parser.ParserError as e:
+                    print(e)
+                    return
+
             return self.to_odml()
 
         elif self.parser == 'JSON':
-            try:
-                self.parsed_doc = json.load(file)
-            except json.decoder.JSONDecodeError as e:
-                print(e)
-                return
-            finally:
-                file.close()
-            return self.to_odml()
+            with open(file) as json_data:
+                try:
+                    self.parsed_doc = json.load(json_data)
+                except ValueError as e:  # Python 2 does not support JSONDecodeError
+                    print("JSON Decoder Error: %s" % e)
+                    return
 
+            return self.to_odml()
 
     def from_string(self, string):
 
@@ -253,17 +245,19 @@ class ODMLReader:
             odml_doc = xmlparser.XMLReader().fromString(string)
             self.doc = odml_doc
             return self.doc
+
         elif self.parser == 'YAML':
             try:
-                odml_doc = yaml.load(string)
+                self.parsed_doc = yaml.load(string)
             except yaml.parser.ParserError as e:
                 print(e)
                 return
             return self.to_odml()
+
         elif self.parser == 'JSON':
             try:
-                odml_doc = json.loads(string)
-            except json.decoder.JSONDecodeError as e:
-                print(e)
+                self.parsed_doc = json.loads(string)
+            except ValueError as e:  # Python 2 does not support JSONDecodeError
+                print("JSON Decoder Error: %s" % e)
                 return
             return self.to_odml()

fileio/odmlparser error when loading JSON or YAML
When loading a JSON odML file via `fileio.py` the following error occurs:

     odml.load('f.json', 'json')
     ... odmlparser.py#246 : AttributeError: 'str' object has no attribute 'close'

When loading a YAML odML file via `fileio.py` the following error occurs:

    odml.load('f.yaml', 'yaml')
    ... odmlparser.py#236 : AttributeError: 'str' object has no attribute 'close'

diff --git a/test/test_parser.py b/test/test_parser.py
index 8f9156a..80c89eb 100644
--- a/test/test_parser.py
+++ b/test/test_parser.py
@@ -23,7 +23,6 @@ class TestParser(unittest.TestCase):
 
         self.odml_doc = self.xml_reader.from_file(self.basefile)
 
-
     def tearDown(self):
         if os.path.exists(self.xml_file):
             os.remove(self.xml_file)
@@ -34,40 +33,33 @@ class TestParser(unittest.TestCase):
         if os.path.exists(self.json_file):
             os.remove(self.json_file)
 
-
     def test_xml(self):
-
         self.xml_writer.write_file(self.odml_doc, self.xml_file)
-        xml_doc = self.xml_reader.from_file(open(self.xml_file))
+        xml_doc = self.xml_reader.from_file(self.xml_file)
 
         self.assertEqual(xml_doc, self.odml_doc)
 
     def test_yaml(self):
-
         self.yaml_writer.write_file(self.odml_doc, self.yaml_file)
-        yaml_doc = self.yaml_reader.from_file(open(self.yaml_file))
+        yaml_doc = self.yaml_reader.from_file(self.yaml_file)
 
         self.assertEqual(yaml_doc, self.odml_doc)
 
-
     def test_json(self):
-
         self.json_writer.write_file(self.odml_doc, self.json_file)
-        json_doc = self.json_reader.from_file(open(self.json_file))
+        json_doc = self.json_reader.from_file(self.json_file)
 
         self.assertEqual(json_doc, self.odml_doc)
 
-
     def test_json_yaml_xml(self):
-
         self.json_writer.write_file(self.odml_doc, self.json_file)
-        json_doc = self.json_reader.from_file(open(self.json_file))
+        json_doc = self.json_reader.from_file(self.json_file)
         
         self.yaml_writer.write_file(json_doc, self.yaml_file)
-        yaml_doc = self.yaml_reader.from_file(open(self.yaml_file))
+        yaml_doc = self.yaml_reader.from_file(self.yaml_file)
 
         self.xml_writer.write_file(yaml_doc, self.xml_file)
-        xml_doc = self.xml_reader.from_file(open(self.xml_file))
+        xml_doc = self.xml_reader.from_file(self.xml_file)
 
         self.assertEqual(json_doc, self.odml_doc)
         self.assertEqual(json_doc, yaml_doc)

pip install -e .
parse_log_pytest
lxml enum34 pyyaml rdflib
pytest
apt-get update apt-get install -y libxml2-dev libxslt1-dev lib32z1-dev
3.5
pytest --no-header -rA --tb=line --color=no -p no:cacheprovider -W ignore::DeprecationWarning
attrs==22.2.0
brotlipy==0.7.0
certifi==2021.5.30
cffi @ file:///tmp/build/80754af9/cffi_1625814693874/work
charset-normalizer @ file:///tmp/build/80754af9/charset-normalizer_1630003229654/work
cryptography @ file:///tmp/build/80754af9/cryptography_1635366128178/work
html5lib @ file:///Users/ktietz/demo/mc3/conda-bld/html5lib_1629144453894/work
idna @ file:///tmp/build/80754af9/idna_1637925883363/work
importlib-metadata==4.8.3
iniconfig==1.1.1
isodate @ file:///Users/ktietz/demo/mc3/conda-bld/isodate_1630584690429/work
keepalive @ file:///home/conda/feedstock_root/build_artifacts/keepalive_1635948558527/work
lxml @ file:///tmp/build/80754af9/lxml_1616442911898/work
-e git+https://github.com/G-Node/python-odml.git@e618e125963abd2bd214274861ae7636f3fdfae5#egg=odML
packaging==21.3
pluggy==1.0.0
py==1.11.0
pycparser @ file:///tmp/build/80754af9/pycparser_1636541352034/work
pyOpenSSL @ file:///opt/conda/conda-bld/pyopenssl_1643788558760/work
pyparsing @ file:///tmp/build/80754af9/pyparsing_1635766073266/work
PySocks @ file:///tmp/build/80754af9/pysocks_1605305763431/work
pytest==7.0.1
PyYAML==5.4.1
rdflib @ file:///home/conda/feedstock_root/build_artifacts/rdflib_1610581402529/work
requests @ file:///opt/conda/conda-bld/requests_1641824580448/work
six @ file:///tmp/build/80754af9/six_1644875935023/work
SPARQLWrapper @ file:///home/conda/feedstock_root/build_artifacts/sparqlwrapper_1629916978493/work
tomli==1.2.3
typing_extensions==4.1.1
urllib3 @ file:///opt/conda/conda-bld/urllib3_1643638302206/work
webencodings==0.5.1
zipp==3.6.0

name: python-odml
channels:
  - defaults
  - https://repo.anaconda.com/pkgs/main
  - https://repo.anaconda.com/pkgs/r
  - conda-forge
dependencies:
  - _libgcc_mutex=0.1=main
  - _openmp_mutex=5.1=1_gnu
  - brotlipy=0.7.0=py36h27cfd23_1003
  - ca-certificates=2025.2.25=h06a4308_0
  - certifi=2021.5.30=py36h06a4308_0
  - cffi=1.14.6=py36h400218f_0
  - charset-normalizer=2.0.4=pyhd3eb1b0_0
  - cryptography=35.0.0=py36hd23ed53_0
  - enum34=1.1.10=py36h06a4308_0
  - html5lib=1.1=pyhd3eb1b0_0
  - icu=58.2=he6710b0_3
  - idna=3.3=pyhd3eb1b0_0
  - isodate=0.6.0=pyhd3eb1b0_1
  - keepalive=0.5=pyhd8ed1ab_6
  - ld_impl_linux-64=2.40=h12ee557_0
  - libffi=3.3=he6710b0_2
  - libgcc-ng=11.2.0=h1234567_1
  - libgomp=11.2.0=h1234567_1
  - libstdcxx-ng=11.2.0=h1234567_1
  - libxml2=2.9.14=h74e7548_0
  - libxslt=1.1.35=h4e12654_0
  - lxml=4.6.3=py36h9120a33_0
  - ncurses=6.4=h6a678d5_0
  - openssl=1.1.1w=h7f8727e_0
  - pip=21.2.2=py36h06a4308_0
  - pycparser=2.21=pyhd3eb1b0_0
  - pyopenssl=22.0.0=pyhd3eb1b0_0
  - pyparsing=3.0.4=pyhd3eb1b0_0
  - pysocks=1.7.1=py36h06a4308_0
  - python=3.6.13=h12debd9_1
  - python_abi=3.6=2_cp36m
  - pyyaml=5.4.1=py36h27cfd23_1
  - rdflib=5.0.0=py36h5fab9bb_3
  - readline=8.2=h5eee18b_0
  - requests=2.27.1=pyhd3eb1b0_0
  - setuptools=58.0.4=py36h06a4308_0
  - six=1.16.0=pyhd3eb1b0_1
  - sparqlwrapper=1.8.5=py36h5fab9bb_1006
  - sqlite=3.45.3=h5eee18b_0
  - tk=8.6.14=h39e8969_0
  - urllib3=1.26.8=pyhd3eb1b0_0
  - webencodings=0.5.1=py36_1
  - wheel=0.37.1=pyhd3eb1b0_0
  - xz=5.6.4=h5eee18b_1
  - yaml=0.2.5=h7b6447c_0
  - zlib=1.2.13=h5eee18b_1
  - pip:
      - attrs==22.2.0
      - importlib-metadata==4.8.3
      - iniconfig==1.1.1
      - packaging==21.3
      - pluggy==1.0.0
      - py==1.11.0
      - pytest==7.0.1
      - tomli==1.2.3
      - typing-extensions==4.1.1
      - zipp==3.6.0
prefix: /opt/conda/envs/python-odml

test/test_parser.py::TestParser::test_json test/test_parser.py::TestParser::test_json_yaml_xml test/test_parser.py::TestParser::test_yaml
test/test_parser.py::TestParser::test_xml
odml/section.py odml/tools/odmlparser.py
odml/section.py odml/tools/odmlparser.py