Description
Describe the problem
The "Network" tab of the Arduino IDE preferences allows users to configure the IDE to access the Internet either directly or through a proxy server.
🐛 If the user has previously configured the preferences to use a proxy server, it is impossible for them to change the preferences back to not using the proxy.
To reproduce
- Select File > Preferences... (Arduino IDE > Settings... for macOS users) from the Arduino IDE menus.
The "Preferences" dialog will open. - Select the "Network" tab from the "Preferences" dialog.
- Select the radio button next to "Manual proxy configuration".
- Set any values you like in the individual proxy configuration fields.
ⓘ You don't need to have a proxy server set up and the configuration doesn't need to be valid in order to perform this demonstration. - Click the "OK" button.
The "Preferences" dialog will close. - Select File > Quit from the Arduino IDE menus.
- Start Arduino IDE.
- Select File > Preferences... from the Arduino IDE menus.
- Select the "Network" tab from the "Preferences" dialog.
- Select the radio button next to "No proxy".
- Click the "OK" button.
- Select File > Quit from the Arduino IDE menus.
- Start Arduino IDE.
- Select File > Preferences... from the Arduino IDE menus.
- Select the "Network" tab from the "Preferences" dialog.
🐛 The "Manual proxy configuration" radio button is selected even though you previously selected "No proxy" and Arduino IDE continues to use the proxy configuration when accessing the Internet.
Expected behavior
The user can change the preference back to "No proxy".
Arduino IDE version
Operating system
Windows
Operating system version
11
Additional context
A variant of the fault was previously reported at arduino/arduino-cli#1677. The origin was identified as being a deficiency in Arduino CLI. That deficiency has since been resolved (arduino/arduino-cli#2212) and the IDE's Arduino CLI dependency bumped to the version that contains that change (#2165).
I had hoped that the manifestation of the fault in Arduino IDE would have been resolved as a matter of course by the change in Arduino CLI, but I see that is not the case so I think some changes will be needed in the Arduino IDE codebase as well to leverage the change in Arduino CLI.
I decided to create a new issue to track that work in the Arduino IDE codebase rather than reusing arduino/arduino-cli#1677 for that purpose because arduino/arduino-cli#1677 ended up being focused on the Arduino CLI deficiency and the symptom of the fault is now different than what is described in arduino/arduino-cli#1677.
At step (9) of the demonstration provided above, I see this printed in the IDE logs:
2023-08-22T07:25:21.712Z config INFO Updating daemon with 'data': {
"board_manager": {
"additional_urls": [
"https://www.pjrc.com/teensy/package_teensy_index.json"
]
},
"build_cache": {
"compilations_before_purge": 10,
"ttl": "720h0m0s"
},
"daemon": {
"port": "50051"
},
"directories": {
"data": "c:\\Users\\per\\AppData\\Local\\Arduino15",
"user": "c:\\Users\\per\\Documents\\Arduino"
},
"library": {
"enable_unsafe_install": false
},
"locale": "en",
"logging": {
"file": "",
"format": "text",
"level": "info"
},
"metrics": {
"addr": ":9090",
"enabled": true
},
"network": {},
"output": {
"no_color": false
},
"sketch": {
"always_export_binaries": false
},
"updater": {
"enable_notification": true
}
}
Workaround
- Select File > Quit from the Arduino IDE menus if it is running.
- Use any text editor to open the file at the following path:
- Windows:
(where
C:\Users\<username>\.arduinoIDE\arduino-cli.yaml
<username>
is your Windows username) - Linux:
❗ The
~/.arduinoIDE/arduino-cli.yaml
~/.arduinoIDE/
folder may be hidden by default in your file manager and terminal. - macOS:
❗ The
~/.arduinoIDE/arduino-cli.yaml
~/.arduinoIDE/
folder is hidden by default. You can make it visible by pressing the Command+Shift+. keyboard shortcut.
- Windows:
- Delete the lines from the file that have this format:
network: proxy: <some proxy URL> user_agent_ext: daemon
- Save the file.
- Start Arduino IDE.
You should now find that "No proxy" is selected in the "Network" tab of the "Preferences" dialog.
Additional reports
- Network configuration items can't be unset arduino-cli#1677
- https://forum.arduino.cc/t/avr-board-installation-error/1172997
- https://forum.arduino.cc/t/noob-now-msgs-when-starting-probs-using-hairless/1209281
Issue checklist
- I searched for previous reports in the issue tracker
- I verified the problem still occurs when using the latest nightly build
- My report contains all necessary details