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

ref: fix typing for sentry.buffer.base #72809

Merged
merged 1 commit into from
Jun 14, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/sentry/buffer/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def process(
# continue
pass
else:
group.update(**update_kwargs)
group.update(using=None, **update_kwargs)
Copy link
Member Author

Choose a reason for hiding this comment

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

this one is a bit annoying, because using could be passed as a named or positional it could collide with arbitrary names in update_kwargs so the type checker rejects it. explicitly passing the default here appeases the checker though

Copy link
Member

Choose a reason for hiding this comment

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

what's the annoyance? seems fine to me as it's just overridden if present in update_kwargs

Copy link
Member Author

Choose a reason for hiding this comment

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

in practice we don't have fields named using so it couldn't possibly collide

created = False
else:
_, created = model.objects.create_or_update(values=update_kwargs, **filters)
Expand Down
Loading