Skip to content

docs(dev): author dev/ guides, guidelines, knowledge, and seed ADRs - #358

Merged
BeArchiTek merged 5 commits into
developfrom
chore/dev-docs-alignment
Jul 3, 2026
Merged

docs(dev): author dev/ guides, guidelines, knowledge, and seed ADRs#358
BeArchiTek merged 5 commits into
developfrom
chore/dev-docs-alignment

Conversation

@BeArchiTek

@BeArchiTek BeArchiTek commented Jun 29, 2026

Copy link
Copy Markdown
Contributor

Author dev/ developer docs (guides, guidelines, knowledge, ADRs)

Fills out the dev/ reference layer to match the styrmin / infrahub-mcp conventions. All content is freshly authored about this collection and grounded in the real plugin code — no peer domain content copied.

Added — guidelines

  • markdown.md — kebab-case naming + the real markdown tooling (.markdownlint.yaml, Vale, yamllint).
  • module-docstrings.mdDOCUMENTATION / EXAMPLES / RETURN rules, doc_fragments, the invoke generate-doc pipeline.
  • Fixed a stale .markdownlint.yml.markdownlint.yaml reference in the existing python.md + documentation.md.

Added — guides

  • adding-a-doc-fragment.mdModuleDocFragment + extends_documentation_fragment.
  • debugging-sanity-failures.md — reproducing/fixing ansible-test sanity failures (boilerplate, HAS_INFRAHUBCLIENT, docstring/arg-spec mismatch).
  • releasing-the-collection.mdinvoke galaxy-build, the automated develop→stable version bump + workflow-publish.yml Galaxy publish + release-drafter changelog (no invented commands).

Added — knowledge

  • inventory-and-lookup.md — deep-dive on the inventory + lookup plugins.
  • processors-and-arg-spec.mdINFRAHUB_ARG_SPEC + the deepcopy() extension pattern and the InfrahubBaseProcessorInfrahubNodesProcessor/InfrahubQueryProcessor hierarchy.

Added — ADRs (MADR, backfilling real decisions)

  • 0001-two-plugin-patterns, 0002-sdk-abstraction-wrapper, 0003-sync-only-sdk, 0004-docker-based-testing, 0005-doc-generation-pipeline.

Other

  • dev/constitution.md — pointer to .specify/memory/constitution.md (no body; avoids drift).
  • dev/README.md — rewritten to the peer Quick-Navigation table, indexing every real file incl. ../.agents/commands/.

Final dev/ layer: 5 knowledge docs · 6 guidelines · 5 guides · 5 ADRs · README + constitution pointer.

Verification

  • Every technical claim in the knowledge doc was verified against plugins/inventory/inventory.py, plugins/lookup/lookup.py, and infrahub_utils.py — all cited classes/options/methods exist (InventoryModule, Cacheable, _mark_trusted, prefetch_relationships, InfrahubQueryProcessor, InfrahubBaseProcessor, …).
  • All dev/ links resolve; ADRs follow dev/adr/README.md's MADR format + numbering; filenames kebab-case; markdownlint reports 0 errors.
  • Agentic-structure checker: dev-reference-layout passes; 0 errors.

Two commits, dev/ only. Pure documentation — no code, schema, or behavior changes.

🤖 Generated with Claude Code

Add a dev/constitution.md pointer; a markdown guideline and a
module-docstrings guideline; guides for adding a doc fragment and
debugging ansible-test sanity failures; a knowledge deep-dive on the
inventory + lookup plugins; and three seed ADRs (two-plugin-patterns,
sdk-abstraction-wrapper, sync-only-sdk). Rewrite dev/README.md to the
peer Quick-Navigation table format. Aligns dev/ with the styrmin /
infrahub-mcp conventions.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Jun 29, 2026

Copy link
Copy Markdown

Deploying infrahub-ansible with  Cloudflare Pages  Cloudflare Pages

Latest commit: cce3b33
Status: ✅  Deploy successful!
Preview URL: https://73c77e32.infrahub-ansible.pages.dev
Branch Preview URL: https://chore-dev-docs-alignment.infrahub-ansible.pages.dev

View logs

@BeArchiTek
BeArchiTek requested a review from a team as a code owner June 29, 2026 19:58
@BeArchiTek BeArchiTek added ci/skip-changelog This will not be added to release notes agentic-drift Repo agentic-structure drift, managed by detecting-repo-drift labels Jun 29, 2026

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 issues found across 10 files

Prompt for AI agents (unresolved issues)

Check if these issues are valid — if so, understand the root cause of each and fix them. If appropriate, use sub-agents to investigate and fix each issue separately.


<file name="dev/guides/adding-a-doc-fragment.md">

<violation number="1" location="dev/guides/adding-a-doc-fragment.md:49">
P2: Step 2's FQCN example omits the filename (`fragments`). All fragments live in `plugins/doc_fragments/fragments.py` as class attributes, so the collection-qualified reference must include the file name before the attribute.</violation>
</file>

<file name="dev/adr/0003-sync-only-sdk.md">

<violation number="1" location="dev/adr/0003-sync-only-sdk.md:23">
P2: Dependency version range in ADR (`>=1.5, <2.0`) does not match the actual project requirement (`>=1.19.0,<2.0`). This will mislead contributors about compatibility.</violation>
</file>

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread dev/guides/adding-a-doc-fragment.md
Comment thread dev/adr/0003-sync-only-sdk.md Outdated
Round out the dev/ reference: a releasing-the-collection guide, a
processors-and-arg-spec knowledge doc, and ADRs 0004 (docker-based
testing) + 0005 (doc-generation pipeline). Fix stale .markdownlint.yml
references to .markdownlint.yaml and refresh the dev/README.md nav.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@BeArchiTek
BeArchiTek force-pushed the chore/dev-docs-alignment branch from f4e8516 to e9854d9 Compare June 29, 2026 22:46
…titution.md

The constitution wiring is flipped to match the peer repos (infrahub,
infrahub-mcp, styrmin): dev/constitution.md holds the real body and
.specify/memory/constitution.md symlinks to it — both provided by #356.
Remove the now-redundant pointer stub here (avoids a merge conflict with
#356's real dev/constitution.md) and fix the dev/README description.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2 issues found across 2 files (changes from recent commits).

Tip: Review your code locally with the cubic CLI to iterate faster.

Re-trigger cubic

Comment thread dev/README.md Outdated
Benoit Kohler and others added 2 commits July 1, 2026 15:46
Revert 7cc5a94, which deleted dev/constitution.md and rewrote the
dev/README description to claim the constitution body lives in
dev/constitution.md with .specify/memory/constitution.md symlinking to
it. That commit deferred both to PR #356, but #356 touches neither file
(.specify/memory/constitution.md is a real 5.8K file, not a symlink), so
the branch was left internally inconsistent: a deleted file that the
README still linked to, and a symlink that does not exist.

Restore dev/constitution.md as the pointer stub and revert the README to
describe it as a pointer. All dev/ links resolve again and the diff now
matches PR #358's description.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…roject

Address two Cubic review findings on PR #358:

- adding-a-doc-fragment.md: the extends_documentation_fragment example
  dropped the file basename. Fragments are attributes of ModuleDocFragment
  in plugins/doc_fragments/fragments.py, so the FQCN is
  opsmill.infrahub.fragments.<ATTRIBUTE>, not opsmill.infrahub.my_fragment.
- 0003-sync-only-sdk.md: the SDK range said >=1.5,<2.0 but pyproject.toml
  pins infrahub-sdk[all]>=1.19.0,<2.0.

Fix the same stale range where it also appeared in AGENTS.md and
infrahub-sdk-usage.md (the latter also showed Poetry-style syntax under a
"# pyproject.toml" comment; corrected to the real PEP 621 dependencies array).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@BeArchiTek
BeArchiTek merged commit 3f2ec08 into develop Jul 3, 2026
24 checks passed
@BeArchiTek
BeArchiTek deleted the chore/dev-docs-alignment branch July 3, 2026 08:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

agentic-drift Repo agentic-structure drift, managed by detecting-repo-drift ci/skip-changelog This will not be added to release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant