Contribution Guide
Thank you for considering a contribution to PAM. Bug reports, compatibility findings, documentation fixes, benchmarks, and focused pull requests are all welcome. This guide explains where each kind of contribution goes, how to set up the runtime locally, and what a pull request needs before it can be merged.
By contributing, you agree that your contribution is licensed under the Apache License 2.0.
Bug Reports
Section titled “Bug Reports”Report reproducible defects as an issue in
push-in/pam. The issue form asks for:
- a summary of what happened and what you expected;
- PAM, PHP, Laravel, and Octane versions, when they apply;
- the operating system, version, and CPU architecture;
- a minimal reproduction: commands, or a small public repository;
- sanitized
pam doctoroutput and logs.
The most useful bug report is one a maintainer can run. Start from a fresh project when you can:
pam init repro --template apicd repro# change the smallest thing that shows the bugpam devThen attach the diagnostics:
pam --versionpam doctorpam support --output pam-support.jsonpam support writes a bounded, path-redacted report that never collects file
contents, environment variables, or network data.
Compatibility and Performance Reports
Section titled “Compatibility and Performance Reports”Two more issue forms exist for specific findings:
- Compatibility report: a Composer package, PHP extension, or Laravel integration that does not work on PAM. Name the package and version and show how it fails.
- Performance report: a reproducible latency, throughput, or memory regression. Include the commit, dirty state, hardware, runtime versions, workers, connections, duration, and payload size, and link the complete raw output rather than screenshots.
Support Questions
Section titled “Support Questions”Issues are for defects. Ask installation, architecture, and usage questions in GitHub Discussions. See Support for what to include.
Core Development Discussion
Section titled “Core Development Discussion”Open an issue or discussion before you start any of the following, so the design can be agreed before code is written:
- a behaviour change or a substantial new feature;
- changes to stable public contracts, security boundaries, persistence semantics, wire formats, or release policy.
Changes in those areas need executable compatibility coverage and an explicit migration story when behaviour changes. Routine fixes and documentation changes can go straight to a pull request.
How Decisions Are Made
Section titled “How Decisions Are Made”PAM is maintainer-led. Maintainers are responsible for release integrity, security response, compatibility policy, and final technical decisions. When trade-offs conflict, decisions favor, in order:
- user and supply-chain safety;
- correctness and bounded resource use;
- compatibility with PHP, Composer, and Laravel contracts;
- operability and debuggability;
- measured performance;
- implementation convenience.
If consensus is not reached, the repository owner makes the final decision and documents the material trade-offs publicly, unless security or privacy prevents it. Contributor access is earned through sustained, constructive participation and sound reviews.
Which Repository?
Section titled “Which Repository?”The runtime, the CLI, and most official Composer packages live in one monorepo,
push-in/pam. Packages such as Nimbus, the
skeleton, pam-socket, pam-http-psr, and pam-http-testing are developed in
its packages/ directory and published as read-only split mirrors. Send pull
requests for those packages to push-in/pam, not to the mirror.
Other products, such as PAM Native, PAM Desktop, and the native plugins, have
their own repositories. The Repository Map lists them
all. Documentation lives in push-in/pam-docs;
see Writing Documentation.
Local Development
Section titled “Local Development”Runtime contributors need:
- Rust 1.88 (pinned in
rust-toolchain.toml, withclippyandrustfmt); - PHP 8.5 Embed development headers;
- a C toolchain;
- Composer 2.
Inspect manifests and lockfiles before changing or installing dependencies, and run the relevant dry run first.
Running the Checks
Section titled “Running the Checks”These are the same checks CI runs on the Rust code:
cargo fmt --all -- --checkcargo clippy --locked --all-targets --all-features -- -D warningscargo test --locked --all-targets --all-features -- --test-threads=1For the Laravel Octane bridge in packages/octane:
pam composer install --working-dir=packages/octane --dry-runpam composer install --working-dir=packages/octanepam composer --working-dir=packages/octane verifycargo test --locked --test cluster --test server -- --test-threads=1For Nimbus and other PHP packages, add focused PHPUnit tests and run
verify in the package directory:
pam composer --working-dir=packages/nimbus verifyAfter changing any Composer package or its publication metadata, validate the package layout:
scripts/package-release.sh validatePull Requests
Section titled “Pull Requests”Keep each pull request focused on one change. Maintainers may ask that broad work be split into smaller reviews. Every pull request should:
- describe the user-visible outcome and why it is needed;
- add regression tests;
- update documentation and the changelog when needed;
- include manifest and lockfile preflight evidence for dependency changes;
- describe compatibility, security, performance, and rollback risks.
All required CI checks must pass before a merge.
Performance Changes
Section titled “Performance Changes”Performance claims must use the checked-in benchmark protocol in benchmarks/
and disclose the source commit, dirty state, hardware, runtime versions, worker
count, and complete results. See Performance & Benchmarks.
Package Changes
Section titled “Package Changes”Package pull requests also need to:
- document public API and behaviour changes;
- explain persistent-worker risks: state that outlives a request, cleanup, cancellation, and rollback;
- keep example controllers thin, with validation in form requests, business rules in services, and domain responses in resources.
Coding Style
Section titled “Coding Style”- Rust:
rustfmtformatting andclippywith warnings denied. - PHP:
declare(strict_types=1);, typed properties and signatures, and the project formatter (pam format, which uses Pint in generated projects). - Enums: coded status, type, state, kind, and category values use
integer-backed enums with sequential values starting at
1. Existing values are never reused within a protocol version. - Safety: native capabilities stay explicit and disabled by default; never weaken a safety limit to make a demo pass.
Release Gates
Section titled “Release Gates”No PAM release can be published from repository-local tests alone. Before a tag is published, the release candidate must pass the community first-run gate:
scripts/community-experience-gate.sh allThe gate creates fresh projects in temporary directories from every official
template (raw, http, laravel, mobile, and native-ui) and starts each one
with pam dev. PAM itself must provision Composer, PHP, Gradle, the Android SDK
and NDK, and the required licenses; nobody may repair a generated project by
hand. Mobile projects only pass once the application is installed and alive on an
Android emulator, Logcat shows no runtime errors, and a real screenshot is
captured. The publication job depends on this gate and fails closed when any
template cannot complete its first run.
How a Release Ships
Section titled “How a Release Ships”Maintainers follow RELEASE.md in the runtime repository:
- Release pull request.
Cargo.toml,Cargo.lock, andCHANGELOG.mdcarry the new version with a dated## X.Y.Z - YYYY-MM-DDheading, and every changed package has its own dated changelog heading.scripts/package-release.sh validate-tag vX.Y.Zchecks both. - Tag. Pushing
vX.Y.Zfrom the merged commit onmainbuilds every target, runs the release gates, creates the GitHub release, and publishes theghcr.io/push-in/nimbus-skeletonimage (amd64 and arm64, with SBOM and provenance). - Mirrors and Packagist. The package splits are verified on the tag and published after the GitHub release exists. A public Composer dry run of the skeleton runs before the release is announced.
Security Vulnerabilities
Section titled “Security Vulnerabilities”If you discover a security vulnerability, report it privately as described in the Security Policy. Do not open a public issue.
Code of Conduct
Section titled “Code of Conduct”Everyone who participates in PAM spaces is expected to follow the Code of Conduct.