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

LongPaths >260 characters. #786

Open
ericnewton76 opened this issue Jan 5, 2022 · 7 comments
Open

LongPaths >260 characters. #786

ericnewton76 opened this issue Jan 5, 2022 · 7 comments
Labels
area: core Issues that address the core abstractions & the wrappers state: needs discussion Issues that need further discussion type: enhancement Issues that propose new functionality

Comments

@ericnewton76
Copy link
Contributor

Is your feature request related to a problem? Please describe.
Long paths in windows >260characters cause issues. The underlying System.IO.File use Win32 APIs that fail to handle >260 cahracters properly.

Describe the solution you'd like
Theres a LongPaths repo that implements long file path support: (https://github.com/peteraritchie/LongPath/)
I'm proposing a merge of that code into the standard IFileSystem implementation or as an alternative IFileSystem implementation.

Describe alternatives you've considered
(https://github.com/peteraritchie/LongPath/)

Additional context
Add any other context or screenshots about the feature request here. I would possibly be the one to submit a pullrequest merging this in.

@ericnewton76 ericnewton76 added state: needs discussion Issues that need further discussion type: enhancement Issues that propose new functionality labels Jan 5, 2022
@hangy
Copy link
Contributor

hangy commented Jan 5, 2022

The LongPath library sounds pretty interesting for this common issue. Thanks for the hint! 😄

I'm proposing a merge of that code into the standard IFileSystem implementation or as an alternative IFileSystem implementation.

I think I'd prefer the latter. Maybe as a sister project in the https://github.com/TestableIO org? Some users may not want the additional dependency or might be depending on some specific System.IO behaviour cross-platform.

Also, the LongPath library is LGPL-3.0-only, while this project is MIT licensed, so that it cannot simply be bundled with System.IO.Abstractions. It additionally targets only older .NET Framework versions, so that it couldn't be integrated that easily.

@fgreinacher
Copy link
Contributor

Thanks for this issue @ericnewton76!

I agree with @hangy that the LongPath library sounds very useful! I'd also prefer to go forward with the "alternative IFileSystem implementation" you proposed in a separate repository. I could set something up in the TestableIO org, but only if there's at least one additional maintainer to help set it up and handle input.

@fgreinacher fgreinacher added the area: core Issues that address the core abstractions & the wrappers label Feb 2, 2022
@patrickdreyer
Copy link

Consider https://github.com/alphaleonis/AlphaFS, as it's MIT licensed too and could easily be bundled with System.IO.Abstractions.

@patrickdreyer
Copy link

patrickdreyer commented May 10, 2022

What: Please create the sister project (System.IO.Abstractions.AlphaFS or System.IO.Abstractions.Alphaleonis ?)
Why:
We will provide the AlphaFS specific FileSystem implementation (AlphaFileSystem or AlphaleonisFileSystem ?)
However, it will contain only what we already implemented anyway. Everything else will throw a NotImplementedException.
We have our own System IO abstraction right now and wanna replace it with this one here.

@fgreinacher
Copy link
Contributor

@patrickdreyer Wow, thanks! I'll take care in the next days. Who should I add as maintainers?

@patrickdreyer
Copy link

patrickdreyer commented Jan 12, 2023

@fgreinacher myself? :-)
Actually, I'll get some apprentices and I will let them to take care of the implementation.

@fgreinacher
Copy link
Contributor

@patrickdreyer We (well, mostly @vbreuss 😄) recently did some work to use the abstractions in another project: Testably/Testably.Abstractions#225.

We did not pull it into the TestableIO, but linked it from the README instead.

Would a similar approach also work for you?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: core Issues that address the core abstractions & the wrappers state: needs discussion Issues that need further discussion type: enhancement Issues that propose new functionality
Projects
None yet
Development

No branches or pull requests

4 participants