Skip to content

TEMP DO NOT MERGE: chore(nimbus): KINTODIAG instrumentation for kinto approve - #16995

Closed
jaredlockhart wants to merge 3 commits into
mainfrom
kinto-diag
Closed

TEMP DO NOT MERGE: chore(nimbus): KINTODIAG instrumentation for kinto approve#16995
jaredlockhart wants to merge 3 commits into
mainfrom
kinto-diag

Conversation

@jaredlockhart

Copy link
Copy Markdown
Collaborator

TEMP DO NOT MERGE. Throwaway diagnostic branch. Closes no issue, must never be merged, and will be deleted once the log evidence is captured.

Because

This commit

  • Logs KINTODIAG lines from approve() on entry, on every poll, on the KintoException branch, on success and on exhaustion, each carrying the xdist worker, the caller from PYTEST_CURRENT_TEST, wall clock and elapsed time.
  • Names the slugs a pending review carries, by diffing the main-workspace bucket against the signed main bucket (get_record_data() alone returns every workspace record, signed or not).
  • Logs the selenium teardown's slug, rollout decision and approve outcome, including swallowed exceptions.
  • Adds --count 3 to the nimbus_ui job to provoke the intermittent failure within one run.

Base is deliberate: origin/main + #16981 + #16980, so the failure is reproduced with both fixes and with first-attempt tracebacks printing.

Because

* The selenium teardown called approve() on the kinto_client factory, so it
  raised AttributeError and was swallowed by the bare except.
* end_experiment() still ran, leaving a pending review that a later test signs
  as if it were its own, cascading until a test finds nothing pending and
  raises "Unable to approve kinto review".
* approve() retries for 120s, so activating the teardown unbounded would burn
  that budget per test whenever no review is pending.

This commit

* Calls the factory so the teardown approves via a KintoClient instance.
* Adds an optional retries argument to approve(), leaving the default budget
  unchanged for in-test callers.
* Bounds the teardown to a short explicit budget.

Fixes #16978
Because

* the constraint was capped at <15, resolving to 14.0, which predates pytest 9.1 support (added in 16.4)
* reruns of integration tests with chained fixtures die during setup instead of retrying, so the session ends in error with nothing recorded as failed
* the first attempt's traceback never reaches the CI log, leaving the real failure readable only from the uploaded report artifact

This commit

* bumps pytest-rerunfailures to >=16.4,<17 and re-locks
* adds --rerun-show-tracebacks to the integration test jobs that pass --reruns 1

Fixes #16979
… approve

TEMP DO NOT MERGE. Throwaway diagnostic branch for the residual
"Unable to approve kinto review" intermittency. Not to be merged.

Because

* `Desktop Nimbus UI` still fails ~9.5% of runs with `Unable to approve
  kinto review` after both the `--dist loadgroup` and selenium-teardown
  fixes, and the current code logs nothing about what was pending
* `KintoClient.approve()` is slug-blind and its `KintoException` branch
  is a silent `pass`, so cross-worker signing of another test's review
  would be invisible
* the selenium teardown swallows every exception, so its outcome is
  unobservable

This commit

* logs `KINTODIAG` lines from `approve()` on entry, per poll, on the
  `KintoException` branch, on success and on exhaustion, with the
  xdist worker, the caller from `PYTEST_CURRENT_TEST`, wall clock and
  elapsed time
* names the slugs a pending review carries by diffing the workspace
  bucket against the signed main bucket
* logs the selenium teardown's slug, rollout decision and approve
  outcome, including swallowed exceptions
* adds `--count 3` to the `nimbus_ui` job to provoke the failure
@jaredlockhart

Copy link
Copy Markdown
Collaborator Author

Closing: the instrumentation belongs in #16981 itself, where the fix under test lives. Moved there as cc1a08366.

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.

1 participant