Skip to content

Conversation

@daniel-falk
Copy link
Contributor

@daniel-falk daniel-falk commented Aug 3, 2025

This PR adds a CICD job to test the formatting of common files like JSON, YML, md, etc. It also adds review instructions for @coderabbitai.

Summary by CodeRabbit

  • Chores
    • Added a configuration file to define repository-specific review instructions and enable automated AI reviews.
    • Introduced a GitHub Actions workflow to automatically check code formatting with Prettier on pushes and pull requests, and provide feedback if formatting issues are found.
  • Documentation
    • Improved README formatting with enhanced spacing for better readability.

@coderabbitai
Copy link

coderabbitai bot commented Aug 3, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

This change adds a new .coderabbit.yaml configuration file for AI review instructions and profiles, a GitHub Actions workflow .github/workflows/prettier.yml to enforce Prettier formatting checks on JSON, YAML, and Markdown files, and a minor whitespace update in the README.md file. No source code or exported entities are modified.

Changes

Cohort / File(s) Change Summary
AI Review Configuration
.coderabbit.yaml
Adds a configuration file specifying English (US) language, a "chill" review profile with poem generation disabled, detailed path-specific review instructions for dashboard deployments, markdown files, and all other files, and enables auto-review with incremental checks on all base branches.
Prettier Workflow
.github/workflows/prettier.yml
Adds a GitHub Actions workflow "Prettier Format Check" triggered on push and pull request events; it checks formatting compliance for JSON, YAML, and Markdown files using Prettier 3.6.0 and posts detailed PR comments with fix instructions if formatting issues are detected.
Documentation
README.md
Inserts a single blank line after the main heading; no content or structural changes made.

Sequence Diagram(s)

sequenceDiagram
    participant GitHub
    participant Workflow (Prettier)
    participant PR Author

    GitHub->>Workflow (Prettier): Trigger on push or PR event
    Workflow (Prettier)->>Workflow (Prettier): Checkout code, setup Node.js, run Prettier check
    alt Formatting issues detected & event is PR
        Workflow (Prettier)->>PR Author: Post comment with list of files and formatting instructions
    end
Loading

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

Possibly related PRs

  • fixedit-ai/client-doordash#285: Both PRs modify the .coderabbit.yaml configuration file, with the main PR adding a new detailed config and the retrieved PR fixing the casing of a profile name within the same file.
  • fixedit-ai/fapp#208: Both PRs add a .coderabbit.yaml configuration file defining AI review instructions and profiles, but with different path-specific details and review settings, indicating they are related changes to the same configuration aspect.

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro (Legacy)

📥 Commits

Reviewing files that changed from the base of the PR and between eadefcd and 0b961e7.

📒 Files selected for processing (3)
  • .coderabbit.yaml (1 hunks)
  • .github/workflows/prettier.yml (1 hunks)
  • README.md (1 hunks)

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 2

🧹 Nitpick comments (3)
.coderabbit.yaml (1)

14-16: Minor grammar tweak for clarity

Current: “dashboards are portable and does not check in specific host names”
Suggested: “dashboards are portable and do not check in specific host names”.

-        dashboards are portable and does not check in specific host names, or refer to
+        dashboards are portable and do not check in specific host names, or refer to
.github/workflows/prettier.yml (2)

29-38: Avoid running Prettier twice

The “Get files that need formatting” step executes the same expensive check again.
Capture the list on the first execution to reuse later, or use Prettier’s --loglevel silent + $? to propagate the list without re-invoking the binary.


40-69: Multi-line template loses indentation inside PR comment

The back-ticked JS template literal keeps the YAML indentation, so lines 48-62 will render with extra leading spaces in GitHub comments.
Wrap the string with dedent or align it flush-left to improve readability.

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro (Legacy)

📥 Commits

Reviewing files that changed from the base of the PR and between 3ba436a and ecee843.

📒 Files selected for processing (2)
  • .coderabbit.yaml (1 hunks)
  • .github/workflows/prettier.yml (1 hunks)
🧰 Additional context used
🧠 Learnings (10)
📓 Common learnings
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/README.md:1-35
Timestamp: 2025-07-01T11:34:26.699Z
Learning: User daniel-falk prefers using `prettier -w *.md` for markdown formatting instead of manual markdown fixes, and plans to integrate automated formatting into CI/CD pipelines systematically.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/lambdas/fixedit-developer-friend-devcloud-dependency-cache/index.py:61-62
Timestamp: 2025-07-01T11:33:53.832Z
Learning: User daniel-falk prefers using automated formatting tools like `black` for Python code formatting instead of manual PEP 8 fixes, and plans to integrate these tools into CI/CD pipelines. They also recommend `autopep8` for finding additional issues like incorrect names.
Learnt from: daniel-falk
PR: fixedit-ai/Axis-ACAP-libraries#54
File: libraries/builder-base/Makefile:1-5
Timestamp: 2024-10-25T10:25:19.311Z
Learning: - When suggesting code changes, include steps to pin the versions of tools like `mypy` and `black` for consistency.
- Include formatting and linting of YAML files in the workflows directory when setting up static tests.
Learnt from: daniel-falk
PR: fixedit-ai/client-doordash#19
File: .github/workflows/unit_tests.yml:3-7
Timestamp: 2024-11-05T09:37:26.633Z
Learning: In the `.github/workflows/unit_tests.yml` workflow, it's acceptable to use only the `push` trigger if running tests on all pushes covers the necessary cases. Including the `pull_request` trigger may be unnecessary unless handling contributions from forked repositories or pull requests without new commits.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/cloud_formation/web-service.yaml:67-67
Timestamp: 2025-07-28T10:11:12.253Z
Learning: User daniel-falk prefers managing sensitive configuration like API tokens through environment variables that are validated at deployment time, with clear error messages when required variables are missing. For CI/CD scenarios, these should be configured as repository secrets rather than hardcoded values.
Learnt from: fixedit-olatz
PR: fixedit-ai/fixedit-agents#295
File: acaps/config_agent/app/src/vapix_stream_profiles.cpp:126-134
Timestamp: 2025-06-18T09:44:13.318Z
Learning: When creating GitHub issues for refactoring tasks in the FixedIT codebase, include comprehensive file lists, clear before/after code examples, implementation notes, and proper backlinks to the original discussion for better tracking and context.
Learnt from: daniel-falk
PR: fixedit-ai/client-doordash#40
File: acaps/bootstrap_agent/fixedit-manifest-host.json:7-7
Timestamp: 2024-11-11T17:24:24.438Z
Learning: In PR #37 (https://github.com/fixedit-ai/client-doordash/pull/37), the build for host was fixed.
Learnt from: fixedit-olatz
PR: fixedit-ai/client-doordash#6
File: bootstrap_agent/app/src/installer_logic/acap_manager.cpp:76-109
Timestamp: 2024-10-30T13:55:27.450Z
Learning: When error handling improvements are suggested in code reviews, the team may choose to implement them in a separate PR.
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-agents#359
File: TEST_INSTRUCTIONS.md:244-245
Timestamp: 2025-07-03T15:28:04.994Z
Learning: In the fixedit-ai/fixedit-agents project, the configs_for_build directory is only used for plugin parsing purposes. Files in this directory should not be updated unless necessary because it breaks the build cache unnecessarily. Build cache optimization is an important consideration when making changes to configuration files.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#4
File: vscode_plugins/acap-documentation-viewer/src/utils/utils.ts:1-1
Timestamp: 2025-06-16T15:00:52.939Z
Learning: User daniel-falk prefers using established, well-tested JavaScript libraries over custom implementations for standard functionality like string sanitization, URL validation, and template inflation, especially for security-critical operations.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/lambdas/fixedit-developer-friend-devcloud-dependency-cache/index.py:67-67
Timestamp: 2025-07-27T10:49:53.485Z
Learning: User daniel-falk prefers explicit type annotations with proper dependencies over fallback mechanisms that silently disable type checking. He believes that if proper type hints are used, the required libraries should be added as dependencies rather than falling back to Any, which defeats the purpose of type checking.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/README.md:0-0
Timestamp: 2025-07-27T10:43:21.696Z
Learning: User daniel-falk prefers conservative documentation that only claims compatibility with Python versions that are actually tested, rather than making broad compatibility claims like "Python 3.8+" without verification. He believes it's better to document the specific version being used and tested rather than potentially fragile compatibility statements.
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#4
File: vscode_plugins/acap-documentation-viewer/src/controller/ResultWebview.ts:0-0
Timestamp: 2025-07-11T10:09:50.781Z
Learning: User daniel-falk prefers detailed, verbose comments that explain the "why" behind code decisions, not just the "what". Comments should provide extra context and be written for readers' understanding, even if they're longer. This applies especially to security-related code where explaining the reasoning (like CSP nonce generation for XSS prevention) adds valuable context.
📚 Learning: - when suggesting code changes, include steps to pin the versions of tools like `mypy` and `black` f...
Learnt from: daniel-falk
PR: fixedit-ai/Axis-ACAP-libraries#54
File: libraries/builder-base/Makefile:1-5
Timestamp: 2024-10-25T10:25:19.311Z
Learning: - When suggesting code changes, include steps to pin the versions of tools like `mypy` and `black` for consistency.
- Include formatting and linting of YAML files in the workflows directory when setting up static tests.

Applied to files:

  • .coderabbit.yaml
  • .github/workflows/prettier.yml
📚 Learning: in the fixedit-ai/client-doordash repository, detailed documentation should be maintained in per-app...
Learnt from: daniel-falk
PR: fixedit-ai/client-doordash#268
File: acaps/telegraf_agent/frontend/README.md:2-3
Timestamp: 2025-05-15T13:40:02.484Z
Learning: In the fixedit-ai/client-doordash repository, detailed documentation should be maintained in per-application README files rather than in the main README.md file.

Applied to files:

  • .coderabbit.yaml
📚 Learning: in the fixedit-ai/fixedit-agents project, when creating documentation that will be converted to pdf ...
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-agents#428
File: acaps/fixedit_data_agent/QUICKSTART_GUIDE.md:41-45
Timestamp: 2025-07-23T14:25:38.892Z
Learning: In the fixedit-ai/fixedit-agents project, when creating documentation that will be converted to PDF (like QUICKSTART_GUIDE.md), PDF output quality and formatting takes priority over GitHub markdown rendering. LaTeX environments like \begin{scriptsize} and \begin{verbatim} should be preserved even if they break GitHub preview, because end users primarily read the PDF versions rather than the GitHub markdown. This prioritizes user experience over developer experience.

Applied to files:

  • .coderabbit.yaml
📚 Learning: in the vscode_plugins/acap-documentation-viewer project, public documentation (readme, changelog) is...
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#14
File: vscode_plugins/acap-documentation-viewer/DEVELOP.md:85-85
Timestamp: 2025-08-01T08:43:55.730Z
Learning: In the vscode_plugins/acap-documentation-viewer project, public documentation (README, CHANGELOG) is intended for end users of the VS Code extension and should not include internal implementation details like data type conversion flows or system architecture. Developer documentation (DEVELOP.md) is the appropriate place for internal technical details that developers working on the extension need to understand.

Applied to files:

  • .coderabbit.yaml
📚 Learning: in prototypes/dashboards/dashboard-json-files/, the grafana dashboard json files are automatically g...
Learnt from: daniel-falk
PR: fixedit-ai/fixedit-agents#385
File: prototypes/dashboards/dashboard-json-files/config_agent.json:607-644
Timestamp: 2025-07-04T12:18:25.332Z
Learning: In prototypes/dashboards/dashboard-json-files/, the Grafana dashboard JSON files are automatically generated by Grafana. Manual optimizations or code style suggestions should not be applied to these files since changes would be overwritten when dashboards are updated through the Grafana UI.

Applied to files:

  • .coderabbit.yaml
📚 Learning: when creating github issues for refactoring tasks in the fixedit codebase, include comprehensive fil...
Learnt from: fixedit-olatz
PR: fixedit-ai/fixedit-agents#295
File: acaps/config_agent/app/src/vapix_stream_profiles.cpp:126-134
Timestamp: 2025-06-18T09:44:13.318Z
Learning: When creating GitHub issues for refactoring tasks in the FixedIT codebase, include comprehensive file lists, clear before/after code examples, implementation notes, and proper backlinks to the original discussion for better tracking and context.

Applied to files:

  • .coderabbit.yaml
📚 Learning: user daniel-falk prefers using `prettier -w *.md` for markdown formatting instead of manual markdown...
Learnt from: daniel-falk
PR: fixedit-ai/FixedIT-Developer-Friend#17
File: cloud_infra/README.md:1-35
Timestamp: 2025-07-01T11:34:26.699Z
Learning: User daniel-falk prefers using `prettier -w *.md` for markdown formatting instead of manual markdown fixes, and plans to integrate automated formatting into CI/CD pipelines systematically.

Applied to files:

  • .github/workflows/prettier.yml
📚 Learning: in the `.github/workflows/unit_tests.yml` workflow, it's acceptable to use only the `push` trigger i...
Learnt from: daniel-falk
PR: fixedit-ai/client-doordash#19
File: .github/workflows/unit_tests.yml:3-7
Timestamp: 2024-11-05T09:37:26.633Z
Learning: In the `.github/workflows/unit_tests.yml` workflow, it's acceptable to use only the `push` trigger if running tests on all pushes covers the necessary cases. Including the `pull_request` trigger may be unnecessary unless handling contributions from forked repositories or pull requests without new commits.

Applied to files:

  • .github/workflows/prettier.yml
📚 Learning: in the github actions workflows for this repository, the fixedit cli will produce an error if multip...
Learnt from: daniel-falk
PR: fixedit-ai/client-doordash#37
File: .github/workflows/build_and_test_acaps.yml:133-149
Timestamp: 2024-11-12T11:57:32.569Z
Learning: In the GitHub Actions workflows for this repository, the FixedIT CLI will produce an error if multiple files are produced, so it is safe to assume only one file will be generated.

Applied to files:

  • .github/workflows/prettier.yml
🪛 YAMLlint (1.37.1)
.coderabbit.yaml

[error] 9-9: trailing spaces

(trailing-spaces)


[error] 10-10: trailing spaces

(trailing-spaces)


[error] 11-11: trailing spaces

(trailing-spaces)


[error] 12-12: trailing spaces

(trailing-spaces)


[error] 13-13: trailing spaces

(trailing-spaces)


[error] 19-19: trailing spaces

(trailing-spaces)


[error] 20-20: trailing spaces

(trailing-spaces)


[error] 21-21: trailing spaces

(trailing-spaces)


[error] 28-28: trailing spaces

(trailing-spaces)


[error] 29-29: trailing spaces

(trailing-spaces)


[error] 30-30: trailing spaces

(trailing-spaces)


[error] 31-31: trailing spaces

(trailing-spaces)


[error] 32-32: trailing spaces

(trailing-spaces)

🔇 Additional comments (1)
.coderabbit.yaml (1)

33-34: Ensure Prettier is actually enforced on this file

You mention “We use Prettier for formatting … yaml, json, etc.”.
Since the workflow only checks formatting, any push that includes this file with trailing whitespace (see above) will fail. Consider adding a pre-commit hook (e.g., prettier --write) or running prettier --check in a separate job that also auto-formats and commits back for convenience.

@daniel-falk daniel-falk force-pushed the feature/setup-prettier-workflow branch from c9a5bbe to eadefcd Compare August 4, 2025 07:53
@daniel-falk daniel-falk force-pushed the feature/setup-prettier-workflow branch from eadefcd to 34f706a Compare August 5, 2025 13:41
@daniel-falk daniel-falk changed the base branch from feature/add-monitoring-dashboard to main August 5, 2025 13:41
@daniel-falk daniel-falk merged commit 32f8188 into main Aug 5, 2025
2 checks passed
@daniel-falk daniel-falk deleted the feature/setup-prettier-workflow branch August 5, 2025 13:43
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.

3 participants