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

Duplicate ticket number #85

Open
Learath2 opened this issue Jul 3, 2024 · 3 comments
Open

Duplicate ticket number #85

Learath2 opened this issue Jul 3, 2024 · 3 comments

Comments

@Learath2
Copy link
Member

Learath2 commented Jul 3, 2024

async def ticket_num(self, category) -> int:

Need to wrap this function with a lock

@murpii
Copy link
Member

murpii commented Jul 15, 2024

I believe there's a different issue at play. I've noticed that the duplicate tickets always come from the same person, as if the button interaction was sent twice.

What I could do is disable the button after it's been clicked, and then release it after the ticket is created to confirm this theory maybe.

@Learath2
Copy link
Member Author

Something something idempotency something something. But I'm fairly sure it's a locking issue, why would the second interaction ever get the old id otherwise?

@murpii
Copy link
Member

murpii commented Jul 23, 2024

Locking this particular function would ensure the counter increments correctly, but it wouldn't prevent the creation of two separate channels, right?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants