Skip to content

Very Strange behavior on python3.4 #41

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

Closed
xeroc opened this issue Jun 2, 2016 · 6 comments
Closed

Very Strange behavior on python3.4 #41

xeroc opened this issue Jun 2, 2016 · 6 comments

Comments

@xeroc
Copy link

xeroc commented Jun 2, 2016

I have a directory with a single image in it which I want to put into
IPFS:

steem@rootu:/var/ipfs/tmp$ ~/.local/bin/ipfs add -r tmpif66w1c4/
added QmU8fTvjUP8a2PoaPqf1pDQ4Fm2yrtAruS8pmHHAaZRrxJ tmpif66w1c4/045f1518-2828-11e6-9574-9db9ce0b34be.png
added QmQVwkefgTHCpauE3nAxixpWsiWRD23AUENnhJ94DGMQtJ tmpif66w1c4

So that is good, but I want to use python:

steem@rootu:/var/ipfs/tmp$ python3
Python 3.4.2 (default, Oct  8 2014, 10:45:20) 
[GCC 4.9.1] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import ipfsApi
>>> api = ipfsApi.Client('127.0.0.1', 5001)
>>> res = api.add("tmpif66w1c4", recursive=True)
r>>> res
{'Name': 'tmpif66w1c4', 'Hash': 'QmY91butp7Pcnm9DtUUqWUupYXkVdfMwKTPbGuK3Ha85nZ'}

Didn't work. How about I add a /?

>>> res = api.add("tmpif66w1c4/", recursive=True)
>>> res
[{'Name': 'tmpif66w1c4/', 'Hash': 'QmUPU3iYDqD8xSp4NoBByWR5wMbLh1hiFSq5Ys6FRNaagj'}, {'Name': 'tmpif66w1c4', 'Hash': 'QmVmgQfRgP4fy8NH2rCotuRt4kwCUiiBPiPA3vo3aAyZ6T'}]

WTF?

@parkan
Copy link

parkan commented Jul 19, 2016

I am seeing very similar behavior under 2.7, did you figure this out @xeroc?

@parkan
Copy link

parkan commented Jul 19, 2016

OK seems to be related to the add api change:

ipfs-inactive/js-ipfs-http-client#178

@whereswaldon
Copy link
Contributor

Since #46 resolved #45, can anyone confirm whether this is taken care of?

@jbenet
Copy link

jbenet commented Aug 12, 2016

cc @diasdavid @dignifiedquire @whyrusleeping who should make sure this was not a user space breakage in the part of go-ipfs.

@whyrusleeping @Kubuxu reminder that we need to ensure all bindings are run with a robust test suite against every release of go-ipfs.

@ntninja
Copy link
Contributor

ntninja commented Sep 15, 2016

Hasn't this been fixed for a while?

@ntninja
Copy link
Contributor

ntninja commented Sep 25, 2016

This has been fixed in the new release. Also we now validate the daemon version if the ipfsapi.connect() function is used, nothing else we can do from our side at this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

5 participants