ARDUINO_USER_AGENT environment variable not set #2499
Labels
conclusion: resolved
Issue was resolved
topic: code
Related to content of the project itself
type: imperfection
Perceived defect in any part of project
Describe the problem
Arduino CLI 0.36.0-rc.1 is not setting the ARDUINO_USER_AGENT environment variable when running tools.
To reproduce
Using Linux x86-64:
1: Install Teensy package 0.59.4
2: Copy this modified teensy_size tool to ~/.arduino15/packages/teensy/tools/teensy-tools/0.59.4/
3: Compile any sketch with FQBN "teensy:avr:teensy40" and look for "ARDUINO_USER_AGENT = " in the output.
This copy of teensy_size prints the ARDUINO_USER_AGENT environment variable to stdout. When run, you will see it prints (null).
To install Teensy package 0.59.4 using Arduino IDE 2.2.1:
1: File - Preferences, add Teensy URL https://www.pjrc.com/teensy/td_download.html
2: In Boards Manager, search "teensy".
3: Select 0.59.4 from drop-down list and click install.
Expected behavior
The ARDUINO_USER_AGENT environment variable is supposed to be set, according to the Platform Specification, under "Environment variables":
https://arduino.github.io/arduino-cli/0.35/platform-specification/#environment-variables
Running this with Arduino CLI 0.34.2 prints a correct ARDUINO_USER_AGENT.
Arduino CLI version
arduino-cli Version: 0.36.0-rc.1 Commit: 31e0341 Date: 2024-01-11T12:36:53Z
Operating system
Linux
Operating system version
Ubuntu 22.04
Additional context
This problem also happens with recent Arduino IDE night builds.
arduino/arduino-ide#2318
Issue checklist
The text was updated successfully, but these errors were encountered: