Before logging an issue, please update to the latest release of Visual Micro from the Downloads Page.

When Logging a Support Issue in the Forum, please ensure you have also:-

  • Enabled vMicro > Compiler > Show Build Properties
  • Re-Compile your program with these settings enabled
 
Save the new Output to a Text File and....
  • Click the Reply button and attach as .txt file OR
  • Click here to Email us with the file attached, and a link to your post
Support requests without the output above may be impossible to answer, so please help us to help you
 
Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic recipe.hooks.errorbuild.1.pattern not being run on build error (Read 44 times)
Rick R
Newbies
*
Offline


Posts: 2
Joined: Oct 16th, 2026
recipe.hooks.errorbuild.1.pattern not being run on build error
Oct 23rd, 2026 at 6:25pm
Print Post  
Brand new to forum, excuse me if posted in the wrong place...

recipe.hooks.errorbuild.1.pattern=cmd.exe /c {build.project_path}\tools\ntfy_build.cmd failure {build.project_path} is not being run on build error?? This is my complete board.txt file. All works except this line??


# Wood_Burning_Stove build property overrides
#

# Visual Micro board-level build hooks.

# Increment firmware version immediately before compilation.
recipe.hooks.prebuild.90.pattern=cmd.exe /c {build.project_path}\tools\version_prebuild.cmd {build.project_path}


# ntfy: Record build start time.
recipe.hooks.prebuild.92.pattern=cmd.exe /c {build.project_path}\tools\ntfy_build.cmd start {build.project_path}

# ntfy: Notify when build succeeds.
recipe.hooks.postbuild.1.pattern=cmd.exe /c {build.project_path}\tools\ntfy_build.cmd success {build.project_path}

# ntfy: Notify when build fails.
recipe.hooks.errorbuild.1.pattern=cmd.exe /c {build.project_path}\tools\ntfy_build.cmd failure {build.project_path}



# Rebuild web UI assets before uploade work. This should work when JUST UPLOADING, and not Building ...
recipe.hooks.deploy.preupload.1.pattern=cmd.exe /c {build.project_path}\tools\build_web_automated.cmd

# Release COM4, reboot the ESP32, then allow firmware upload.
recipe.hooks.deploy.preupload.2.pattern=cmd.exe /c powershell.exe -NoProfile -ExecutionPolicy Bypass -File {build.project_path}\tools\preupload_esp32.ps1


# Restart PuTTY after upload.
recipe.hooks.deploy.postupload.1.pattern=cmd.exe /c powershell.exe -NoProfile -ExecutionPolicy Bypass -File {build.project_path}\tools\postupload_esp32.ps1

I have Stop On Error selected within the compiler options ... cannot find this topic in the forum. Any thoughts?? VS2026
  

Please Register or Login to the Forum to see File Attachments
Back to top
 
IP Logged
 
Tim@Visual Micro
Administrator
*****
Offline


Posts: 12261
Location: United Kingdom
Joined: Apr 10th, 2010
Re: recipe.hooks.errorbuild.1.pattern not being run on build error
Reply #1 - Today at 12:11am
Print Post  
Thanks. without stop on error does the event fire?
  
Back to top
IP Logged
 
Rick R
Newbies
*
Offline


Posts: 2
Joined: Oct 16th, 2026
Re: recipe.hooks.errorbuild.1.pattern not being run on build error
Reply #2 - Today at 1:42am
Print Post  
I have. I also tried adding a compiler error to my intermediated library files and tried both Stop on Error and without stop on error in case it was specific to the .ino file, to no avail . So a test matrix of compiler error in intermediate library file and in the .ino file with with without Stop on Error. All cases did not fire recipe.hooks.errorbuild.1.pattern=cmd.exe /d /s /c ""{build.project_path}\tools\ntfy_build.cmd" failure "{build.project_path}""   

I have another problem with recipe.hooks.deploy.postupload.1.pattern=powershell.exe -NoProfile -ExecutionPolicy Bypass -File "{build.project_path}\tools\postupload_esp32.ps1" -Port "{serial.port}" -BuildPath "{build.path}" -ProjectRoot "{build.project_path}" whereby it runs after firmware upload, but if I turn on "Automatic FS Upload: ON" it still runs after firmware upload, but before FS upload. Is there a hook for FS upload phase. My work around for this issue is that I simply create  a separate process with a 120second delay before it runs, which allows the FS Upload to finish.... I basically automatically start PUTTY after the upload automatically during development process...  probably not related, but still a hook issue. Thanks for your inquiry ....
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint