Correct local source pulling
Metadata
Current evaluation
Merged PR #377 corrected symlink-aware local source checks, preventing cleanup failures and allowing local sources to be pulled twice without an "is a symlink" error.
Resolution: closed resolved
Reason: PR #377 was merged as commit 8b4a18d9b, with the fix committed as eb6ad38ab. It explicitly handles symlinks and fixes repeated local source pulls.
Evaluated by: mr-cal-bot
No scores available.
Issue body
isdir evaluates to true as it follows symlinks by default and
later fails when doing an rmdir, so we invert the check and we
also specifically check for a link or fail in a controlled way
if not for healthier user output.
This also fixes the case where you could not pull twice with the
"is a symlink error".
LP: #1558446
Signed-off-by: Sergio Schvezov sergio.schvezov@ubuntu.com
Evaluation history
| Date | Model | Scores | Action | Summary |
|---|---|---|---|---|
| stealth/space-bunny-alpha | — | closed resolved | Merged PR #377 corrected symlink-aware local source checks, preventing cleanup failures and allowing local sources to be pulled twice without an "is a symlink" error. | |
| stealth/space-bunny-alpha | — | closed resolved | Fixed local source pulling in merged PR #377 by correcting symlink-aware directory checks and allowing repeated pulls without an "is a symlink" error. | |
| stealth/space-bunny-alpha | — | closed resolved | Fixed local source pulling in merged PR #377 via commit eb6ad38ab: inverted the isdir check, handled symlinks explicitly, and allowed pulling twice without an “is a symlink” error. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged in PR #377 (8b4a18d9b), fixing symlinked local source pulls and allowing a second pull without an “is a symlink” error. | |
| stealth/space-bunny-alpha | — | closed resolved | Merged fix for local source pulls: symlink-safe directory handling prevented rmdir failures and allowed repeated pulls. Resolved Launchpad bug #1558446. | |
| qwen/qwen3.6-35b-a3b | — | — | Merged fix for local source pulling that incorrectly followed symlinks, causing rmdir failures and duplicate pull errors. The change inverts the directory check, adds explicit symlink validation, and improves error handling. Approved by @zyga. Resolves LP: #1558446. | |
| qwen3.6-35b-a3b-mtp-q6 | — | — | Merged fix for local source pulling that resolved symlink handling and isdir check errors. The update inverts the directory check, validates links explicitly, and prevents duplicate pull failures. Approved by @zyga and merged to address LP: #1558446. |
Update history
No update history recorded yet.
Related issues
| Issue | Project | State | Summary | Similarity |
|---|---|---|---|---|
| #1558446 Pulling local sources is rather broken | snapcraft (launchpad) | closed | Local source pull bug fixed by ubuntu-core/snapcraft PR #377 (commit eb6ad38ab "Correct local source pulling", merged as 8b4a18d9b), which inverts the isdir/rmdir checks so symlinked local sources are removed rather than raising. | |
| #1659653 Symlinks to directories in local sources aren't pulled as symlinks | snapcraft (launchpad) | closed | Merged PR #1081 (commit baeec1045) fixed local source handling to preserve directory symlinks instead of replacing them with directories. | |
| #1081 local source: preserve symlinks to directories. | snapcraft | merged | Merged PR #1081 as baeec1045, preserving directory symlinks in local sources instead of replacing them with directories; fixes LP #1659653. | |
| #83 Don't follow symlinks when provisioning the build | snapcraft | merged | Merged PR #83 (branch local_source_copy_fix) via merge commit 7071da3ea, change commit 503e9b2b7, stopping source copy from following symlinks during build provisioning and fixing the local-source build failure. | |
| #322 sources: improve missing local source error message | craft-parts | merged | Merged PR #322 improved missing local-source handling to report a source-not-found error instead of exposing a file-copy error. | |
| #262 Refactored the local source pull. | snapcraft | merged | Merged PR #262 refactored local source pulling and added full test coverage in commit 70d51290e; merge commit: 3d0e49c4c. | |
| #2167 many: detect local source changes | snapcraft | merged | Merged #2167, adding timestamp-based detection of local source changes so pull and subsequent steps refresh when local sources are newer; resolves LP #1583718. |