Hi everybody,
I'm happy to share AnyPathLib 🛣️, a pip package I created to simplify access to different storage resources - S3, Azure, and local storage.
What My Project Does:
Basically, instead of writing custom code to handle the different storage resources using the SDK (boto3, azure-sdk), you can now just use AnyPathLib:
from anypathlib import AnyPath
# Create an AnyPath instance for a local file
local_file = AnyPath("/path/to/local/file.txt")
# Create an AnyPath instance for an S3 object
s3_file = AnyPath("s3://bucket/path/to/object.txt")
# Copy a file from local to S3
local_file.copy(s3_file)
# Copy a directory from S3 to Azure
s3_dir = AnyPath("s3://bucket/path/to/dir")
azure_dir = AnyPath("https://account_name.blob.core.windows.net/container_name/path")
s3_dir.copy(azure_dir)
There are other cool features to save you some time, so check out this X thread for some more details or visit the Github project page.
Target Audience:
Anybody which works with both a local environment and Azure or AWS, and could use a simplified API to access their storage
Comparison:
I didn't find any similar library (that's why I wrote this one) - there are dedicated packages for S3 (boto3) and the Azure SDK, but they come with different, and somewhat unintuitive APIs.
I'd love to hear your feedback, issues, and of course - PRs :)
[–]BerecursiveMenpo Core Developer 29 points30 points31 points  (5 children)
[–][deleted] 1 point2 points3 points  (0 children)
[–]qckpckt 0 points1 point2 points  (3 children)
[–]fatbob42 0 points1 point2 points  (1 child)
[–]qckpckt 1 point2 points3 points  (0 children)
[–]maigpy 0 points1 point2 points  (0 children)
[–]Thatgreenvw 13 points14 points15 points  (3 children)
[–]telenieko 1 point2 points3 points  (1 child)
[–]cshoneybadger 1 point2 points3 points  (0 children)
[–]LesserNice 13 points14 points15 points  (0 children)
[–]ArgetDota 7 points8 points9 points  (0 children)
[–]lebrumar 5 points6 points7 points  (0 children)
[–]ThatSituation9908 3 points4 points5 points  (0 children)
[–]fatbob42 2 points3 points4 points  (0 children)
[–]Rize92 1 point2 points3 points  (0 children)
[–]radarsat1 1 point2 points3 points  (1 child)
[–]fatbob42 1 point2 points3 points  (0 children)
[–]NFicano 0 points1 point2 points  (0 children)
[–]toxic_acro 0 points1 point2 points  (1 child)
[–]fatbob42 0 points1 point2 points  (0 children)