Pull Requests
This page describes how a change reaches the main branch of the connectum repository: fork, branch, local checks, changeset, pull request, review. The commands and checks below belong to that repository. The docs and examples repositories use the same fork-and-pull-request flow, but they have no changesets and no pull request template, and their checks differ: the docs repository provides pnpm docs:validate, pnpm docs:build and pnpm docs:validate:built, and an example brings its own scripts.
Set up the toolchain first with Development Setup. Every command here runs from the root of the framework repository.
Fork and branch
Fork
Connectum-Framework/connectumon GitHub.Clone your fork and add the original repository as
upstream:bashgit clone https://github.com/YOUR_USERNAME/connectum.git cd connectum git remote add upstream https://github.com/Connectum-Framework/connectum.git pnpm installCreate a branch from the current
main. A shorttype/topicname such asfix/amqp-reconnectordocs/auth-guideis the habit in this repository; no tool enforces it.bashgit fetch upstream git checkout -b fix/my-change upstream/mainMake the change together with its tests, and update the documentation that describes it (see Documentation Style Guide).
Push the branch to your fork and open a pull request against
mainof the upstream repository.
Keep the fork up to date
Pull requests are squash-merged, so the history of your branch does not survive. Rebase the branch onto the latest upstream main rather than merging main into it:
git fetch upstream
git rebase upstream/main
# After a rebase the branch you already pushed has to be replaced
git push --force-with-lease origin fix/my-changeTo keep your own main current, fast-forward it from upstream:
git checkout main
git merge --ff-only upstream/main
git push origin mainRun the checks before you push
The pull request template asks you to confirm pnpm build && pnpm typecheck && pnpm test and pnpm lint. CI covers more than the template: it also runs pnpm lint:repo, runs the unit and integration tests as separate steps, and has separate Bun and esbuild jobs. Running the commands below locally catches most of what CI would report.
pnpm build
pnpm typecheck
pnpm test
pnpm lint
pnpm lint:repopnpm buildcomes first: inturbo.jsonthetesttasks (and the per-packagetypechecktask) depend onbuild, and CI builds before it type checks. Runningpnpm typecheckon a fresh clone without a build is not the supported order.pnpm testruns each package's unit and integration suites. Integration suites that need a message broker skip themselves when the broker is not configured; see Testing.- Linting has two steps.
pnpm lintruns Biome over each package'ssrcdirectory.pnpm lint:reporuns Biome over the whole repository (release scripts, fixtures, interop helpers) so the same rules bind code that no package owns. CI runs both. CI additionally runspnpm lint:rules, which proves that the repository's custom Biome rules still fire, and renders the API reference with TypeDoc, where any warning (a broken{@link}, for instance) fails the job. If you change JSDoc on a public symbol,pnpm docs:apireproduces that check locally. - The full command list, including the Bun and esbuild suites (
pnpm test:bun,pnpm test:esbuild), is in CLI Commands.
Pre-commit hook
pnpm install installs a Git hook through Husky. On every git commit it:
- refuses to continue if a staged file also has unstaged changes (the
MMstatus), - generates the protobuf sources (
turbo run build:proto), - runs
pnpm run biome, which isbiome check --write --error-on-warnings .over the whole repository and rewrites formatting and import order in place, - re-stages what Biome changed.
Because the hook rewrites files, stage the changes you intend to commit, make sure git status shows no MM entries, and review the files Biome rewrote before you push. See Code Style for what Biome enforces.
Add a changeset
Versions and changelogs are produced by Changesets, not edited by hand. Do not edit a package's CHANGELOG.md; add a changeset instead:
pnpm changesetThe command asks which packages changed and at which semver level, and writes a file to .changeset/. Commit that file with your change. Add one whenever the change alters what a published @connectum/* package does or exposes: a fix, a feature, or a breaking change. A change that touches only documentation, CI, or internal tests usually has nothing to release; if you are unsure, ask in the pull request.
All @connectum/* packages belong to one fixed version group (fixed in .changeset/config.json), so they are released with the same version number. A breaking change therefore carries extra weight; the changeset format for it is described in Commit Messages.
Open the pull request
The repository's pull request template is filled in automatically when you open the pull request. Its sections are:
| Section | What to write |
|---|---|
| Summary | One to three sentences: what the change does and why. |
| Type of change | Bug fix, new feature, breaking change (with a migration guide entry), or documentation, chore, internal. |
| Test plan | The checks you ran and anything you exercised by hand, such as the affected examples. |
| Parity coverage | Either the transportParityTest() scenario you added or extended, or a short justification that the change does not alter observable RPC behavior. |
| Related issues / changes | Links to issues, ADRs, and related pull requests. |
The Parity coverage section is required for any change that touches service-observable RPC behavior. What that means and which scenarios exist is described in Parity Invariant and Parity Coverage.
Give the pull request a Conventional Commits title. The repository squash-merges, and the title becomes the commit subject on main (see Commit Messages). Link the issue it resolves with Closes #123 in the description.
Review
Reviewers expect, before a pull request is merged:
- the required CI checks pass;
- at least one maintainer approves;
- every review discussion is resolved, by a change or by an explained decision.
Which checks are required is configured in the repository's GitHub settings and is not repeated here. Respond to feedback with new commits or a rebase; maintainers merge once the conditions above are met.