-
Notifications
You must be signed in to change notification settings - Fork 33
Error TypeError: Cannot read property 'path' of undefined #7
Comments
And at times it throws Error: invalid block |
Found the root cause: In ipfs-repo/src/blockstore.js We have the put method which includes:
The structure of block obj will be like
And when i inspect the code inside Block.isBlock, it reads,
I am not sure from where it takes this, probably inside the dist file. But the intended code should read as,
Because of this, the block will always be invalidated and file upload will fail Hence when i tried by commenting out the isBlock validation, the file upload runs through smoothly and the blocks were successfully uploaded in bucket |
Hi @madan-ideas2it, what version of node are you running this with? |
@jacobheun v8.11.3 |
I updated the ipfs dependencies and am getting a different error related to cid versions. I will try to make some time later next week to look at this if you aren't able to troubleshoot the issue. I imagine it's related to a recent ipfs update as I demo'd this in early July. |
@jacobheun i troubleshooted and the issue is that wrong code is being picked up in blockstore put method as explained |
I upgraded ipfs and ipfs-repo in the example to the latest versions and got a completely different error when I tested it. For me it is failing on node startup, before attempting to upload the block. The symbol key you are seeing comes from class-is. I haven't been able to reproduce your error.
|
Related to ipfs/js-ipfs#1557 |
The examples should be working in the latest version, 0.2.0. I tested against a clean s3 bucket. @madan-ideas2it please let me know if you're still encountering an issue. |
Very stale. Please reopen if you're still seeing problems. |
This example doesnot seem to work for me, the files are not getting added to me and hence the callback after adding returns empty array instead of the files added.
The version config and lock files are getting generated in my bucket, but the actual file to be added is not getting uploaded and no error is thrown, instead it returns empty array
The text was updated successfully, but these errors were encountered: