Skip to content

examples/languages: price-go, a WebAssembly action built from Go - #280

Merged
erhangundogan merged 3 commits into
mainfrom
example-wasm-price
Nov 30, 2026
Merged

erhangundogan merged 3 commits into
mainfrom
example-wasm-price

Conversation

@erhangundogan

Copy link
Copy Markdown
Contributor

Adds price-go to examples/languages: python/price in Go, built from src/price-go/ with itero ws build, run by the workflow price-go on price.requested. The actions guide points to it.

Tested for real: built and run through ws daemon --once on macOS and on Linux (Docker, Debian 13, arm64), three orders each, the same totals and tax as python/price.

python/price in Go, its source in src/price-go/, built into
actions/price-go with `itero ws build` (the built module is not
committed: like an example's npm install, it is built once). The
workflow price-go runs it on price.requested; it prices an order as
python/price does (120 gives a total of 144 and a tax of 24).

The actions guide points to it from its WebAssembly section.
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 30, 2026 •

Copy link
Copy Markdown

🚀 Deploying Preview to Cloudflare 🚀

Preview URL: https://example-wasm-price-itero-doc.erhan-gundogan.workers.dev (commit 04cbbd0)

This URL reflects your latest Preview deployment

Preview Deployments by commit

Status Deployment URL Commit Updated (UTC) See this deployment's details
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://72f32ebb-itero-doc.erhan-gundogan.workers.dev 04cbbd0 2026-11-30T11:15:01.453Z Visit the dashboard ↗
  • Build: Success ✅
  • Deployment: Success ✅

View logs ↗
https://54a4125b-itero-doc.erhan-gundogan.workers.dev 7ae9e33 2026-11-30T10:26:36.235Z Visit the dashboard ↗

every_example_checks runs `itero ws check` on every example, and
languages' price-go action exists only once `itero ws build` has built it
from src/price-go/ (the module is not committed). The test now builds an
example that has a src/ folder first, as its README says, so a real Go
build runs with the tests. The tests need Go: `make test-linux` installs
it in its image, and CONTRIBUTING says so.
The examples test builds the languages example's WebAssembly action
with Go. Ubuntu's runner has go on its PATH; macOS's does not, and the
test failed there with "needs go". actions/setup-go installs the
current stable Go on macOS only.
@erhangundogan
erhangundogan merged commit 91c8465 into main Nov 30, 2026
8 checks passed
@erhangundogan
erhangundogan deleted the example-wasm-price branch November 30, 2026 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant