Need to recalculate remaining if there's an error#365
Merged
michael-richey merged 6 commits intomainfrom Aug 15, 2025
Merged
Conversation
heyronhay
approved these changes
Aug 15, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What does this PR do?
Need to keep going after an error so
remainingcan't be 0. We also don't have arespin the except block so we can't calculate the real number of remaining elements, just set it to 1 to keep going. If were at pagesize 1 we need to set it back.Also "handle" a 404 by just breaking out to the loop, stopping the process. If something is missing that we expect to be there then that's an issue.
During the testing the
userspublic API changed. The GET returns a new fieldallowed_login_methodsbut the POST doesn't allow it, so it has to be excluded.Description of the Change
The
remainingvariable was only being updated during a success, not in theexceptsection of the code. It needs to be recalculated in every iteration of the loop. Moved thedebugbefore setting it to 0 so it's useful again and addedidxto the debug.