Teensy boards starting to fail in github actions (arduino/compile-sketches)

temporary_user

New member
Hope this is not out-of-scope:

At the Mozzi library (hosted on github) we use github actions for continuous integration. This includes builds for teensy 3.6 and 4.1. These just started failing almost exactly four days ago with
Code:
  Opening Teensy Loader...
  Unable find Teensy Loader.  (p)  Is the Teensy Loader application running?
  quit
This is definitely not from a change in Mozzi, but of course, it may have been a change in the workflows we import, or the github infrastructure, itself. Noteably, however, all other of our supported platforms seem unaffected.

I don't really know, how to even start debugging this, but perhaps it rings a bell, here?

Link to a failed build: https://github.com/sensorium/Mozzi/actions/runs/9530526281
Link to a recent successful build: https://github.com/sensorium/Mozzi/actions/runs/9438094175

(note that python has updated from 4.5 to 5.0 between these two, but there's also this intermediate run failing with python 4.5, so this does not seem to be the issue: https://github.com/sensorium/Mozzi/actions/runs/9473517356/job/26164703326#step:4:215 ; here, I had re-run the previously successful run for Teensy 3.6 for testing purposes)

Regards
Thomas (tfry-git)
 
Additional observations:
  • Reverting the github "compile-sketches" action to an earlier version does not help. This is quite definitely not due to a change somewhere on github, but to a change in the teensy core around early June.
  • It's probably quite normal in this use case that a Teensy Loader application is not around. The action is simply meant to compile the sketch (and that actually works). The problem is that it still exits with an error after compilation. Roughly, the action is trying to run
    Code:
    arduino-cli compile --warnings all --fqbn teensy:avr:teensy41
    . It would be great, if this could be (again) made to succeed, even if the teensy loader is not around.
 
Hi,

I'm having the exact same issue on gitlab-ci, was there an update of 1.59.0 ? I believe it was running this version before without issues and unfortunately we triggered a rebuild of our container image so it probably updated arduino-cli and debian.
I will try reverting to a previous version of the teensy tools to see if that works.

Best,
Antoine
 
Additional observations:
  • Reverting the github "compile-sketches" action to an earlier version does not help. This is quite definitely not due to a change somewhere on github, but to a change in the teensy core around early June.
  • It's probably quite normal in this use case that a Teensy Loader application is not around. The action is simply meant to compile the sketch (and that actually works). The problem is that it still exits with an error after compilation. Roughly, the action is trying to run
    Code:
    arduino-cli compile --warnings all --fqbn teensy:avr:teensy41
    . It would be great, if this could be (again) made to succeed, even if the teensy loader is not around.
After some investigation and trying to revert to previous version of my base image, and the teensy core, nothing would work.
After digging further, what worked was reverting arduino-cli to version 0.35.3, it seems the new version 1.0.0 is what introduced the new behavior.
 
After some investigation and trying to revert to previous version of my base image, and the teensy core, nothing would work.
After digging further, what worked was reverting arduino-cli to version 0.35.3, it seems the new version 1.0.0 is what introduced the new behavior.
If you have not done so yet, you may want to post up on the Arduino forum and/or open issue with Arduino CLI?
At least with the first posting, looks like several of the warnings are in the mozzi library. Like:
1720189755444.png

Like line 124 here, which looks like it changed 6 months ago...

I am assuming that this is probably related to the issue up on this library:

Good luck
 
After some investigation and trying to revert to previous version of my base image, and the teensy core, nothing would work.
After digging further, what worked was reverting arduino-cli to version 0.35.3, it seems the new version 1.0.0 is what introduced the new behavior.

Great find! I can confirm this, and it provides a path to work around the issue for the time being (compile-sketches allows a "cli-version" parameter).

If you have not done so yet, you may want to post up on the Arduino forum and/or open issue with Arduino CLI?
At least with the first posting, looks like several of the warnings are in the mozzi library. Like: [...]

I submitted a ticket to arduino-cli: https://github.com/arduino/arduino-cli/issues/2658

The warnings in Mozzi are unrelated to this. They are warnings, not errors.
 
Somehow this thread was on my list of issues to investigate. Looks like the Arduino developers updated Arduino CLI, so this is no longer a problem?

I can confirm the code inside teensy_post_compile does indeed look for ARDUINO_USER_AGENT to have a specific format. This is the code that's been inside 1.59 and the first few 1.60 betas.

Code:
        ardua = getenv("ARDUINO_USER_AGENT");

        if (ardua && strchr(ardua, ' ') == NULL && strstr(ardua, "arduino-ide") == NULL) {
                int a, b, c;
                if (sscanf(ardua, "arduino-cli/%d.%d.%d", &a, &b, &c) == 3) {
                        if (a > 0 || (a == 0 && b >= 22)) headless_mode = 1;
                } else if (sscanf(ardua, "arduino-cli/nightly-%d", &a) == 1) {
                        if (a >= 20220611 && a < 22220000) headless_mode = 1;
                }
        }
 
Back
Top