Add support for recognition and handling of Windows junctions.#5
Open
cb109 wants to merge 1 commit into4degrees:masterfrom
Open
Add support for recognition and handling of Windows junctions.#5cb109 wants to merge 1 commit into4degrees:masterfrom
cb109 wants to merge 1 commit into4degrees:masterfrom
Conversation
|
Great - thanks! I'll just do some additional testing and make sure it doesn't affect other platforms, but it seems like a useful addition. |
| try: | ||
| os.listdir(path) | ||
| accessDenied = False | ||
| except WindowsError as e: |
There was a problem hiding this comment.
careful about this exception, as it does exist only under windows....
just discovered at my expenses ;)
Contributor
Author
There was a problem hiding this comment.
That makes sense. It should probably be OSError then instead, from which WindowsError is a subclass.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi Martin,
When I gave riffle a try on my Windows 7 machine, it failed for folders like 'C:\Documents and Settings' or 'C:\Users\USER\Cookies' with 'Windows Error 5: Access denied'. This happens because these folders are junctions that are softlinked to other, real directories. I added support for them (using existing functionality from jaraco.windows) and thought it may be worth sharing. Feel free to decline in case you don't fancy it, had fun writing it anyway ;)
Cheers,
Christoph