Repository navigation
CI rehearsal only (do not merge) - #18
michael-moffett wants to merge 8 commits into
Conversation
Add `Config::fromEnv(string $prefix = 'PAY_KIT_'): Config` to the PHP SDK (the PHP item "Add `Config::fromEnv()`"). `docs/paykit-interface.md:85-95` says every SDK must have a `configure_from_env` entry point, and maps it to `Config::fromEnv()` for PHP. Python (`configure_from`) and TypeScript (`configureFromEnv`) have one. PHP has none.
|
| { | ||
| $env = static function (string $name) use ($prefix): ?string { | ||
| $raw = getenv($prefix . $name); | ||
| return $raw === false || trim($raw) === '' ? null : trim($raw); |
| protected function tearDown(): void | ||
| { | ||
| foreach (self::ENV_NAMES as $name) { | ||
| putenv("PAY_KIT_{$name}"); | ||
| putenv("ACME_{$name}"); | ||
| } |
There was a problem hiding this comment.
Tests clear existing configuration If the shell already has a production configuration variable set, these tests do not isolate themselves from it and
tearDown() removes it instead of restoring it. For example, an existing PAY_KIT_NETWORK=solana_mainnet makes the defaults test throw because it selects mainnet with a demo signer; after cleanup, subsequent tests see a different environment.
… Config from PAY_KIT_* env vars
… env vars; diff kept unchanged per the director's 2026-10-07 ruling on the two Greptile findings
| target("swift", "client", ["swift-x402-upto"], "swift-x402-upto-client", "SwiftX402UptoClient"), | ||
| ...["kotlin", "kotlin-x402", "kotlin-x402-upto"].map((id) => | ||
| target("kotlin", "client", [id], `${id}-client`, `mpp-${id}-harness-client`)), | ||
| target("swift", "conformance", ["swift"], "../swift", "mpp-conformance"), |
There was a problem hiding this comment.
Swift conformance build fails The Swift conformance target builds from
swift/, but its Package.swift is at the repository root. The macOS artifact build therefore cannot find the package manifest and fails before the Swift harness legs can run.
| target("swift", "conformance", ["swift"], "../swift", "mpp-conformance"), | |
| target("swift", "conformance", ["swift"], "..", "mpp-conformance"), |
| } | ||
| needsConfirmation = replayClaim !== 'retry'; | ||
| // Retain pending state if the RPC accepted the send but lost its response. | ||
| await broadcastTransaction(rpcUrl, txToSend); |
There was a problem hiding this comment.
Failed sends strand payments If
sendTransaction fails before accepting a pull-mode payment, the replay reservation remains pending for 21 minutes. A retry of the same signed payment is rejected as already in progress; after the lease expires, recovery only checks for confirmation and never broadcasts it. A transient send failure can therefore leave a valid payment unable to complete.
…_KIT_* env vars; diff kept unchanged per the director's 2026-10-07 ruling on the two Greptile findings
Fork CI only. Do not merge.