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

Set minimum attrs version #1520

Open
max-radin opened this issue Jan 10, 2025 · 0 comments · May be fixed by #1521
Open

Set minimum attrs version #1520

max-radin opened this issue Jan 10, 2025 · 0 comments · May be fixed by #1521

Comments

@max-radin
Copy link

I found that upgrading attrs to 23.2.0 or higher would resolve errors such as

  File "/Users/maxradin/anaconda3/lib/python3.11/functools.py", line 994, in __get__
    raise TypeError(msg) from None
TypeError: No '__dict__' attribute on 'CtrlSpec' instance to cache 'shapes' property.

when using qualtran. (See isi-usc-edu/pyLIQTR#35 for example code and full traceback.)

My guess is that this is because earlier versions of attrs did not support cached properties on slotted classes, as described in python-attrs/attrs#1200. I'd suggest updating qualtran's requirements to specify a minimum version of 23.2.0 for attrs.

max-radin added a commit to max-radin/Qualtran that referenced this issue Jan 10, 2025
@max-radin max-radin linked a pull request Jan 10, 2025 that will close this issue
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

Successfully merging a pull request may close this issue.

1 participant