Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions AGENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ Key rules:
✅ **Always**

- Run `uv run invoke format lint-code` before committing Python code
- Run `uv run invoke docs-generate` after creating, modifying or deleting CLI commands, SDK config, or Python docstrings
Copy link

Choose a reason for hiding this comment

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

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

# Search for invoke task definitions related to docs generation
fd -e py "tasks" | head -20

Repository: opsmill/infrahub-sdk-python

Length of output: 104


🏁 Script executed:

# Look for docs-generate, docs_generate, and old command definitions
rg "docs.generate|docs_generate|generate.sdk|generate_sdk|generate.infrahubctl|generate_infrahubctl" --type=py -B 2 -A 5

Repository: opsmill/infrahub-sdk-python

Length of output: 6029


🏁 Script executed:

# Check docs/AGENTS.md for any references to these commands
fd "AGENTS" -e md -e mdx

Repository: opsmill/infrahub-sdk-python

Length of output: 175


🏁 Script executed:

# Check docs/AGENTS.md for references to old commands
cat -n docs/AGENTS.md | head -100

Repository: opsmill/infrahub-sdk-python

Length of output: 2792


🏁 Script executed:

# Also check the content of the root AGENTS.md file to see the context
sed -n '50,70p' AGENTS.md

Repository: opsmill/infrahub-sdk-python

Length of output: 702


Update docs/AGENTS.md to use docs-generate instead of legacy commands in the Never section.

The docs-generate task exists and properly covers all stated triggers (CLI commands, SDK config, and Python docstrings via API documentation). However, docs/AGENTS.md currently contradicts itself: line 13 references the unified uv run invoke docs-generate, but lines 69-70 still instruct contributors to regenerate using the old individual commands (uv run invoke generate-infrahubctl and uv run invoke generate-sdk).

Update the Never section to:

- Edit `docs/infrahubctl/*.mdx` directly (regenerate with `uv run invoke docs-generate`)
- Edit `docs/python-sdk/reference/config.mdx` directly (regenerate with `uv run invoke docs-generate`)
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In `@AGENTS.md` at line 57, The Never section still references legacy tasks; find
the entries that mention `uv run invoke generate-infrahubctl` and `uv run invoke
generate-sdk` (the lines that tell contributors how to regenerate docs) and
replace them with unified guidance to regenerate using `uv run invoke
docs-generate`, e.g., update the two bullets to read that
`docs/infrahubctl/*.mdx` and `docs/python-sdk/reference/config.mdx` should be
edited directly and regenerated with `uv run invoke docs-generate` instead of
the old individual commands.

- Run markdownlint before committing markdown changes
- Follow async/sync dual pattern for new features
- Use type hints on all function signatures
Expand Down