Skip to content

Conversation

@fumlig
Copy link

@fumlig fumlig commented Jul 7, 2025

In many cases, if one assignment fails we want all of them to fail instead of creating a partial match. This PR adds and option all_or_none to the AssignTickets request that, if set, avoids assigning any of the tickets if at least one is not found before starting the assignment.

@fumlig fumlig force-pushed the ol/atomic-assignments branch 2 times, most recently from af5c624 to aed661d Compare July 8, 2025 08:51
@fumlig fumlig changed the title AllOrNothing option in AssignTickets DisallowPartial option in AssignTickets Jul 8, 2025
@odouglas-es
Copy link

odouglas-es commented Jul 8, 2025

Note: since you only changed protos, you might need to run make all-protos to update the swagger docs as well. Normally running make presubmit would rebuild everything and check that it all works but you can also just run make all-protos to generate the necessary files and make test to check if anything test-wise is broken.

@fumlig fumlig force-pushed the ol/atomic-assignments branch from aed661d to cacaea5 Compare July 8, 2025 09:01
@fumlig
Copy link
Author

fumlig commented Jul 8, 2025

Note: since you only changed protos, you might need to run make all-protos to update the swagger docs as well. Normally running make presubmit would rebuild everything and check that it all works but you can also just run make all-protos to generate the necessary files and make test to check if anything test-wise is broken.

Ah ok, thanks! I noticed that a bunch of version numbers change as well: is that something I can/should avoid? 🤔

@odouglas-es
Copy link

odouglas-es commented Jul 8, 2025

Note: since you only changed protos, you might need to run make all-protos to update the swagger docs as well. Normally running make presubmit would rebuild everything and check that it all works but you can also just run make all-protos to generate the necessary files and make test to check if anything test-wise is broken.

Ah ok, thanks! I noticed that a bunch of version numbers change as well: is that something I can/should avoid? 🤔

Unfortunately no direct way, its a go thing, the toolchain always tries to update packages/modules. You can rollback or ignore them unless you explicitly updated a go module version. I normally just roll them back.

You could but it would require you to pin the versions of all the modules using the replace command which is a lot of work.

@fumlig fumlig marked this pull request as ready for review July 8, 2025 09:24
Copy link

@odouglas-es odouglas-es left a comment

Choose a reason for hiding this comment

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

Nice! would be nice to have a couple unit tests to validate this, what do you think?

Copy link
Member

@slvmnd slvmnd left a comment

Choose a reason for hiding this comment

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

Nice!

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

Successfully merging this pull request may close these issues.

3 participants