Skip to content

Fix stale test_lock_bypass_fixes patch of removed is_trial_paywalled (#9357 drift)#9394

Closed
ZachL111 wants to merge 1 commit into
BasedHardware:mainfrom
ZachL111:zach/fix-lock-bypass-test-isolation
Closed

Fix stale test_lock_bypass_fixes patch of removed is_trial_paywalled (#9357 drift)#9394
ZachL111 wants to merge 1 commit into
BasedHardware:mainfrom
ZachL111:zach/fix-lock-bypass-test-isolation

Conversation

@ZachL111

@ZachL111 ZachL111 commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

tests/unit/test_lock_bypass_fixes.py::TestScheduledDailySummaryLockFilter fails on current main (in isolation and in the full unit suite), which reds the Backend unit suite on any full-suite PR.

Root cause

#9357 ("stop gating the daily recap on the desktop trial paywall") removed the is_trial_paywalled call from _send_summary_notification in utils/other/notifications.py, so utils.other.notifications no longer exposes is_trial_paywalled. Both tests still did patch('utils.other.notifications.is_trial_paywalled', ...), which raises AttributeError: <module 'utils.other.notifications'> does not have the attribute 'is_trial_paywalled'.

Change

Remove the vestigial is_trial_paywalled patch from test_scheduled_summary_excludes_locked and test_scheduled_summary_skips_when_all_locked. The tests still cover the locked-conversation filtering behavior, which is their actual purpose.

Testing

  • tests/unit/test_lock_bypass_fixes.py: 61 passed (was 2 failed + 59 passed).
  • The failure reproduces on plain origin/main and is fixed by this change.
  • Ran black, py_compile, and check_module_stub_pollution; all clean.

Review in cubic

…edHardware#9357

BasedHardware#9357 stopped gating the daily recap on the desktop trial paywall, removing the
is_trial_paywalled call from _send_summary_notification. test_lock_bypass_fixes still
patched utils.other.notifications.is_trial_paywalled, which no longer exists there, so
TestScheduledDailySummaryLockFilter failed with AttributeError on every run (in isolation
and in the full unit suite), redding the Backend unit suite on full-suite PRs. Remove the
vestigial patch; the tests still cover the locked-conversation filter, their actual purpose.
@ZachL111

Copy link
Copy Markdown
Contributor Author

Note for reviewers: this test is failing on main itself, not just on this branch. TestScheduledDailySummaryLockFilter patches utils.other.notifications.is_trial_paywalled, which #9357 removed from _send_summary_notification, so it raises AttributeError on any run and reds the Backend unit suite on full-suite PRs. This drops the stale patch; the tests still cover the locked-conversation filter, and the file goes from 2 failed to 61 passed.

@Git-on-my-level Git-on-my-level left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Good catch and clean fix. Verified that is_trial_paywalled is no longer importable from utils.other.notifications on main (it only appears in the comment block documenting the #9357 removal), so the stale patch(...) was guaranteed to raise AttributeError and red the Backend unit suite.

The change correctly removes the vestigial patch from both test_scheduled_summary_excludes_locked and test_scheduled_summary_skips_when_all_locked while preserving all the locked-conversation filtering assertions that are the actual purpose of those tests. The added comments clearly explain the drift for future readers.

All checks green, test-only, single commit. Thanks for the contribution!

@ZachL111 ZachL111 force-pushed the zach/fix-lock-bypass-test-isolation branch from f046dd2 to 77105f0 Compare July 11, 2026 00:42
@ZachL111

Copy link
Copy Markdown
Contributor Author

Closing as superseded by main. main already removed the is_trial_paywalled gating from _send_summary_notification (#9357) and dropped the now-stale patch from both TestScheduledDailySummaryLockFilter tests, with the reasoning documented inline. This branch only conflicts against that change and has nothing left to add. Happy to reopen if I have missed something.

@ZachL111 ZachL111 closed this Jul 11, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Hey @ZachL111 👋

Thank you so much for taking the time to contribute to Omi! We truly appreciate you putting in the effort to submit this pull request.

After careful review, we've decided not to merge this particular PR. Please don't take this personally — we genuinely try to merge as many contributions as possible, but sometimes we have to make tough calls based on:

  • Project standards — Ensuring consistency across the codebase
  • User needs — Making sure changes align with what our users need
  • Code best practices — Maintaining code quality and maintainability
  • Project direction — Keeping aligned with our product principles and locked invariants

Before your next PR, please skim:

  • PRODUCT.md — product north star
  • Product invariants — locked rules (shared chat, memory tiers, agent control plane, integrations, brand)

If this was declined for direction or taste, maintainers should cite an invariant ID or open a proposed one — ask if that citation is missing.

Your contribution is still valuable to us, and we'd love to see you contribute again in the future! If you'd like feedback on how to improve this PR or want to discuss alternative approaches, please don't hesitate to reach out.

Thank you for being part of the Omi community!

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