Iteration 1 validation surfaced two bugs in runwhen-local 0.11.0 that
prevent cluster-scoped CRDs (like Crossplane GCP Buckets) from being
discovered:
1. NameError: KubernetesResourceTypeSpec is not defined
(kubeapi.py:1125 references a symbol never imported)
2. list_namespaced_custom_object returns 404 for cluster-scoped CRDs
(the loop always calls the namespaced API path)
Added docs/08-current-limitations.md with symptoms, causes, and
one-line / small-patch proposed fixes for both. Updated the iteration
checklist in docs/07 to reflect this and added the missing docs entry
to the top-level README.
Co-authored-by: Cursor <cursoragent@cursor.com>
simple-private-codecollection
An educational, generation-rule-only RunWhen CodeCollection. It ships no
Robot Framework code of its own — instead it teaches how a private repository
can define discovery rules and SLX templates that reuse a generic
runtime already loaded by the RunWhen runner (in this case
k8s-kubectl-cmd
from rw-generic-codecollection).
What it demonstrates
- How workspace-builder discovers a Kubernetes Custom Resource (a
Crossplane
Bucketfrom the Upbound GCP provider) via a generation rule. - How the resulting SLX points its
codeBundle.repoUrlat a different code collection where the runtime actually lives. - How to compute a fractional SLI (0.0–1.0) from
.status.conditions[]withjq, and how to emit a detailed TaskSet with per-condition issues viaRW.DynamicIssues.
Layout
codebundles/
gcp-bucket-crossplane-health/ # rules + templates only, no *.robot
.runwhen/
generation-rules/gcp-bucket-crossplane-health.yaml
templates/
gcp-bucket-crossplane-health-slx.yaml
gcp-bucket-crossplane-health-sli.yaml
gcp-bucket-crossplane-health-taskset.yaml
docs/
01-overview.md
02-generation-rules-only-pattern.md
03-crossplane-crd-discovery.md
04-generation-rule-walkthrough.md
05-slx-and-templates.md
06-runner-integration.md
07-validate-and-observe.md
08-current-limitations.md
images/ # screenshots referenced from the chapters
Start here
Open docs/01-overview.md and read the chapters in
order. Each chapter has a short "What you'll do" preamble, an inline diagram
or code snippet, and screenshot placeholders that we fill in as we iterate.
Target environment
This training example is wired for the RunWhen airgap environment (in-cluster
workspace-builder in runwhen-env-airgap-runner, Gitea at
gitea.airgap.shared.runwhen.com). The generation rule targets real Crossplane
Bucket resources already present in that cluster (see
llm-storage.yaml
and similar). The pattern applies to any RunWhen environment; only the
repoUrl in the templates needs to change.