Overview
All contributions to Ryujinx are made via pull requests rather than direct commits. PRs are reviewed and merged by maintainers after approval from at least two core team members.To merge pull requests, you must have write permissions in the repository.
Quick Code Review Rules
DO
- Follow existing code style
- Keep changes focused and related
- Use Draft PRs for early feedback
- Rebase when requested
- Make review changes as new commits
DON'T
- Mix unrelated changes
- Add unjustified dependencies
- Resolve conversations prematurely
- Force-push during review
Code Review Rules in Detail
Keep Changes Focused
Good PR - Single focused change
Bad PR - Mixed unrelated changes
Follow Code Style
All changes must follow the existing code style. Read more at docs/coding-style.Avoid External Dependencies
Any dependency addition must be:- Justified with clear reasoning
- Discussed with maintainers before merge
- Properly licensed and attributed
Draft Pull Requests
Use Draft PRs for:- Work in progress that needs early CI feedback
- Changes you want to discuss before formal review
- Experimental implementations
Rebasing Changes
Rebase your changes when required or directly requested. Changes should always be committed on top of the upstream branch.Use
--force-with-lease instead of --force to avoid accidentally overwriting others’ work.Making Review Changes
If asked to make changes during review:Pull Request Ownership
Automatic Assignment
Every pull request automatically receives:- Labels indicating which code segment is affected
- Reviewers assigned based on the area being modified
Merge Conflict Resolution
If a merge conflict occurs during review, the PR author is responsible for resolution.- Using Git (Recommended)
- Using GitHub Web UI
Pull Request Builds
When you submit a PR, various CI workflows validate your changes.CI Workflows
From.github/workflows/build.yml:
Build Job
Build Job
Compiles Ryujinx for all platforms:
- Windows (x64, ARM64)
- Linux (x64, ARM64)
- macOS (x64, Universal)
Test Job
Test Job
Runs all unit tests:Skipped for
linux-arm64 due to emulationFormat Check
Format Check
Validates code style:
Viewing Build Results
Navigate to Actions tab
Go to Actions tab in your PR
Common CI Failures
Code style violations
Code style violations
Error:
dotnet format found style issuesFix:Compilation errors
Compilation errors
Error: Build failed with compiler errorsFix: Review the build log in Actions tab, fix the errors locally, test with
dotnet build, then pushTest failures
Test failures
Error: Unit tests failedFix: Run tests locally:Fix failing tests and push changes
Platform-specific failures
Platform-specific failures
Error: Build succeeds locally but fails in CI for specific platformFix: Check for platform-specific code paths. Use conditional compilation if needed:
Review Turnaround Times
Ryujinx is maintained by volunteers on a free-time basis.Best Practices to Avoid Review Purgatory
Make reviewers' lives easier
- Use descriptive commit messages
- Add code comments for complex logic
- Include XML docs where applicable
Example PR Description
Merging Pull Requests
Anyone with write access can merge a PR when:CI passes
All tests and builds succeed in CI
Follow-Up Reviews
Merge Strategy
Typically, PRs are merged as one commit (squash merge). This creates a cleaner history than merge commits.- Squash Merge (Default)
- Merge Commit (Special Cases)
All commits in the PR are squashed into a single commit on main.Use for: Most PRs with multiple small commits
Blocking PR Merging
If you need to prevent your PR from being merged:- Convert to Draft
- Add [WIP] prefix
Select “Convert to draft” under the reviewers section
Old Pull Request Policy
The team periodically reviews older PRs for relevance.Inactive or outdated PRs may be closed. As the PR owner, you can reopen if you feel it still needs attention.
PR Checklist
Before submitting your PR, ensure:- Code follows the coding style guidelines
-
dotnet formathas been run - All tests pass locally (
dotnet test) - New tests added for new functionality
- PR description clearly explains the changes
- Related issue is linked (if applicable)
- No unrelated changes included
- Commits have clear, descriptive messages
- No new external dependencies without justification
- Breaking changes are clearly documented
Review Response Examples
Requesting Clarification
Agreeing with Feedback
Respectfully Disagreeing
Working with Multiple Reviewers
When receiving conflicting feedback:Next Steps
Contributing Guide
Full contribution guidelines
Coding Style
Learn code conventions
Testing
Write and run tests