Skip to content

Install dependencies from local path using symlinks #5

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

Merged
merged 1 commit into from
Sep 11, 2020
Merged

Install dependencies from local path using symlinks #5

merged 1 commit into from
Sep 11, 2020

Conversation

per1234
Copy link
Collaborator

@per1234 per1234 commented Sep 11, 2020

Port bug fix from experimental repository.

See: arduino/actions#81

Previously, the shared function used to install dependencies from local paths used copy instead of symlinks.

The switch to using copy for everything was done for a couple of reasons:

- Some functions were already using copy/move to install because they worked from temporary folders that are deleted by the context manager
- Use of symlinks on Windows requires the script to be run as administrator, which makes it less friendly to contributors or users running the script locally who are using Windows

However, the previous symlinks were essential for the deltas feature to work for libraries or platforms under test because these are installed to a different location than the repository that is checked out to the delta and head refs.

When the project under test is a sketch, symlinks are not necessary, since the sketch is run in place, which is why this bug was not detected via minimal informal integration tests.

The first reason to copy listed above is easily overcome by changing the code to create temporary folders with the required lifespan.

The second remains, but it's easy enough to find the solution to the error message resulting from running the script without the necessary permissions.
@per1234 per1234 added the type: imperfection Perceived defect in any part of project label Sep 11, 2020
@codecov-commenter
Copy link

Codecov Report

Merging #5 into main will not change coverage.
The diff coverage is 100.00%.

Impacted file tree graph

@@            Coverage Diff            @@
##              main        #5   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files            2         2           
  Lines         1555      1545   -10     
=========================================
- Hits          1555      1545   -10     
Impacted Files Coverage Δ
compilesketches/compilesketches.py 100.00% <100.00%> (ø)
compilesketches/tests/test_compilesketches.py 100.00% <100.00%> (ø)

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 9edb02e...7ea2bcf. Read the comment docs.

@per1234 per1234 merged commit df7b94f into arduino:main Sep 11, 2020
@per1234 per1234 deleted the install-via-symlink branch September 11, 2020 06:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: imperfection Perceived defect in any part of project
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants