Skip to content

Core caching fails when custom build path on different drive from system temporary folder #2157

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
3 tasks done
per1234 opened this issue Apr 24, 2023 · 0 comments
Open
3 tasks done
Labels
os: windows Specific to Windows operating system topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project

Comments

@per1234
Copy link
Contributor

per1234 commented Apr 24, 2023

Describe the problem

Under the following conditions:

  • A custom build path is set via the --build-path flag.
  • The build path is on a different drive from the system temporary folder.

core caching fails:

Couldn't deeply cache core build: Rel: can't make E:\build-path relative to C:\Users\per\AppData\Local\Temp\arduino\cores

To reproduce

$ arduino-cli version
arduino-cli.exe  Version: git-snapshot Commit: 2c2a5cc6 Date: 2023-04-24T05:04:04Z

$ arduino-cli sketch new "e:/FooSketch"  # The sketch path must be on the same drive as the build path due to arduino/arduino-cli#2156
Sketch created in: e:\FooSketch

$ arduino-cli compile --build-path "e:/build-path" --fqbn arduino:avr:uno "e:/FooSketch"
Couldn't deeply cache core build: Rel: can't make e:\build-path relative to C:\Users\per\AppData\Local\Temp\arduino\cores
Running normal build of the core...
Sketch uses 444 bytes (1%) of program storage space. Maximum is 32256 bytes.
Global variables use 9 bytes (0%) of dynamic memory, leaving 2039 bytes for local variables. Maximum is 2048 bytes.

Used platform Version Path
arduino:avr   1.8.6   C:\Users\per\AppData\Local\Arduino15\packages\arduino\hardware\avr\1.8.6

Expected behavior

Core caching to be done regardless of build path location.

Arduino CLI version

2c2a5cc

Operating system

Windows

Operating system version

11

Additional context

I was not able to reproduce the fault on Linux or macOS

Issue checklist

  • I searched for previous reports in the issue tracker
  • I verified the problem still occurs when using the nightly build
  • My report contains all necessary details
@per1234 per1234 added topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project os: windows Specific to Windows operating system labels Apr 24, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
os: windows Specific to Windows operating system topic: code Related to content of the project itself type: imperfection Perceived defect in any part of project
Projects
None yet
Development

No branches or pull requests

1 participant