compatibility of IPFS plugin with Python 3 - #2554
Conversation
|
@musoke, thanks for your PR! By analyzing the history of the files in this pull request, we identified @multikatt, @wordofglass and @jrobeson to be potential reviewers. |
|
Great; thank you! These were important fixes anyway.
|
|
OK, I'll fix those up and rebase. Do you want me to open a separate issue/pull request for the bug? |
|
Cool; thanks! For this, either a separate PR or an addendum to this one will be totally fine. Or you can just open the issue if you don't have time to propose a fix right now. |
153a7df to
9b3d12f
Compare
Paths were being constructed in a Python 3-incompatible way by concating bytes and strings. Do this more carefully by encoding and decoding of binary and strings.
In the future, just checking that a hash begins with "Qm" and has length 46 will likely not be sufficient.
9b3d12f to
c531927
Compare
|
OK, done. I opened an issue for the crash since I won't be fixing it in the next couple days. |
|
Anything else that needs to get done here? p.s. to keep the paper trail, #2555 is the opened issue referenced |
|
This PR was complete at the time I wrote it. I was waiting for feedback/merging before fixing the other bug but that never happened. |
|
Apologies for letting this drop. Merged at last! ✨ |
I was looking to use the IPFS plugin, but it seemed not to be compatible with Python 3. I've made some small updates here that bring it to where the Python 2 version was.
However, this does not bring the IPFS plugin totally up to date; there is an issue with the command
beet ipfs -g <hash>that became apparent when testing these changes. The other commands,-a,-i,-p,-ldo seem to work though.(Note that this is a fake hash.)
This is also present with Python 2 and versions v1.4.3 or the current master (09ea54).
Presumably this was able to sneak in as the IPFS plugin is not tested by the CI.
cc @multikatt who introduced the plugin in #1397