Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Conversation

@Abishek-Newar
Copy link
Contributor

@Abishek-Newar Abishek-Newar commented Oct 27, 2025

Description

Added a standardized Makefile would make it much easier to test and lint the code locally with simple, consistent commands which would make it easy for contrubuters.

What problem is being solved?

How is it being solved?

What changes are made to solve it?

Added a Makefile to it

References

Closes #239

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

Summary by CodeRabbit

  • Chores
    • Added development tooling to streamline common build and validation workflows.

Note: This release contains no user-facing changes. Updates are limited to internal development infrastructure.

@Abishek-Newar Abishek-Newar requested a review from a team as a code owner October 27, 2025 14:04
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Oct 27, 2025

Important

Review skipped

Auto incremental reviews are disabled on this repository.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Walkthrough

A new Makefile is added to the java-sdk repository with PHONY targets for common development tasks: help, test, test-integration, lint, and fmt. Each target wraps the corresponding Gradle command.

Changes

Cohort / File(s) Summary
Build Automation
Makefile
New file with PHONY targets: help (default), test, test-integration, lint, and fmt. Each wraps Gradle commands for testing, integration testing, linting, and code formatting.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

  • Single new file with simple, straightforward make targets
  • No logic complexity or conditional flows
  • Direct wrapper around existing Gradle commands
  • Minimal surface area for errors

Possibly related issues

Pre-merge checks and finishing touches

❌ Failed checks (1 warning)
Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. You can run @coderabbitai generate docstrings to improve docstring coverage.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title Check ✅ Passed The pull request title "chore: Added a top-level Makefile in java-sdk to simplify running tests and linters" directly and clearly summarizes the main change in the changeset. The title accurately describes what was added (a top-level Makefile) and its purpose (to simplify running tests and linters), which is exactly what the raw summary confirms. The title is specific, concise, and would be immediately understandable to someone reviewing the commit history.
Linked Issues Check ✅ Passed The pull request successfully meets all primary objectives from linked issue #239. The Makefile includes the three core required targets: test (mapping to ./gradlew test), lint (mapping to ./gradlew check), and fmt (mapping to ./gradlew spotlessApply). These targets directly enable the stated goal of allowing contributors to run "make test", "make lint", and "make fmt" for simplified local workflows. The implementation follows the exact specifications provided in the issue's minimal solution, establishing the unified Makefile approach requested across the SDK ecosystem.
Out of Scope Changes Check ✅ Passed All changes in this pull request are directly related to the stated objective of adding a Makefile to simplify testing and linting workflows. The Makefile includes the required targets (test, lint, fmt) plus two additional targets: help (which displays available targets) and test-integration (which runs integration tests). These additions are reasonable enhancements within scope, as they directly serve the Makefile's purpose of providing convenient testing shortcuts and improved discoverability through the help target. No unrelated or extraneous changes were introduced outside the scope of Makefile implementation.

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
Makefile (1)

1-9: Consider adding clean and all targets for completeness.

While the current targets meet the stated objectives, adding a clean target (./gradlew clean) and an all target (perhaps running tests and lint) would align with common Makefile conventions and provide a more complete development workflow. The static analysis tool flagged these as missing standard targets.

# Clean build artifacts
clean:
	./gradlew clean

# Run all tests
all: test lint
	@echo "All checks completed"

These are optional additions; the current Makefile is fully functional without them.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a46765a and dfec769.

📒 Files selected for processing (1)
  • Makefile (1 hunks)
🧰 Additional context used
🪛 checkmake (0.2.2)
Makefile

[warning] 1-1: Missing required phony target "all"

(minphony)


[warning] 1-1: Missing required phony target "clean"

(minphony)

🔇 Additional comments (2)
Makefile (2)

1-25: Implementation meets PR objectives effectively.

The Makefile provides the standardized shortcuts requested in issue #239: make test, make lint, and make fmt wrap the corresponding Gradle commands. The help target is well-designed as the default, and the bonus test-integration target adds useful flexibility.


13-25: Verify ./gradlew wrapper is committed to the repository.

The Makefile assumes the Gradle wrapper script (./gradlew) is available in the repository root. Ensure it's committed and that contributors on all platforms (Windows, macOS, Linux) can execute these targets without additional setup.

Copy link
Member

@SoulPancake SoulPancake left a comment

Choose a reason for hiding this comment

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

Thanks, LGTM

@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 36.39%. Comparing base (aa07907) to head (3f31521).

❌ Your project status has failed because the head coverage (36.39%) is below the target coverage (80.00%). You can increase the head coverage or adjust the target coverage.

Additional details and impacted files
@@            Coverage Diff            @@
##               main     #242   +/-   ##
=========================================
  Coverage     36.39%   36.39%           
  Complexity     1141     1141           
=========================================
  Files           188      188           
  Lines          7185     7185           
  Branches        822      822           
=========================================
  Hits           2615     2615           
  Misses         4465     4465           
  Partials        105      105           

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

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@SoulPancake SoulPancake added this pull request to the merge queue Oct 29, 2025
Merged via the queue into openfga:main with commit b69eb86 Oct 29, 2025
15 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.

Add a top-level Makefile in java-sdk to simplify running tests and linters

3 participants

Morty Proxy This is a proxified and sanitized view of the page, visit original site.