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
KeyError: '_data' #80
Comments
Worked for me too |
up also happens in python 3.8 and ERAlchemy==1.2.10/ SQLAlchemy==1.4.3 |
Hitting same issue, same versions mentioned. |
Same issue for me. The change fixed the problem for me. |
A possible fix that should allow for backwards compatibility is to use the builtin something like this is working for me: def table_to_intermediary(table):
"""Transform an SQLAlchemy Table object to it's intermediary representation. """
return Table(
name=table.fullname,
# columns=[column_to_intermediary(col) for col in table.c._data.values()]
# columns=[column_to_intermediary(col) for col in (table.c._data.values() if hasattr(table.c,"_data") else table.c._colset)]
columns=[column_to_intermediary(col) for col in getattr(table.c,"_colset",getattr(table.c,"_data",{}).values())]
) EDIT: |
Another workaround, if you don't need 1.4 (release notes on docs.sqlalchemy.org), pinning |
This worked for me. Thanks! |
columns=[column_to_intermediary(col) for col in table.c._colset] is still needful with
|
I added a fork of eralchemy in this repo which contains fixes for the current SQLAlchemy version: #94 |
Solution from: Alexis-benoist/eralchemy#80
Fix works for me! |
Solution from: Alexis-benoist/eralchemy#80
i am getting this same issue |
Hi @tarunsengar1987 , |
With
I get this error:
I have investigated to fix it for sqlachemy but don't know about backwards compat.
eralchemy/eralchemy/sqla.py
Line 50 in d6fcdc6
needs to be replaced with:
I can create a tested PR if you are willing to merge it.
The text was updated successfully, but these errors were encountered: