Skip to content

Commit 67f6dcf

Browse files
committed
support streaming for /cat option with stream=True
1 parent be7bd29 commit 67f6dcf

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

ipfsApi/http.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -71,6 +71,10 @@ def request(self, path,
7171
params=params, files=files, **kwargs)
7272

7373
if not decoder:
74+
# return raw stream
75+
if kwargs.get('stream'):
76+
return res.raw
77+
7478
if path == '/cat':
7579
# since <api>/cat only returns the raw data and not an encoded
7680
# object, dont't try to parse it automatically.

0 commit comments

Comments
 (0)