8000 test(notifications): give the slow-target test room under parallel load by adeelahmad · Pull Request #38 · adeelahmad/lense · GitHub
[go: up one dir, main page]

Skip to content

test(notifications): give the slow-target test room under parallel load - #38

Merged
adeelahmad merged 1 commit into
mainfrom
claude/notifications-webhooks-tqjjrw
Oct 2, 2026
Merged

adeelahmad merged 1 commit into
mainfrom
claude/notifications-webhooks-tqjjrw

Conversation

@adeelahmad
Copy link
Copy Markdown
Owner

Requested by Adeel · project thread

Description

Before: test_a_slow_target_is_cut_off failed once in three full pytest -n auto runs. It requires a send with a 2 s deadline to finish within 5 s, and under parallel load the threads sometimes get scheduled too late to make that.

After: the fake target now takes 30 s to answer, the deadline is 1 s and the read timeout is 10 s, so only the deadline can end the send. The test checks that the send stopped after the deadline and before half the target's 30 s. That still proves the deadline cut the send short, with about 14 s of margin. Only the test changes; notify.post is unchanged.

Motivation and Context

Follow-up from the review of #16.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My code follows the code style of this project.
  • My change requires documentation updates.
  • I have updated the documentation accordingly.
  • My change requires dependencies updates.
  • I have updated the dependencies accordingly.

Local runs: in a full pytest -n auto run, 301 tests passed and 1 failed. The failure is test_conversion.py::test_office_and_text_files_become_documents; LibreOffice in this container can't open the file, and it fails without this change too. The notifications, jobs, batches and uploads tests then passed twice more under -n auto.

🤖 Generated with Claude Code

https://claude.ai/code/session_01PqBe9ycLaqFLZvCqL5wprK


Generated by Claude Code

It asserted a 2 s deadline ended the send within 5 s, which a loaded
pytest -n auto run sometimes missed. Now the target would take 30 s, the
deadline is 1 s and the read timeout 10 s, and the test checks the send ended
between the deadline and half the target's time.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01PqBe9ycLaqFLZvCqL5wprK
@adeelahmad adeelahmad self-assigned this Oct 2, 2026
Copy link
Copy Markdown
Owner Author

Every check on this PR failed within about 3 seconds without running a single step: CI, pre-commit and PR title. Each failed job shows no runner and no steps, and GitHub has no log for it. This doesn't come from this PR's change. CI and pre-commit on main have been failing the same way since 13:32 UTC (for example run 37013710426, on the merge of #12). The same pattern on PR title suggests GitHub Actions isn't giving this repository runners at the moment, which often means an Actions spending limit or a billing problem.

I've re-run the failed jobs once. There's no code fix to port. Locally, a full pytest -n auto run passes 301 tests; the one failure is test_conversion.py::test_office_and_text_files_become_documents, which fails because this machine's LibreOffice can't open the file. The notifications tests pass under -n auto in repeated runs.


Generated by Claude Code

Copy link
Copy Markdown
Owner Author

Merging this without CI. GitHub Actions hasn't given this repository a runner since 13:32 UTC, and the re-run failed the same way. A local full run of pytest -n auto on this head stands in for it: 301 passed. The one failure is test_conversion.py::test_office_and_text_files_become_documents, because this machine's LibreOffice can't open the file; this change doesn't touch it. The notifications, jobs, batches and uploads tests passed twice more under -n auto. ruff format and ruff check are clean. Adeel allowed validated PRs to be merged without waiting for him.


Generated by Claude Code

@adeelahmad
adeelahmad merged commit 2a9301c into main Oct 2, 2026
0 of 12 checks passed
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.

2 participants

0