Skip to content

Fix Server sketch compilation: add forward declaration for purgePendingConfigNotes#266

Open
Copilot wants to merge 2 commits intomasterfrom
copilot/fix-arduino-compilation-error-yet-again
Open

Fix Server sketch compilation: add forward declaration for purgePendingConfigNotes#266
Copilot wants to merge 2 commits intomasterfrom
copilot/fix-arduino-compilation-error-yet-again

Conversation

Copy link
Contributor

Copilot AI commented Feb 28, 2026

handleConfigCancelPost calls purgePendingConfigNotes at line ~6850, but the function is defined at line ~7295 with no prior forward declaration, causing the Arduino preprocessor to fail with "not declared in this scope".

Change

Added one forward declaration to the existing declarations block alongside dispatchPendingConfigs:

// Before (line 1721):
static void dispatchPendingConfigs();

// After:
static uint8_t purgePendingConfigNotes(const char *clientUid);
static void dispatchPendingConfigs();
Original prompt

This section details on the original issue you should resolve

<issue_title>Arduino Compilation Error in TankAlarm-112025-Server-BluesOpta (2026-02-28)</issue_title>
<issue_description>## Arduino Compilation Failed - TankAlarm 112025

The Arduino code compilation failed for the TankAlarm-112025 (Blues Opta) projects.

Workflow Run: https://github.com/SenaxInc/ArduinoSMSTankAlarm/actions/runs/22531031477
Commit: ca16cde
Branch: master

Details

TankAlarm-112025 (Arduino Opta)

  • Client Sketch: TankAlarm-112025-Client-BluesOpta/TankAlarm-112025-Client-BluesOpta.ino ✅
  • Server Sketch: TankAlarm-112025-Server-BluesOpta/TankAlarm-112025-Server-BluesOpta.ino ❌
  • Viewer Sketch: TankAlarm-112025-Viewer-BluesOpta/TankAlarm-112025-Viewer-BluesOpta.ino ✅

Board:

  • Arduino Opta (arduino:mbed_opta:opta)

Triggered by: push

Next Steps

  1. Review the workflow logs for detailed error messages
  2. Fix compilation errors in the Arduino code
  3. Re-run the workflow to verify the fix

/cc @copilot</issue_description>

Comments on the Issue (you are @copilot in this section)


🔒 GitHub Advanced Security automatically protects Copilot coding agent pull requests. You can protect all pull requests by enabling Advanced Security for your repositories. Learn more about Advanced Security.

…Notes

Co-authored-by: dorkmo <1923070+dorkmo@users.noreply.github.com>
Copilot AI changed the title [WIP] Fix Arduino compilation error in TankAlarm-112025 server sketch Fix Server sketch compilation: add forward declaration for purgePendingConfigNotes Feb 28, 2026
@dorkmo dorkmo marked this pull request as ready for review February 28, 2026 23:37
Copilot AI review requested due to automatic review settings February 28, 2026 23:37
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Fixes an Arduino compilation failure in the Server sketch by adding a missing forward declaration so handleConfigCancelPost() can call purgePendingConfigNotes() before its definition.

Changes:

  • Added static uint8_t purgePendingConfigNotes(const char *clientUid); to the existing forward-declarations block in the Server sketch.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

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.

Arduino Compilation Error in TankAlarm-112025-Server-BluesOpta (2026-02-28)

3 participants