Skip to content

UX: Improve situation with weird __table_args__ syntax #142

@amotl

Description

@amotl

Problem

Coming from those recent improvements ...

... @seut mentioned that the need to convey special CrateDB table options like that ...

__table_args__ = {
    'crate_"translog.durability"': "'async'",
}

... is very unfortunate from an UX perspective. I agree with that assessment.

Proposal

It would be so nice to be able to write it down like that, right?

__table_args__ = {
    "crate_translog.durability": "async",
}

Thoughts

SQLAlchemy will be the first instance to receive those options, while evaluating the ORM model. We will need to check where it breaks down the line, and whether we can do something to improve on behalf of the dialect implementation, or if there would be a need to improve SQLAlchemy itself to support such edge cases.

Bonus

The documentation about __table_args__ is also a bit thin, and should be improved.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions