Skip to content
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

Symlink tests/mesonTest/subprojects/CLI11 causes directory cycle #696

Closed
boris-kolpackov opened this issue Jan 26, 2022 · 1 comment
Closed

Comments

@boris-kolpackov
Copy link

boris-kolpackov commented Jan 26, 2022

The tests/mesonTest/subprojects/CLI11 symlink points to its parent directory (../../.. to be precise) which causes a directory cycle that in turn can cause traversal issues for various tools. In case of build2 you get a warning, which is annoying:

warning: directory cycle caused by symlink build/.bpkg/tmp/78c1e67e6423/upstream/tests/mesonTest/subprojects/CLI11/
  info: symlink target build/.bpkg/tmp/78c1e67e6423/upstream/

Also note that directory symlinks on Windows are tricky (if at all available): https://build2.org/article/symlinks.xhtml#windows

@jspelletier
Copy link

jspelletier commented Jan 27, 2022

Hello,
This symlink is causing job failures in gitlab when this repo is used as submodules and the git strategy is clone. It seems this can also happen in fetch strategy if runner was previously in clone mode.

I don't know why you need this file but couldn't you instead create it at runtime when running tests? Please consider removing this symlink!

The symlink causes errors such as the following:
Remove-Item : There is a mismatch between the tag specified in the request and the tag present in the reparse point

At C:\Users\xxxxxxx\AppData\Local\Temp\build_script368801463\script.ps1:224 char:3
+   Remove-Item -Force -Recurse "C:\gitlab-runner\builds\CsRJCNVP\0\yyyy...
+   ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [Remove-Item], Win32Exception
    + FullyQualifiedErrorId : System.ComponentModel.Win32Exception,Microsoft.PowerShell.Commands.RemoveItemCommand

gitlab is unable to delete the submodule folder and this causes errors later on when trying to execute git clone operations

Thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants