Repository navigation
Release: Next release milestone (release v1.9.0) - #199
Merged
Merged
Conversation
… list rail0 keys balance --rpc-url https://rpc.mainnet.arc.io printed the native balance as '5 native': the symbol came only from the gateway's chain catalog, and a testnet environment does not list Arc mainnet (5042). Now a chain missing from the catalog falls back to the gas coin of well-known chains (Arc USDC, Ethereum/Base/Arbitrum/ Optimism ETH, Polygon POL, Avalanche AVAX, Celo CELO, mainnets and testnets), and only then to 'native'. go.sum: the rail0-go v1.10.0 entries main lacks (the same change as #192), so this branch builds on its own. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Production's chain set is now decided: Arc mainnet only, accepting USDC and EURC. So 'rail0 env production' writes chain arc (the production gateway resolves the slug to Arc mainnet, 5042) and token USDC, like development and staging, instead of base-url alone, after which every command asked for --chain. Still no admin-url: the production admin has no domain yet. A stored legacy chain-id is now restated as chain on the way to production too, rather than cleared as stale. README table, help text and docs regenerated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…efault On Arc the gas coin IS USDC: the native balance (18 decimals) and the USDC ERC-20 (6 decimals, the scale payments, the admin and the gateway use) are one balance. The default read showed only the native row, which read as a different amount. Now, on Arc mainnet (5042) and testnet (5042002), the default prints both rows and a note saying they are the same balance. --token and --tokens are unchanged; other chains keep the native row alone. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Payouts are not part of rail0's first phase: the gateway answers every payout route 404 unknown_route unless RAIL0_FEATURE_PAYOUTS is on (rail0-gateway f8c55a5). So 'rail0 payouts' is Hidden: out of --help, shell completion and the generated reference (docs/cli and docs/man drop its pages). It still runs when typed, for a gateway with the feature on, and the README keeps its section with a note on top. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Slack mrkdwn: *<url|release notes>*, so the link stands out under the release line like the field labels below it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
'rail0 keys balance <addr> --rpc-url <Arc mainnet> --token USDC' against the staging gateway failed as 'unknown token "USDC" on chain 5042 — available: ' with an empty list. When the gateway lists no token at all on the chain, the error now says the environment does not serve that chain (switch with 'rail0 env' or --base-url); keys balance adds that the token's 0x address works without the gateway. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
… env switch, rail0 balance The config file now records the active environment (production when absent) and a block of settings per environment; `config set/get/unset` work on the active one, and base-url, chain and token have built-in defaults in every environment (production: api.rail0.xyz, arc, USDC), so no payment command needs -c/-t. `env <name>` only records the choice, keeps every session, and is hidden from help, completion, docs and README; `env --help` still answers. `keys balance` becomes the top-level `rail0 balance`. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…a milestone branch Change pull requests target a milestone branch (release/next) instead of main; its one pull request into main is the release, so one approval covers the milestone. On that branch, release-prepare now takes the version and the notes from the pull requests merged into it (plus main since the last tag); the branch's own pull request title counts only on a feature branch with none. README describes the flow. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…a milestone branch (#198) Change pull requests now target the milestone branch `milestone/next` (milestone "Next release") instead of `main`. The developer merges into it only what is meant to ship, and its single pull request into `main` is the release, so one approval covers the whole milestone. **What changes in `bin/release-prepare`.** Run on a milestone branch, it now takes the version and the notes from the pull requests merged into that branch (its first-parent history above `main`), together with what `main` holds since the last tag. - The milestone pull request's own title does not count. - A feature branch with no pull requests merged into it behaves as before: its own title counts. - Merges of `main` into the branch and the release bump commit are left out. The README "Releasing" section describes the flow. **Tests.** `bin/release-prepare-test` gains 7 milestone checks: - the bump comes from the merged `feat`; - both merged pull requests appear in the notes; - the branch's own title is not a change; - a real run updates the pull request; - a re-run does not bump again; - the bump commit stays out of the notes. The whole harness passes. Not a release. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
… list (#194) `rail0 keys balance <addr> --rpc-url https://rpc.mainnet.arc.io` printed the native balance as `"symbol": "native"`, `"5 native"`. The symbol came only from the gateway's chain catalog, and the current environment (staging) lists testnets only, so it does not know Arc mainnet (5042). **Change** - `nativeSymbol(chain)`: the catalog's symbol first; for a chain the catalog does not list, the gas coin of a well-known chain; otherwise `native`, as before. The well-known chains are Arc 5042/5042002 → USDC, Ethereum, Base, Arbitrum and Optimism → ETH, Polygon → POL, Avalanche → AVAX, Celo → CELO, mainnets and testnets. - Test: `TestKeysBalanceNativeSymbolOfAChainTheGatewayDoesNotList`. On chain 5042 the native row reads `1.5 USDC`; a listed chain keeps its catalog symbol; an unknown chain still reads `native`. - `go.sum`: adds the rail0-go v1.10.0 entries `main` is missing, the same change as #192, so this branch builds and passes the now-required `check` on its own. The two changes are identical, so whichever merges second has nothing left to merge. - **Token symbol on a chain the gateway does not serve** (f92d429): `rail0 keys balance <addr> --rpc-url https://rpc.mainnet.arc.io --token USDC` against the staging gateway failed as `unknown token "USDC" on chain 5042 — available: ` with an empty list. When the gateway lists no token on the chain, the error now says the environment does not serve that chain (point `--base-url` at a gateway that does), and `keys balance` adds that the token's 0x address works without the gateway. Covered by `TestKeysBalanceTokenSymbolOnAChainTheGatewayDoesNotServe`. **Checks:** gofmt, `go build ./...`, `go vet ./...`, `go test ./...`, `bin/docs` (no docs change), `bin/release-prepare-test`. Not a release: it can ride with the next one. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
One line in `.github/workflows/release.yml`: the Slack payload's link is now `*<url|release notes>*` (mrkdwn bold), so it stands out under the release line like the field labels below it. The same change is made in rail0-ts, rail0-go, rail0-ruby and rail0-cli. The workflow YAML still parses. No release: the next one uses it. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
# Conflicts: # cmd/keys_balance.go # cmd/keys_balance_test.go
# Conflicts: # cmd/balance.go
…s, payouts commands hidden (#195) Three changes for the production launch on Arc mainnet, one commit each. ## 1. `rail0 env production` sets chain `arc` and token `USDC` (6b657d3) Production's chain set is now decided: **Arc mainnet only**, accepting USDC and EURC. Until now `production` declared `base-url` alone, so after `rail0 env production` every command asked for `--chain`. Now it writes `chain: arc` and `token: USDC`, as development and staging do. The production gateway resolves the slug `arc` to Arc mainnet (5042). - There is still no `admin-url`: the production admin has no domain yet. - A stored legacy `chain-id` is now restated as `chain` on the way to production too, instead of being cleared as stale. - README table, help text and the `env` docs are updated. The `env` tests are updated to match. ## 2. On Arc, `keys balance` shows the native and the ERC-20 USDC (0bcebec) On Arc the gas coin **is** USDC: the native balance (18 decimals) and the USDC ERC-20 at `0x3600…0000` (6 decimals, the scale payments, the admin and the gateway use) are the same balance. The default read showed only the native row, which read as a different amount. On Arc mainnet (5042) and testnet (5042002), the default output now has both rows and a `note`. `--token` and `--tokens` are unchanged, and other chains keep the native row alone. ``` $ rail0 keys balance 0x2D2B…57D5 --rpc-url https://rpc.mainnet.arc.io balances: native 10 (18 dec) · 0x3600…0000 10 USDC (6 dec) note: on Arc the native USDC (18 decimals) and the USDC ERC-20 (6 decimals) are the same balance ``` The first row still shows `native` as its symbol. #194 fixes that for a chain the gateway does not list. New test: `TestKeysBalanceDefaultOnArcShowsBothScales`. ## 3. `rail0 payouts` is hidden (1612bf8) Payouts are not part of rail0's first phase. The gateway answers every payout route `404 unknown_route` unless `RAIL0_FEATURE_PAYOUTS` is on (rail0-gateway f8c55a5). - `payoutsCmd` is `Hidden`, so it is out of `--help`, shell completion and the generated reference. Its pages in `docs/cli` and `docs/man` are removed. - It still runs when typed, against a gateway with the feature on. - The README keeps its Payouts section, with a note on top. ## Checks gofmt, `go vet ./...`, `go test ./...`, the docs-drift check (`go run ./tools/gendocs` leaves `docs/` clean), `bin/release-prepare-test`. Tried `keys balance` against Arc mainnet. No release in this PR: run `bin/release-prepare` on the branch when you want it to ship. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
# Conflicts: # README.md # cmd/balance.go # cmd/env.go # cmd/env_test.go # docs/cli/rail0_env.md # docs/man/rail0-env.1 # docs/man/rail0.1
… env switch, rail0 balance (#197) ## What changes **Config file: environment + per-environment settings.** `config.yaml` now holds `environment:` (the active one; absent = `production`) and `environments.<name>.<key>` blocks. `config set / get / unset` work on the active environment for `base-url`, `admin-url`, `chain`, `token` (and the legacy `chain-id`); `output` and `http-timeout` stay global in `settings`. Resolution: flag > env var > config file > the environment's built-in default. **Built-in defaults in every environment.** `base-url`, `chain` (`arc`) and `token` (`USDC`) are defaulted on development, staging and production, so a payment command needs neither `-c` nor `-t` out of the box. `rail0 config` lists them with origin `<env> default`; `config unset` returns to the default. **`env` is hidden.** It only records the chosen environment (remembered for every later command), no longer clears settings or revokes the session of the gateway it leaves (sessions are per gateway and stay cached), and is left out of `rail0 --help`, completion, the generated reference and the README. `rail0 env --help` and the command keep working. **`rail0 balance`** replaces `keys balance` (same flags and behaviour), listed under "Network catalog". ## Breaking - `settings.base-url / chain / chain-id / token / admin-url` in an existing `config.yaml` are no longer read (no migration, by decision: the CLI has no external users yet). Move them under `environments.<name>` or just `config set` them again. - `rail0 keys balance` is gone; use `rail0 balance`. ## Verification `go build`, `go vet`, `go test ./...` green; `docs/` regenerated (env pages removed, balance page added); smoke-tested against a converted local config (`env current -d`, `config`, `env -d`, `balance --help`). 🤖 Generated with [Claude Code](https://claude.com/claude-code)
Merging pull request #199 publishes v1.9.0 through .github/workflows/release.yml.
marco-commercelayer
self-requested a review
November 6, 2026 10:17
marco-commercelayer
approved these changes
Nov 6, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The "Next release" milestone: every pull request merged into
milestone/nextships with this release. Version and notes are written bybin/release-prepare, run onmilestone/next.🤖 Generated with Claude Code
rail0 CLI v1.9.0
Added
Fixed
Full diff: v1.8.2...v1.9.0
Version: minor, computed from the pull requests merged since v1.8.2 (a breaking change → major,
feat→ minor, anything else → patch). Decided by:Merging this pull request also releases v1.9.0: its changes and the version bump
ship together, under the one approval. On the push to
main,.github/workflows/release.ymlre-runs CI on the merge commit, creates the tag, and GoReleaser builds the binaries and publishes the GitHub release, andposts the release to Slack.
The release notes are the text between the
release-notesmarkers above, read from thispull request when it merges: edit them here, before merging.
Opened by
bin/release-prepare.