Skip to content

docs: Add deprecated docstrings to all legacy FGA methods#1546

Merged
atainter merged 1 commit intomainfrom
at-add-deprecation-docstrings-fga
Apr 6, 2026
Merged

docs: Add deprecated docstrings to all legacy FGA methods#1546
atainter merged 1 commit intomainfrom
at-add-deprecation-docstrings-fga

Conversation

@atainter
Copy link
Copy Markdown
Contributor

@atainter atainter commented Apr 6, 2026

No description provided.

@atainter atainter requested review from a team as code owners April 6, 2026 21:31
@atainter atainter requested a review from marji-workos April 6, 2026 21:31
@greptile-apps
Copy link
Copy Markdown
Contributor

greptile-apps bot commented Apr 6, 2026

Greptile Summary

This PR adds method-level @deprecated JSDoc annotations to all 12 methods of the FGA class in src/fga/fga.ts, complementing the already-existing class-level deprecation notice. This is a documentation-only change with no logic modifications.

  • All 12 FGA methods now carry a @deprecated tag and a @see src/authorization/authorization.ts reference, consistent with the class-level annotation that was already present.
  • 6 of the 12 deprecated methods (checkBatch, writeWarrant, batchWriteWarrants, listWarrants, query, batchWriteResources) have no direct equivalent in the Authorization module, so the uniform @see reference alone may not provide sufficient migration guidance for users of those methods.
  • No functional code is modified; the change is purely additive documentation.

Confidence Score: 5/5

Safe to merge — this is a documentation-only change with no logic modifications.

All 12 FGA methods are correctly annotated with @deprecated and no methods were missed. The sole observation is a P2 style suggestion about the @see reference being potentially insufficient for the 6 methods with no Authorization equivalent. P2 findings do not block merge.

No files require special attention.

Important Files Changed

Filename Overview
src/fga/fga.ts Adds @deprecated JSDoc annotations to all 12 FGA methods; all methods are covered, though the uniform @see reference may not guide users of the 6 methods with no Authorization equivalent

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[Developer calls FGA method] --> B{Direct equivalent in\nAuthorization module?}
    B -- Yes --> C["check / createResource / getResource\nlistResources / updateResource / deleteResource"]
    B -- No --> D["checkBatch / writeWarrant / batchWriteWarrants\nlistWarrants / query / batchWriteResources"]
    C --> E[Migrate to Authorization module\nsrc/authorization/authorization.ts]
    D --> F[No direct equivalent —\nmigration guide needed]
Loading

Reviews (1): Last reviewed commit: "Add deprecated docstrings to all legacy ..." | Re-trigger Greptile

Comment on lines +62 to +64
* @deprecated The FGA module is deprecated. Use the Authorization module instead.
* @see src/authorization/authorization.ts
*/
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

P2 @see reference may be insufficient for some FGA methods

The @see src/authorization/authorization.ts annotation is applied uniformly to all 12 methods, but 6 of them — checkBatch, writeWarrant, batchWriteWarrants, listWarrants, query, and batchWriteResources — have no direct equivalent in the Authorization module. Developers trying to migrate those calls will find no corresponding method to switch to.

Consider supplementing the @see tag with a link to an external migration guide or changelog entry that covers every FGA method, not only those that map cleanly into Authorization.

@atainter atainter changed the title Add deprecated docstrings to all legacy FGA methods docs: Add deprecated docstrings to all legacy FGA methods Apr 6, 2026
@atainter atainter merged commit 4ef8f19 into main Apr 6, 2026
8 of 9 checks passed
@atainter atainter deleted the at-add-deprecation-docstrings-fga branch April 6, 2026 21:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants