Skip to content

sync AI instructions with upstream#359

Merged
softhack007 merged 5 commits intomdevfrom
ai_instructions_update
Apr 14, 2026
Merged

sync AI instructions with upstream#359
softhack007 merged 5 commits intomdevfrom
ai_instructions_update

Conversation

@softhack007
Copy link
Copy Markdown
Collaborator

@softhack007 softhack007 commented Apr 14, 2026

updated instructions / coding guides, to incorporate changes from upstream WLED.

Summary by CodeRabbit

  • Documentation
    • Updated C++ coding conventions (enum naming, const/constexpr guidance, hot-path and portability notes) and added caveats for filesystem name lengths and ESP8266 timing.
    • Strengthened contribution and review guidance: stricter feature-flag validation, explicit approval required for build-config changes, new guidance for AI-marked edits, and a recommended FMEA process for reliability/safety debates.

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 14, 2026

Warning

Rate limit exceeded

@softhack007 has exceeded the limit for the number of commits that can be reviewed per hour. Please wait 30 minutes and 5 seconds before requesting another review.

Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 30 minutes and 5 seconds.

⌛ How to resolve this issue?

After the wait time has elapsed, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout.

Please see our FAQ for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 19481e09-bfca-4d87-b833-33b85e0594aa

📥 Commits

Reviewing files that changed from the base of the PR and between fba4c4b and c383937.

📒 Files selected for processing (2)
  • .github/copilot-instructions.md
  • docs/cpp.instructions.md

Walkthrough

Updates AI-assisted review guidance and C++ coding standards docs: changes include stricter feature-flag name validation, new AI-generated code block markers, tightened platformio.ini modification rules, expanded const/constexpr and enum naming guidance, ESP8266 bit-shift notes, LittleFS filename caveat, and added human-only instruction blocks. (≤50 words)

Changes

Cohort / File(s) Summary
Copilot AI Review Guidance
.github/copilot-instructions.md
Removed requirement to “summarize good practices”; added exact-allowlist validation for WLED_ENABLE_* / WLED_DISABLE_* names; changed AI attribution to block delimiters (// AI: ... / // AI: end); require maintainer approval for platformio.ini changes and flag them; added FMEA guidance for "is it worth doing?" debates.
C++ Coding Standards
docs/cpp.instructions.md
Added PascalCase rule for enum values; new general style bullets (prefer static for local C helpers, avoid magic numbers, include "wled.h"); expanded and clarified const/constexpr guidance including forbidding reference data members; switched unsigned arithmetic example; extended bit-shift guidance to ESP8266; added LittleFS filename-length caveat; inserted <!-- HUMAN_ONLY_START --> / <!-- HUMAN_ONLY_END --> blocks and updated AI marker to // AI: end.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

Suggested reviewers

  • netmindz
🚥 Pre-merge checks | ✅ 3
✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title 'sync AI instructions with upstream' directly describes the main purpose of the pull request: updating instructions and coding guides to incorporate changes from upstream WLED.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ 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.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

coderabbitai[bot]

This comment was marked as resolved.

@softhack007
Copy link
Copy Markdown
Collaborator Author

@coderabbitai please check if <!-- HUMAN_ONLY_START --> / <!-- HUMAN_ONLY_END --> tags are still consistent (no overlap, every START is followed by END)

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 14, 2026

Tip

For best results, initiate chat on the files or code changes.

🧩 Analysis chain

🏁 Script executed:

#!/bin/bash
# Find all files containing HUMAN_ONLY tags
echo "=== Files with HUMAN_ONLY tags ==="
rg -l 'HUMAN_ONLY' 

echo ""
echo "=== All HUMAN_ONLY tag occurrences with line numbers ==="
rg -n 'HUMAN_ONLY' --no-heading

Length of output: 6099


@softhack007: All <!-- HUMAN_ONLY_START --> / <!-- HUMAN_ONLY_END --> tags are consistent across all three files that contain them. Here's the summary:

File START count END count Issues
docs/cpp.instructions.md 22 22 ✅ None
docs/cicd.instructions.md 1 1 ✅ None
docs/esp-idf.instructions.md 27 27 ✅ None

Findings:

  • Every START has a matching END — no unclosed blocks.
  • No END appears without a preceding START.
  • No nesting or overlapping — a new START never appears before the previous block's END.
  • There are a few back-to-back adjacent blocks (e.g., docs/cpp.instructions.md lines 392/393, and docs/esp-idf.instructions.md lines 427/429 and 599/600), where an END is immediately followed by a START on the next line — these are consecutive blocks, not overlaps, and are valid.

🧠 Learnings used
Learnt from: softhack007
Repo: MoonModules/WLED-MM PR: 0
File: :0-0
Timestamp: 2026-04-04T14:32:02.618Z
Learning: In MoonModules/WLED-MM, clang-format is intentionally NOT enforced via CI or .clang-format config because it would cause merge conflicts when cherry-picking features from upstream WLED (which uses different formatting). Instead, "soft" formatting rules are documented in .github/cpp.instructions.md. Do not recommend adding clang-format to CI as a follow-up to missing automated enforcement — the decision is deliberate.

Learnt from: softhack007
Repo: MoonModules/WLED-MM PR: 0
File: :0-0
Timestamp: 2026-04-04T00:29:49.127Z
Learning: In MoonModules/WLED-MM, function-level doc comment blocks (e.g. /* ***** */ style headers) are NOT required during code reviews, especially not for previously existing functions. Do not flag missing function-level comments as review issues in this repository.

Learnt from: softhack007
Repo: MoonModules/WLED-MM PR: 0
File: :0-0
Timestamp: 2026-04-07T16:49:44.284Z
Learning: In MoonModules/WLED-MM, `.github/agent-build.instructions.md` is intentionally kept in `.github/` (not moved to `docs/`) because it is exclusively meant for GitHub Copilot agent tasks, not for CodeRabbit code reviews. It should NOT be referenced in `.coderabbit.yaml` and should not be flagged as misplaced or missing from `docs/`.

Learnt from: softhack007
Repo: MoonModules/WLED-MM PR: 270
File: wled00/fcn_declare.h:403-406
Timestamp: 2025-10-22T21:59:24.331Z
Learning: In MoonModules/WLED-MM PR `#270`, the out-of-bounds null-terminator write in wled00/util.cpp (extractModeSlider) is deferred and tracked in Issue `#272`; do not address it within PR `#270`.

@softhack007 softhack007 changed the title sync c++ and generic instructions with upstream sync AI instructions with upstream Apr 14, 2026
@softhack007

This comment was marked as outdated.

@coderabbitai

This comment was marked as outdated.

coderabbitai[bot]

This comment was marked as resolved.

Moved feature flags into separate sub-section
added code example
Clarified the recommendation for using explicit shifts on RISC-V and ESP8266 boards.
@softhack007
Copy link
Copy Markdown
Collaborator Author

@coderabbitai review

@coderabbitai
Copy link
Copy Markdown

coderabbitai bot commented Apr 14, 2026

✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

Removed instruction about using common functions in Web UI updates.
@softhack007 softhack007 merged commit 83368c3 into mdev Apr 14, 2026
71 checks passed
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.

1 participant