Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

When Param and Comp classes are called and AttributeError is thrown in version 5.0.0 #1465

Closed
turoger opened this issue Nov 16, 2021 · 2 comments

Comments

@turoger
Copy link

turoger commented Nov 16, 2021

When Param and Comp classes are called from parserutils, an AttributeError is thrown because Param and Compcan't set the attribute for self.name in L114 and L218.

To fix this I added decorators to each class.

    @property
    def name(self):
        return self._name

    @name.setter
    def name(self, name):
        self._name = name

Unsure if others face the same issue, but posting here to see raise the issue.

My environment on Python 3.8.5:

Package                Version
---------------------- ---------
antlr4-python3-runtime 4.9.3
backoff                1.11.1
certifi                2021.10.8
CFGraph                0.2.1
chardet                4.0.0
charset-normalizer     2.0.7
click                  8.0.3
Flask                  2.0.2
Flask-Cors             3.0.10
idna                   3.3
isodate                0.6.0
itsdangerous           2.0.1
Jinja2                 3.0.3
jsonasobj              1.3.1
MarkupSafe             2.0.1
mwoauth                0.3.7
networkx               2.6.3
numpy                  1.21.4
oauthlib               3.1.1
pandas                 1.3.4
pip                    20.1.1
PyJSG                  0.11.6
PyJWT                  1.7.1
pyparsing              3.0.6
PyShEx                 0.7.20
PyShExC                0.8.3
python-dateutil        2.8.2
pytz                   2021.3
rdflib                 5.0.0
rdflib-jsonld          0.6.2
requests               2.26.0
requests-oauthlib      1.3.0
setuptools             47.1.0
shexer                 1.4.0
ShExJSG                0.7.1
simplejson             3.17.5
six                    1.16.0
sparqlslurper          0.4.1
SPARQLWrapper          1.8.5
tqdm                   4.62.3
urllib3                1.26.7
Werkzeug               2.0.2
wikidataintegrator     0.9.19
wlighter               1.0.1
@maximelefrancois86
Copy link

see #1204

@turoger
Copy link
Author

turoger commented Nov 24, 2021

Thank you, the solution works with Python 3.8.5 as well. I will close this.

@turoger turoger closed this as completed Nov 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants