Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: do not call read auth model on batchcheck and write #78

Merged
merged 4 commits into from
Apr 30, 2024

Conversation

ewanharris
Copy link
Member

Description

Removes the read auth model call in BatchCheck/Write and replaces it with checking and returning an invalid model id error and then returning an invalid auth error if one arises.

References

Part of openfga/sdk-generator#314

Review Checklist

  • I have clicked on "allow edits by maintainers".
  • I have added documentation for new/changed functionality in this PR or in a PR to openfga.dev [Provide a link to any relevant PRs in the references section above]
  • The correct base branch is being used, if not main
  • I have added tests to validate that the change in functionality is working as expected

@ewanharris ewanharris force-pushed the fix/dont-read-model-on-batch-check branch from a2f6214 to abe6884 Compare April 30, 2024 08:42
@ewanharris ewanharris marked this pull request as ready for review April 30, 2024 08:42
@ewanharris ewanharris requested a review from a team as a code owner April 30, 2024 08:42
@codecov-commenter
Copy link

codecov-commenter commented Apr 30, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 22.49%. Comparing base (d27ef8f) to head (e9b3d66).
Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #78      +/-   ##
==========================================
- Coverage   22.51%   22.49%   -0.03%     
==========================================
  Files          94       94              
  Lines        9758     9750       -8     
==========================================
- Hits         2197     2193       -4     
+ Misses       7308     7306       -2     
+ Partials      253      251       -2     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

client/client.go Outdated Show resolved Hide resolved
Copy link
Member

@rhamzeh rhamzeh left a comment

Choose a reason for hiding this comment

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

2790f77 (#78)
can be removed

client/client_test.go Outdated Show resolved Hide resolved
client/client_test.go Outdated Show resolved Hide resolved
client/client_test.go Outdated Show resolved Hide resolved
client/client_test.go Outdated Show resolved Hide resolved
@ewanharris ewanharris added this pull request to the merge queue Apr 30, 2024
Merged via the queue into main with commit c50b18f Apr 30, 2024
9 checks passed
@ewanharris ewanharris deleted the fix/dont-read-model-on-batch-check branch April 30, 2024 19:07
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.

3 participants