Skip to content

Conversation

@LilyFirefly
Copy link
Collaborator

transaction, transaction_if_not_already and transaction_required can all be used as a decorator or a context manager. They all have an optional using parameter, which means that when being used as a decorator it is nice to omit the parentheses when possible.

Fixes #103.

@LilyFirefly LilyFirefly self-assigned this Jan 20, 2026
@LilyFirefly LilyFirefly added the enhancement New feature or request label Jan 20, 2026
@LilyFirefly LilyFirefly force-pushed the support-decorators-without-parentheses branch from c7c2792 to 3d593d0 Compare January 20, 2026 17:29
@LilyFirefly LilyFirefly marked this pull request as ready for review January 20, 2026 17:34
@LilyFirefly LilyFirefly requested a review from a team as a code owner January 20, 2026 17:34
Base automatically changed from fix-test-dbs-and-gitignore to main January 21, 2026 10:30
Copy link
Collaborator

@meshy meshy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you! Can I please ask you to add a note about this to the changelog file?

That's the only blocker on this from my perspective.

`transaction`, `transaction_if_not_already` and `transaction_required`
can all be used as a decorator or a context manager. They all have an
optional `using` parameter, which means that when being used as a
decorator it is nice to omit the parentheses when possible.

Fixes #103.
@LilyFirefly LilyFirefly force-pushed the support-decorators-without-parentheses branch from 3d593d0 to 34e7654 Compare January 21, 2026 10:48
@meshy meshy merged commit 6296fed into main Jan 21, 2026
7 checks passed
@meshy meshy deleted the support-decorators-without-parentheses branch January 21, 2026 10:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Don't require parentheses for decorator calls

3 participants