Compilations
Each time the Stagenet builds your repository, it creates a compilation — a record of what was built, from which commit, and whether it succeeded. Every connected repository has its own compilation history under the Compilations tab.
What triggers a compilation
- Push to the connected branch — the GitHub App receives a webhook for every push and starts a new compilation automatically.
- Initial connection — when you first add a repository, the Stagenet runs an initial compilation against the default branch.
- Manual trigger — the Compile button in the repository’s Overview tab queues a new compilation against the latest commit on the connected branch.
- Build config change — saving a change to the Build Configuration triggers a fresh compilation.
The compilation record stores the trigger (auto for a push, manual for a UI-initiated build) so you can tell at a glance which build came from where.
Statuses
| Status | Meaning |
|---|---|
| Pending | Queued, hasn’t started yet. |
| Running | The Stagenet is cloning, installing, and compiling. |
| Success | The compile finished and artifacts were imported. Matching Imported Contracts are created or versioned. |
| Failed | The compile finished with a non-zero exit status, or an internal error stopped the build. The error message and logs are on the compilation page. |
Reading a compilation
Open any compilation to see:
- The commit it built from
- Start/end timestamps and duration
- Full stdout and stderr from your install and compile commands
- An error message (when the build failed)
- The list of artifacts that were imported (when the build succeeded), with bytecode sizes and source paths
This is the first place to look when a build fails. The captured logs are exactly what your installCommand and compileCommand printed.
Debugging a failed build
Common causes, roughly in order of how often they cause failures:
- Missing build dependencies — the install command didn’t pull in something the compile step needs (e.g. a private package, a git submodule, a Foundry library). Confirm your install command runs cleanly on a fresh clone.
- Wrong project root — the Stagenet is running install/compile from the repository root, but your project lives in a subdirectory. Set Project root.
- Missing environment variables — your
hardhat.configor build scripts readprocess.env.Xbut the Stagenet doesn’t haveXset. Add it under Environment variables. - Solidity compiler version mismatch — the project pins a specific solc that isn’t installed in the build environment. Hardhat usually auto-downloads compilers; Foundry uses whatever
foundry-toolchainships. - No artifacts produced — compile succeeded but the Artifact Selection globs didn’t match anything. The compilation page lists which artifacts were imported (or none).
After fixing the underlying issue, push a new commit or click Compile to retry — every retry creates a fresh compilation record so you keep the history of what you tried.
Compilation history
Every compilation is kept, not just the latest. This is useful when:
- A build that was passing starts failing — comparing recent compilations narrows down which commit introduced the regression.
- You want to know what bytecode was deployed against what was in the source at the time — each Imported Contract version links back to the compilation that produced it.