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

Frontend FTBFS in rawhide #3130

Closed
praiskup opened this issue Feb 5, 2024 · 1 comment · Fixed by #3172
Closed

Frontend FTBFS in rawhide #3130

praiskup opened this issue Feb 5, 2024 · 1 comment · Fixed by #3172

Comments

@praiskup
Copy link
Member

praiskup commented Feb 5, 2024

See the CI #3106 failure.

@praiskup
Copy link
Member Author

praiskup commented Feb 5, 2024

Seems like related to sqlalchemy 2+
https://bodhi.fedoraproject.org/updates/?search=sqlalchemy

@praiskup praiskup moved this from Needs triage to In 3 months in CPT Kanban Feb 7, 2024
@nikromen nikromen moved this from In 3 months to In Progress in CPT Kanban Feb 12, 2024
@praiskup praiskup mentioned this issue Feb 26, 2024
4 tasks
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 3, 2024
See fedora-copr#3130

    AttributeError: 'Engine' object has no attribute 'execute'

And also use text for raw SQL commands

    Use the text() construct, or the Connection.exec_driver_sql()
    method to invoke a driver-level SQL string.
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 3, 2024
See fedora-copr#3130

    sqlalchemy.exc.InvalidRequestError: No 'on clause' argument may be
    passed when joining to a relationship path as a target
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 3, 2024
See fedora-copr#3130

This is a straightforward case. We cannot join or select using
attribute names represented as strings.

    sqlalchemy.exc.ArgumentError: Strings are not accepted for
    attribute names in loader options; please use class-bound
    attributes directly.

This one is a bit harder to understand.

    sqlalchemy.exc.ArgumentError: expected ORM mapped attribute for
    loader strategy argument

Easier to show on an example. When selecting e.g. `BuildChroot` and
wanting to join the build information, we cannot do
`join(models.Build)` but instead, we need to
`join(models.BuildChroot.build)`.
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 3, 2024
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
See fedora-copr#3130

For some reason the order of `[x.name for x in self.c3.copr_chroots]`
is different SQLAlchemy 1 and 2.

F39:

    ['fedora-18-x86_64', 'fedora-rawhide-i386']

F40:

    ['fedora-rawhide-i386', 'fedora-18-x86_64']
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
See fedora-copr#3130

    AttributeError: 'Engine' object has no attribute 'execute'

And also use text for raw SQL commands

    Use the text() construct, or the Connection.exec_driver_sql()
    method to invoke a driver-level SQL string.

And finially setting `future=True` which is going to be passed to
`create_engine` by Flask-SQLAlchemy to ensure compatibility between
SQLAlchemy 1.x and 2.0. Otherwise we would get

    AttributeError: 'Connection' object has no attribute 'commit'
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
See fedora-copr#3130

    sqlalchemy.exc.InvalidRequestError: No 'on clause' argument may be
    passed when joining to a relationship path as a target
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
See fedora-copr#3130

This is a straightforward case. We cannot join or select using
attribute names represented as strings.

    sqlalchemy.exc.ArgumentError: Strings are not accepted for
    attribute names in loader options; please use class-bound
    attributes directly.

This one is a bit harder to understand.

    sqlalchemy.exc.ArgumentError: expected ORM mapped attribute for
    loader strategy argument

Easier to show on an example. When selecting e.g. `BuildChroot` and
wanting to join the build information, we cannot do
`join(models.Build)` but instead, we need to
`join(models.BuildChroot.build)`.
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
FrostyX added a commit to FrostyX/copr that referenced this issue Mar 5, 2024
See fedora-copr#3130

For some reason the order of `[x.name for x in self.c3.copr_chroots]`
is different SQLAlchemy 1 and 2.

F39:

    ['fedora-18-x86_64', 'fedora-rawhide-i386']

F40:

    ['fedora-rawhide-i386', 'fedora-18-x86_64']
praiskup pushed a commit that referenced this issue Mar 7, 2024
See #3130

    AttributeError: 'Engine' object has no attribute 'execute'

And also use text for raw SQL commands

    Use the text() construct, or the Connection.exec_driver_sql()
    method to invoke a driver-level SQL string.

And finially setting `future=True` which is going to be passed to
`create_engine` by Flask-SQLAlchemy to ensure compatibility between
SQLAlchemy 1.x and 2.0. Otherwise we would get

    AttributeError: 'Connection' object has no attribute 'commit'
praiskup pushed a commit that referenced this issue Mar 7, 2024
See #3130

    sqlalchemy.exc.InvalidRequestError: No 'on clause' argument may be
    passed when joining to a relationship path as a target
praiskup pushed a commit that referenced this issue Mar 7, 2024
See #3130

This is a straightforward case. We cannot join or select using
attribute names represented as strings.

    sqlalchemy.exc.ArgumentError: Strings are not accepted for
    attribute names in loader options; please use class-bound
    attributes directly.

This one is a bit harder to understand.

    sqlalchemy.exc.ArgumentError: expected ORM mapped attribute for
    loader strategy argument

Easier to show on an example. When selecting e.g. `BuildChroot` and
wanting to join the build information, we cannot do
`join(models.Build)` but instead, we need to
`join(models.BuildChroot.build)`.
praiskup pushed a commit that referenced this issue Mar 7, 2024
See #3130

For some reason the order of `[x.name for x in self.c3.copr_chroots]`
is different SQLAlchemy 1 and 2.

F39:

    ['fedora-18-x86_64', 'fedora-rawhide-i386']

F40:

    ['fedora-rawhide-i386', 'fedora-18-x86_64']
@nikromen nikromen moved this from In Progress to Done in CPT Kanban Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Development

Successfully merging a pull request may close this issue.

2 participants