File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1010
1111from ..doc import BaseDocument
1212from ..format import Format , Document , Section , Property
13- from ..info import FORMAT_VERSION
14- from ..resources import RDF_SUBCLASS_FILE
13+ from ..info import FORMAT_VERSION , INSTALL_PATH
1514from .dict_parser import DictReader
1615from .parser_utils import ParserException
1716from .utils import RDFConversionFormats
@@ -34,11 +33,13 @@ def load_rdf_subclasses():
3433 """
3534 section_subclasses = {}
3635
37- if not os .path .isfile (RDF_SUBCLASS_FILE ):
38- print ("[Warning] Could not find subclass file '%s'" % RDF_SUBCLASS_FILE )
36+ subclass_file = os .path .join (INSTALL_PATH , "resources" , "section_subclasses.yaml" )
37+
38+ if not os .path .isfile (subclass_file ):
39+ print ("[Warning] Could not find subclass file '%s'" % subclass_file )
3940 return section_subclasses
4041
41- with open (RDF_SUBCLASS_FILE , "r" ) as yaml_file :
42+ with open (subclass_file , "r" ) as yaml_file :
4243 try :
4344 section_subclasses = yaml .load (yaml_file )
4445 except yaml .parser .ParserError as err :
You can’t perform that action at this time.
0 commit comments