Fix the linting in the Infrahub documentation IFC-2265#8367
Fix the linting in the Infrahub documentation IFC-2265#8367
Conversation
|
No actionable comments were generated in the recent review. 🎉 WalkthroughThis pull request adds new replacement rules to Vale style configs to normalize capitalization for terms such as Artifact(s), Generator(s), Profile(s), Resource Manager(s), Transformation(s), and Transforms. It also applies consistent capitalization and minor wording edits across many documentation files (guides, topics, tutorials, and release notes). Changes are editorial only—formatting, terminology, and style updates—with no modifications to public API signatures or runtime behavior. 🚥 Pre-merge checks | ✅ 3 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…ctions IFC-2265 Use literal space instead of \s in Artifact lookbehind to prevent cross-line matching. Replace vale-off sections in style guide with backticks on incorrect examples, which Vale naturally ignores.
There was a problem hiding this comment.
Actionable comments posted: 17
🤖 Fix all issues with AI agents
Before applying any fix, first verify the finding against the current code and
decide whether a code change is actually needed. If the finding is not valid or
no change is required, do not modify code for that item and briefly explain why
it was skipped.
In @.vale/styles/Infrahub/branded-terms-case-swap.yml:
- Around line 40-41: The plural mapping currently forces "Resource Managers" to
the singular by the rule (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource
Manager; change that mapping so the RHS is the correct plural "Resource
Managers" (e.g., ...: Resource Managers) while keeping the singular mapping
(?<![\.|/|#])(?:resource [Mm]anager|Resource manager)[\.!]?\s: Resource Manager
intact, so legitimate plural usages are not rewritten to singular.
In `@docs/docs/getting-started/concepts.mdx`:
- Line 96: Update the ReferenceLink title to capitalize the Infrahub term:
change the ReferenceLink component in concepts.mdx (the <ReferenceLink
title="Learn more about generator" ... /> instance) so the title reads "Learn
more about Generator" to match the project's capitalization guidelines for
"Generator".
In `@docs/docs/guides/configuration-changes.mdx`:
- Line 61: Update the three headings so the text after each colon uses sentence
case: change "Option A: use a .env file (recommended)" to "Option A: Use a .env
file (recommended)" and similarly fix the other two headings referenced ("Option
B:" and "Option C:") so the first letter after the colon is capitalized per
sentence-case guidelines; locate and edit the exact heading strings in
docs/docs/guides/configuration-changes.mdx.
In `@docs/docs/guides/database-backup.mdx`:
- Around line 65-67: The sentence starting "artifact storage backup is planned
for future versions and must currently be handled separately." should be
rewritten to use sentence-initial capitalization and active voice; change it to
something like "We plan to add artifact storage backup in a future release;
handle artifact storage backups separately for now." Ensure you still follow the
rule of not capitalizing "artifact" mid-sentence (only capitalize at sentence
start) and replace the passive phrasing ("is planned", "must be handled") with
an active construction in the same sentence.
In `@docs/docs/guides/generator.mdx`:
- Around line 39-40: The two adjacent list items
"[infrahubctl]($(base_url)infrahubctl/infrahubctl) installed and configured
locally" and "The repository cloned locally where you'll develop the Generator"
repeat the word "locally"; edit the second bullet ("The repository cloned
locally where you'll develop the Generator") to remove or reposition "locally"
(e.g., "The repository cloned where you'll develop the Generator" or "A clone of
the repository where you'll develop the Generator") so the phrasing no longer
repeats while preserving meaning.
In `@docs/docs/guides/profiles.mdx`:
- Line 153: Update the inconsistent step headings to sentence-case: change the
headings "Step 2: Assigning multiple Profiles to an interface" and "Step 3:
Validating Profile inheritance with multiple Profiles" to "Step 2: assigning
multiple Profiles to an interface" and "Step 3: validating Profile inheritance
with multiple Profiles" respectively so they match the other headings (e.g.,
"Step 1: creating a Profile"); ensure all "Step N:" headings in
docs/guides/profiles.mdx follow the same sentence-case pattern.
In `@docs/docs/guides/resource-manager.mdx`:
- Line 1086: Fix the subject-verb agreement in the sentence "Resource Manager
allocate resources across all branches to prevent conflicts." by changing
"allocate" to "allocates" so it reads "Resource Manager allocates resources
across all branches to prevent conflicts."; update any identical occurrences
(e.g., the similar singular-subject issue noted earlier) to maintain
consistency.
- Line 9: The sentence contains a subject-verb agreement error: replace the
phrase "Resource Manager eliminate" with the correct singular verb form
"Resource Manager eliminates" so the sentence reads "Resource Manager eliminates
manual IP address and number assignment..." (locate the exact phrase "Resource
Manager eliminate manual IP address and number assignment" in the docs/guides
text and update it).
- Line 761: Update the sentence that begins "Another way we can use Resource
Manager..." to include the definite article: change "use Resource Manager" to
"use the Resource Manager" so it reads "Another way we can use the Resource
Manager is in situations where we create a node..." to correct the missing
article.
In `@docs/docs/release-notes/infrahub/release-0_13.mdx`:
- Line 94: Update the phrase "Transformations & Artifacts" so that "Artifacts"
is lowercase per terminology guidelines: change "Transformations & Artifacts" to
"Transformations & artifacts" (keep "Transformations" capitalized and
"Generator" as-is) in the sentence that begins "Similar to the Transformations &
Artifacts, Generator will be automatically executed…" to match the rule that
Infrahub-specific terms like Generator and Transformation are capitalized but
artifact(s) remain lowercase.
- Line 96: Update the sentence that reads "The Generator itself is a Python
class that is based on the `InfrahubGenerator` class from the SDK. Just like
Transformations and checks, the Generators are user defined." to use the
hyphenated compound adjective "user-defined" (so it reads "...the Generators are
user-defined.") and ensure consistency for similar occurrences of "user defined"
near mentions of Generator and InfrahubGenerator in this file.
In `@docs/docs/release-notes/infrahub/release-1_1_6.mdx`:
- Line 40: Change the heading "**Supported artifact Content Types**:" to
sentence case by updating it to "**Supported artifact content types**:" in the
release notes (unless "Content Types" is a deliberate domain-specific term), and
ensure any other occurrences in this document follow sentence case for
consistency with documentation guidelines.
In `@docs/docs/release-notes/infrahub/release-1_2_8.mdx`:
- Line 35: Fix the typos in the release note line mentioning
"convert_query_response": change "the same was as" to "the same way as" and
hyphenate "non-default branch". Update the sentence that contains
"convert_query_response" in release-1_2_8.mdx so it reads: Added support for
"convert_query_response" for Python Transformations. The feature works the same
way as with Generators. Note any non-default branch will need to be rebased
after this upgrade.
In `@docs/docs/release-notes/infrahub/release-1_5_0.mdx`:
- Line 268: Update the release note sentence to use the correct noun and
hyphenation: replace "transform based webhooks" with "Transformation-based
webhooks" and change "without an attached transform" to "without an attached
Transformation" so the line reads consistently (keep the rest of the sentence
and the PR/issue reference unchanged).
In `@docs/docs/topics/artifact.mdx`:
- Line 35: Update the sentence in the docs where it reads "artifact related
queries" to use a hyphenated compound adjective: change it to "artifact-related
queries" so the phrase correctly uses a compound modifier before "queries."
In `@docs/docs/topics/database-backup.mdx`:
- Line 28: The heading "**artifact storage**" uses all-lowercase but should
follow sentence case for headings; change that heading text to "Artifact
storage" so only the first word is capitalized while leaving "artifact(s)"
uncapitalized elsewhere; update the heading string in the
docs/topics/database-backup.mdx file where the markdown heading text "**artifact
storage**" appears.
In `@docs/docs/topics/developer-guide.mdx`:
- Around line 28-33: Remove the duplicated paragraph so the description appears
only once: delete the block that repeats "This uses [copier]... customize your
repository (such as including example generators, Transformations, and
scripts)..." and keep the corrected version that uses the capitalized
terminology ("Generators" and "Transformations"); also update any remaining
lowercase "generators" to "Generators" and ensure Infrahub-specific terms follow
the capitalization guideline (e.g., Generator(s), Transformation(s), Profile(s),
Resource Manager) while leaving the "uv tool run" text unchanged.
In `@docs/docs/topics/generator.mdx`:
- Line 59: Fix the typo in the sentence snippet "In the second video we will
will look..." by removing the duplicated "will" so it reads "In the second video
we will look at how to plan a Generator..."; update the sentence in the
docs/topics/generator.mdx content that contains "we will will look" to the
corrected phrasing to ensure grammar and clarity.
In `@docs/docs/topics/object-conversion.mdx`:
- Line 11: The phrase "seamless Transformation process" in
docs/topics/object-conversion.mdx incorrectly capitalizes a generic term; change
it to "seamless transformation process" and audit nearby occurrences of
"Transformation" to ensure only Infrahub-specific feature mentions use
capitalization. Specifically, replace the capitalized phrase and confirm
capitalization rules are applied consistently with other Infrahub-specific terms
(Generator(s), Transformation(s), Profile(s), Resource Manager) so only feature
references remain capitalized.
In `@docs/docs/topics/resource-manager.mdx`:
- Line 23: Fix the grammar in the sentence that currently reads "This is due the
dynamic nature of using Resource Manager..." by changing "due the" to "due to
the" and add the article before Resource Manager so it reads "using a Resource
Manager"; update the sentence near the phrase "`allow_upsert=True`" accordingly
so it becomes "due to the dynamic nature of using a Resource Manager and the
idempotency of using the `allow_upsert=True`," preserving the mention of HFID.
In `@docs/docs/topics/schema-attr-kind-number-pool.mdx`:
- Line 15: The phrase "resource manager" in the sentence describing NumberPool
parameters should be capitalized to match project conventions; update the text
that reads "...for the `CoreNumberPool` resource manager." to use "Resource
Manager" (e.g., "...for the `CoreNumberPool` Resource Manager.") so it matches
other uses of Infrahub-specific terms like `NumberPool` and `CoreNumberPool`.
In `@docs/docs/topics/webhooks.mdx`:
- Line 33: The sentence "webhooks execute the transform by passing in the
webhook data" uses "transform" as a noun; update that phrase in
docs/docs/topics/webhooks.mdx to use the correct terminology "Transformation"
(e.g., change to "webhooks execute the Transformation by passing in the webhook
data") so the line reads consistently with the guideline and the earlier mention
of "Python Transformation".
🧹 Nitpick comments (5)
🤖 Fix all nitpicks with AI agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/getting-started/concepts.mdx`: - Line 96: Update the ReferenceLink title to capitalize the Infrahub term: change the ReferenceLink component in concepts.mdx (the <ReferenceLink title="Learn more about generator" ... /> instance) so the title reads "Learn more about Generator" to match the project's capitalization guidelines for "Generator". In `@docs/docs/guides/generator.mdx`: - Around line 39-40: The two adjacent list items "[infrahubctl]($(base_url)infrahubctl/infrahubctl) installed and configured locally" and "The repository cloned locally where you'll develop the Generator" repeat the word "locally"; edit the second bullet ("The repository cloned locally where you'll develop the Generator") to remove or reposition "locally" (e.g., "The repository cloned where you'll develop the Generator" or "A clone of the repository where you'll develop the Generator") so the phrasing no longer repeats while preserving meaning. In `@docs/docs/release-notes/infrahub/release-0_13.mdx`: - Line 96: Update the sentence that reads "The Generator itself is a Python class that is based on the `InfrahubGenerator` class from the SDK. Just like Transformations and checks, the Generators are user defined." to use the hyphenated compound adjective "user-defined" (so it reads "...the Generators are user-defined.") and ensure consistency for similar occurrences of "user defined" near mentions of Generator and InfrahubGenerator in this file. In `@docs/docs/release-notes/infrahub/release-1_1_6.mdx`: - Line 40: Change the heading "**Supported artifact Content Types**:" to sentence case by updating it to "**Supported artifact content types**:" in the release notes (unless "Content Types" is a deliberate domain-specific term), and ensure any other occurrences in this document follow sentence case for consistency with documentation guidelines. In `@docs/docs/topics/schema-attr-kind-number-pool.mdx`: - Line 15: The phrase "resource manager" in the sentence describing NumberPool parameters should be capitalized to match project conventions; update the text that reads "...for the `CoreNumberPool` resource manager." to use "Resource Manager" (e.g., "...for the `CoreNumberPool` Resource Manager.") so it matches other uses of Infrahub-specific terms like `NumberPool` and `CoreNumberPool`.docs/docs/release-notes/infrahub/release-1_1_6.mdx (1)
40-40: Consider using sentence case for "content types".The text uses "Content Types" in title case. Per the documentation guidelines, sentence case should be used for headings and labels. Unless "Content Types" is a specific technical term in the Infrahub domain, consider changing it to "content types".
📝 Suggested refinement
-**Supported artifact Content Types**: +**Supported artifact content types**:🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/release-notes/infrahub/release-1_1_6.mdx` at line 40, Change the heading "**Supported artifact Content Types**:" to sentence case by updating it to "**Supported artifact content types**:" in the release notes (unless "Content Types" is a deliberate domain-specific term), and ensure any other occurrences in this document follow sentence case for consistency with documentation guidelines.docs/docs/release-notes/infrahub/release-0_13.mdx (1)
96-96: Minor grammar: "user defined" → "user-defined".When used as a compound adjective before a noun (or as a predicate adjective in this pattern), a hyphen improves clarity.
Proposed fix
-The Generator itself is a Python class that is based on the `InfrahubGenerator` class from the SDK. Just like Transformations and checks, the Generators are user defined. +The Generator itself is a Python class that is based on the `InfrahubGenerator` class from the SDK. Just like Transformations and checks, the Generators are user-defined.🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/release-notes/infrahub/release-0_13.mdx` at line 96, Update the sentence that reads "The Generator itself is a Python class that is based on the `InfrahubGenerator` class from the SDK. Just like Transformations and checks, the Generators are user defined." to use the hyphenated compound adjective "user-defined" (so it reads "...the Generators are user-defined.") and ensure consistency for similar occurrences of "user defined" near mentions of Generator and InfrahubGenerator in this file.docs/docs/topics/schema-attr-kind-number-pool.mdx (1)
15-15: Pre-existing: "resource manager" on line 15 should also be capitalized.Line 15 still has lowercase "resource manager" while the rest of the file has been updated. Consider fixing for consistency.
-When defining a `NumberPool` attribute, you'll have to define extra `parameters` on the attribute to define the `start_range` and `end_range` for the `CoreNumberPool` resource manager. +When defining a `NumberPool` attribute, you'll have to define extra `parameters` on the attribute to define the `start_range` and `end_range` for the `CoreNumberPool` Resource Manager.As per coding guidelines: "Capitalize Infrahub-specific terms: Resource Manager."
🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/topics/schema-attr-kind-number-pool.mdx` at line 15, The phrase "resource manager" in the sentence describing NumberPool parameters should be capitalized to match project conventions; update the text that reads "...for the `CoreNumberPool` resource manager." to use "Resource Manager" (e.g., "...for the `CoreNumberPool` Resource Manager.") so it matches other uses of Infrahub-specific terms like `NumberPool` and `CoreNumberPool`.docs/docs/guides/generator.mdx (1)
39-40: Minor: repeated "locally" across adjacent list items.Per the static analysis hint, "locally" appears in both line 39 and line 40. Consider rewording line 40 to avoid the repetition.
Suggested rewording
-- The repository cloned locally where you'll develop the Generator +- A local clone of the repository where you'll develop the Generator🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/guides/generator.mdx` around lines 39 - 40, The two adjacent list items "[infrahubctl]($(base_url)infrahubctl/infrahubctl) installed and configured locally" and "The repository cloned locally where you'll develop the Generator" repeat the word "locally"; edit the second bullet ("The repository cloned locally where you'll develop the Generator") to remove or reposition "locally" (e.g., "The repository cloned where you'll develop the Generator" or "A clone of the repository where you'll develop the Generator") so the phrasing no longer repeats while preserving meaning.docs/docs/getting-started/concepts.mdx (1)
96-96: Pre-existing: "generator" should be capitalized in the link title.Line 96 wasn't changed in this PR, but since the surrounding lines were updated for Generator capitalization, this reference link title should also be updated for consistency.
-<ReferenceLink title="Learn more about generator" url="../topics/generator" /> +<ReferenceLink title="Learn more about Generator" url="../topics/generator" />As per coding guidelines: "Capitalize Infrahub-specific terms: Generator(s)."
🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and decide whether a code change is actually needed. If the finding is not valid or no change is required, do not modify code for that item and briefly explain why it was skipped. In `@docs/docs/getting-started/concepts.mdx` at line 96, Update the ReferenceLink title to capitalize the Infrahub term: change the ReferenceLink component in concepts.mdx (the <ReferenceLink title="Learn more about generator" ... /> instance) so the title reads "Learn more about Generator" to match the project's capitalization guidelines for "Generator".
| (?<![\.|/|#])(?:resource [Mm]anager|Resource manager)[\.!]?\s: Resource Manager | ||
| (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Manager |
There was a problem hiding this comment.
Plural "Resource Managers" is forced to singular "Resource Manager".
Line 41 maps both Resource Managers and resource managers to the singular Resource Manager. There are legitimate plural uses (e.g., "Infrahub supports multiple Resource Managers"), where forcing singular would produce incorrect grammar. Consider mapping the plural form to Resource Managers instead.
Proposed fix
- (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Manager
+ (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Managers📝 Committable suggestion
‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.
| (?<![\.|/|#])(?:resource [Mm]anager|Resource manager)[\.!]?\s: Resource Manager | |
| (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Manager | |
| (?<![\.|/|#])(?:resource [Mm]anager|Resource manager)[\.!]?\s: Resource Manager | |
| (?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Managers |
🤖 Prompt for AI Agents
Before applying any fix, first verify the finding against the current code and
decide whether a code change is actually needed. If the finding is not valid or
no change is required, do not modify code for that item and briefly explain why
it was skipped.
In @.vale/styles/Infrahub/branded-terms-case-swap.yml around lines 40 - 41, The
plural mapping currently forces "Resource Managers" to the singular by the rule
(?<![\.|/|#])[Rr]esource [Mm]anagers[\.!]?\s: Resource Manager; change that
mapping so the RHS is the correct plural "Resource Managers" (e.g., ...:
Resource Managers) while keeping the singular mapping (?<![\.|/|#])(?:resource
[Mm]anager|Resource manager)[\.!]?\s: Resource Manager intact, so legitimate
plural usages are not rewritten to singular.
- Fix sentence-case headings after colons in configuration-changes.mdx - Rewrite passive voice and fix capitalization in database-backup.mdx - Fix step heading consistency in profiles.mdx - Fix subject-verb agreement with singular Resource Manager - Lowercase "artifacts" mid-sentence in release notes - Fix typos: "was" -> "way", "will will" -> "will", "due the" -> "due to the" - Hyphenate "non-default" - Use "Transformation" noun form instead of "transform" in webhooks and release notes - Lowercase generic "transformation" in object-conversion.mdx - Remove duplicated paragraph in developer-guide.mdx
There was a problem hiding this comment.
Actionable comments posted: 4
🤖 Fix all issues with AI agents
Verify each finding against the current code and only fix it if needed.
In `@docs/docs/release-notes/infrahub/release-0_13.mdx`:
- Line 96: The phrase "user defined" in the sentence referencing the Generator
and InfrahubGenerator should be hyphenated as a compound adjective; update the
sentence containing "The Generator itself is a Python class that is based on the
`InfrahubGenerator` class from the SDK. Just like Transformations and checks,
the Generators are user defined." to use "user-defined" instead of "user
defined" so it reads "...the Generators are user-defined."
In `@docs/docs/release-notes/infrahub/release-1_5_0.mdx`:
- Line 146: Fix the malformed Markdown by replacing the stray admonition and
mismatched asterisks in the line containing '⚠ !!! ***WARNING** this is a
breaking change...' — remove the redundant '!!!', correct the emphasis token
'***WARNING**' to a valid form like '⚠️ **WARNING:**' (or '⚠️ ***WARNING***' if
you need bold+italic), and ensure a colon or dash follows the label so the rest
of the sentence renders correctly in MDX.
In `@docs/docs/topics/generator.mdx`:
- Line 31: Update the text where the phrase "user defined" describes Generators
to use the compound adjective form "user-defined"; specifically modify the
sentence referencing the Generator class (based on InfrahubGenerator) and the
comparison to Transformations and checks so it reads "user-defined" instead of
"user defined" to correct the hyphenation.
- Line 25: The sentence that ends with the link [SDK tracking
feature]($(base_url)python-sdk/topics/tracking) is missing a final period;
update the line in docs/topics/generator.mdx that starts with "Running a
Generator definition will create new nodes..." to add a trailing period after
the link so the sentence ends with "...tracking)."
- Line 15: Update the heading text in docs/docs/topics/generator.mdx by
replacing the string "## High level design" with the hyphenated form "##
High-level design" so the compound adjective is correct; locate the markdown
heading "## High level design" and change it accordingly.
🧹 Nitpick comments (1)
🤖 Fix all nitpicks with AI agents
Verify each finding against the current code and only fix it if needed. In `@docs/docs/topics/generator.mdx`: - Line 15: Update the heading text in docs/docs/topics/generator.mdx by replacing the string "## High level design" with the hyphenated form "## High-level design" so the compound adjective is correct; locate the markdown heading "## High level design" and change it accordingly.docs/docs/topics/generator.mdx (1)
15-15: Nit: hyphenate compound adjective in heading."High level design" → "High-level design" since "high-level" is a compound modifier.
Proposed fix
-## High level design +## High-level design🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed. In `@docs/docs/topics/generator.mdx` at line 15, Update the heading text in docs/docs/topics/generator.mdx by replacing the string "## High level design" with the hyphenated form "## High-level design" so the compound adjective is correct; locate the markdown heading "## High level design" and change it accordingly.
Why
Problem statement: since #8257 new rules has been added to documentation lint tool vale, without triggering the CI documentation lint check. The CI check has been fixed in this PR #8365
Goal: Fix the documentation according to the new rules, and adapt them if necessary.
Closes IFC-2265
What changed
<!-- Vale off -->" sections have been added to the documentation.How to review
<!-- Vale off -->" sectionsHow to test
vale --config=./.vale.ini $(find ./docs -type f \( -name "*.mdx" -o -name "*.md" \) -not -path "./docs/node_modules/*")Summary by CodeRabbit
Documentation
Style