Skip to content

fix: ensure team scoping wraps sub filters - #158

Merged
bougyman merged 2 commits into
mainfrom
make-teams-work
Aug 19, 2026
Merged

fix: ensure team scoping wraps sub filters#158
bougyman merged 2 commits into
mainfrom
make-teams-work

Conversation

@bougyman

Copy link
Copy Markdown
Member

No description provided.

Copilot AI lite review requested due to automatic review settings August 19, 2026 21:11

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

page/3 was unconditionally including "after" => nil in the GraphQL
variables on the first page request. The cli_test.exs assertion used
exact equality (==) against the variables map, so the extra null key
caused an assertion error that cascaded into a full BEAM VM exit (88).

Only include "after" in the variables map when a cursor is present.
Also add "pageInfo" to the cli_test.exs stub response so it matches
the real API response shape for the paginated query.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@bougyman

Copy link
Copy Markdown
Member Author

Fixed the failing unit test.

Root cause: page/3 unconditionally included "after" => nil in the GraphQL variables on the first-page request. The test at test/linear_cli/cli_test.exs:410 used exact equality (==) to assert the variables map, so the unexpected "after" => nil key caused an ExUnit.AssertionError that escaped through the Req stub callback, got wrapped in Ash.Error.Unknown, and finally hit CLI.main's catch-all rescue which called System.halt(88) — terminating the entire BEAM VM mid-run.

Changes:

  • app/lib/linear_cli/linear/project.ex: page/3 now only includes "after" in the variables map when a cursor is present (not nil).
  • app/test/linear_cli/cli_test.exs: Added "pageInfo" to the stub response so it matches the real API response shape for the paginated query.

@bougyman
bougyman merged commit bc19184 into main Aug 19, 2026
2 checks passed
@bougyman
bougyman deleted the make-teams-work branch August 19, 2026 21:32
bougyman pushed a commit that referenced this pull request Aug 20, 2026
🤖 I have created a release *beep* *boop*
---


##
[1.15.2](v1.15.1...v1.15.2)
(2026-08-19)


### Bug Fixes

* ensure team scoping wraps sub filters
([#158](#158))
([bc19184](bc19184))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).
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