Skip to content

Exception when using Win32Directory.IsHardLink #13

Open
@ancow

Description

@ancow

If I try using "o update-wrap" on a network share, I get an exception stating that openfilesystem can''t get information about a junction point.
The complete backtrace is (sorry about the German - I don't know how to make it complain in English):

System.Reflection.TargetInvocationException: Ein Aufrufziel hat einen Ausnahmefehler verursacht. ---> System.IO.IOException: Unable to get information about junction point. ---> System.Runtime.InteropServices.COMException (0x80070001): Unzulässige Funktion. (Ausnahme von HRESULT: 0x80070001)
   --- Ende der internen Ausnahmestapelüberwachung ---
   bei OpenFileSystem.IO.FileSystems.Local.Win32.JunctionPoint.ThrowLastWin32Error(String message) in c:\src\openfilesystem\src\OpenFileSystem\FileSystems\Local\Win32\Interop\JunctionPoint.cs:Zeile 404.
   bei OpenFileSystem.IO.FileSystems.Local.Win32.JunctionPoint.InternalGetTarget(SafeFileHandle handle) in c:\src\openfilesystem\src\OpenFileSystem\FileSystems\Local\Win32\Interop\JunctionPoint.cs:Zeile 366.
   bei OpenFileSystem.IO.FileSystems.Local.Win32.JunctionPoint.Exists(String path) in c:\src\openfilesystem\src\OpenFileSystem\FileSystems\Local\Win32\Interop\JunctionPoint.cs:Zeile 322.
   bei OpenFileSystem.IO.FileSystems.Local.Win32.Win32Directory.get_IsHardLink() in c:\src\openfilesystem\src\OpenFileSystem\FileSystems\Local\Win32\Win32Directory.cs:Zeile 24.
   bei OpenWrap.Repositories.FolderRepository.DirectoryCopyAnchorageStrategy.Anchor(IDirectory packagesDirectory, IDirectory packageDirectory, String anchorName) in c:\src\openwrap\src\OpenWrap\Repositories\FolderRepository.cs:Zeile 163.
   bei OpenWrap.Repositories.FolderRepository.<AnchorPackages>d__14.MoveNext() in c:\src\openwrap\src\OpenWrap\Repositories\FolderRepository.cs:Zeile 125.
   bei System.Linq.Enumerable.<SelectManyIterator>d__31`3.MoveNext()
   bei OpenWrap.PackageManagement.DefaultPackageManager.<CopyPackageCore>d__c1.MoveNext() in c:\src\openwrap\src\OpenWrap\PackageManagement\DefaultPackageManager.cs:Zeile 460.
   bei OpenWrap.PackageManagement.DefaultPackageManager.<UpdateProjectPackageCore>d__107.MoveNext() in c:\src\openwrap\src\OpenWrap\PackageManagement\DefaultPackageManager.cs:Zeile 549.
   bei OpenWrap.PackageManagement.AbstractPackageOperationResultIterator.<System.Collections.Generic.IEnumerable<OpenWrap.PackageManagement.PackageOperationResult>.GetEnumerator>d__0.MoveNext() in c:\src\openwrap\src\OpenWrap\PackageManagement\AbstractPackageOperationResultIterator.cs:Zeile 27.
   bei OpenWrap.Commands.Wrap.UpdateWrapCommand.<UpdateProjectPackages>d__e.MoveNext() in c:\src\openwrap\src\OpenWrap.Commands\Wrap\UpdateWrapCommand.cs:Zeile 89.
   bei System.Linq.Enumerable.<ConcatIterator>d__71`1.MoveNext()
   bei System.Linq.Enumerable.WhereEnumerableIterator`1.MoveNext()
   bei OpenWrap.Commands.AbstractCommand.<Execute>d__0.MoveNext() in c:\src\openwrap\src\OpenWrap\Commands\AbstractCommand.cs:Zeile 23.
   bei OpenWrap.Commands.Cli.CommandLineRunner.<Run>d__b.MoveNext() in c:\src\openwrap\src\OpenWrap\Commands\Cli\CommandLineRunner.cs:Zeile 95.
   bei OpenWrap.Commands.Cli.ConsoleCommandExecutor.Execute(String commandLine, IEnumerable`1 optionalInputs) in c:\src\openwrap\src\OpenWrap\Commands\Cli\ConsoleCommandExecutor.cs:Zeile 39.
   bei OpenWrap.Commands.Cli.ShellRunner.Main(IDictionary`2 env) in c:\src\openwrap\src\OpenWrap\Commands\Cli\ShellRunner.cs:Zeile 76.
   --- Ende der internen Ausnahmestapelüberwachung ---
   bei System.RuntimeMethodHandle._InvokeMethodFast(Object target, Object[] arguments, SignatureStruct& sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
   bei System.RuntimeMethodHandle.InvokeMethodFast(Object target, Object[] arguments, Signature sig, MethodAttributes methodAttributes, RuntimeTypeHandle typeOwner)
   bei System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, Boolean skipVisibilityChecks)
   bei System.Reflection.RuntimeMethodInfo.Invoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   bei System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   bei OpenWrap.BootstrapRunner.<>c__DisplayClass16.<LoadEntrypointCache>b__15(IDictionary`2 env)
   bei OpenWrap.BootstrapRunner.ExecuteEntrypoint(KeyValuePair`2 entryPoint, IEnumerable`1 assemblies, IEnumerable`1 consumedArgs)
   bei OpenWrap.BootstrapRunner.Run(String[] args)

Translating some of the more necessary words:
bei => at
Zeile => line
Unzulässige Funktion => illegal function

The way I understand this, junction points aren't allowed on network drives and calling whatever function is used to check results in some sort of access exception. I might be mistaken, though, as the German translation seems a little strange.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions