-
Notifications
You must be signed in to change notification settings - Fork 28
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
Support filelike objects, not only pathes #35
Comments
Sounds like a reasonable addition! A PR would be welcome. |
It works, would just need rename of path to filelike |
OK! Updates to the naming and the docs would still be welcome in a PR. (But we wouldn't want to call it |
Nvm, saving doesn't work if using filelike. |
What if we use If you are OK with this I can try doing it. |
Sure! That seems worth a shot. Thanks for looking into it! |
fixes support to filelike objects resolves beetbox#35 Incompatible changes: - renames `MediaFile.path` to `MediaFile.filename` - renames `path` arument to `MediaFile` to `filename` (compatibility with mutagen) Mediafile can now be created using following scheme: ``` fileobj = io.BytesIO() ... Mediafile(filename="myfile.mp3") Mediafile(fileobj=myfileobj) ``` but ``` Mediafile("myfile.mp3") Mediafile(myfileobj) ``` will also work.
fixes support to filelike objects resolves beetbox#35 Incompatible changes: - renames `MediaFile.path` to `MediaFile.filename` - renames `path` arument to `MediaFile` to `filename` (compatibility with mutagen) Mediafile can now be created using following scheme: ``` fileobj = io.BytesIO() ... Mediafile(filename="myfile.mp3") Mediafile(fileobj=myfileobj) ``` but ``` Mediafile("myfile.mp3") Mediafile(myfileobj) ``` will also work.
fixes support to filelike objects resolves beetbox#35 Incompatible changes: - renames `MediaFile.path` to `MediaFile.filename` - renames `path` arument to `MediaFile` to `filename` (compatibility with mutagen) MediaFile can now be created using following scheme: ``` fileobj = io.BytesIO() ... MediaFile(filename="myfile.mp3") MediaFile(fileobj=myfileobj) ``` but ``` MediaFile("myfile.mp3") MediaFile(myfileobj) ``` will also work.
fixes support to filelike objects resolves beetbox#35 Incompatible changes: - renames `path` argument to `MediaFile` to `filename` (compatibility with mutagen) MediaFile can now be created using following scheme: ``` fileobj = io.BytesIO() # here goes filling of BytesIO with music file MediaFile(filename="myfile.mp3") MediaFile(fileobj=myfileobj) ``` but old style ``` MediaFile("myfile.mp3") MediaFile(myfileobj) ``` will also work.
fixes support to filelike objects resolves beetbox#35 Incompatible changes: - renames `path` argument to `MediaFile` to `filename` (compatibility with mutagen) MediaFile can now be created using following scheme: ``` fileobj = io.BytesIO() # here goes filling of BytesIO with music file MediaFile(filename="myfile.mp3") MediaFile(fileobj=myfileobj) ``` but old style ``` MediaFile("myfile.mp3") MediaFile(myfileobj) ``` will also work.
fixes support for filelike objects resolves beetbox#35 Incompatible changes: - renames `path` argument to `MediaFile` to `filename` (compatibility with mutagen) MediaFile can now be created using following scheme: ``` fileobj = io.BytesIO() MediaFile(filename="myfile.mp3") MediaFile(fileobj=myfileobj) ``` but old style ``` MediaFile("myfile.mp3") MediaFile(myfileobj) ``` will also work.
Hi!
I'm trying to use this library with remote files defined as file-likes in python.
mutagen
supports file-like interface, why tho mediafile doesn't?Docs say it needs local file path as first argument.
The text was updated successfully, but these errors were encountered: