I tried debugging and trying to find the problem with the path. The value of readableStreamForFile.path is: "/home/mrpimp/linuxProjects/hardhat-nft/images/randomNft/pug.png"
I've also tried using the clone of this repository and I got the same error. My best guess is that Pinata updated their library recently or that there is a problem with my computer which seems unlikely.
Issue description:
At 21:45:57, I try the command: hh deploy --tags randomipfs,mocks
I get this error: Error: readStream is not a readable stream or form data
I get the error three times since the problem is within the for loop containing the readableStreamForFIle variable.
My code:
This is my code for uploadToPinata.js:
This is my code for 02-deploy-random-ipfs.js:
PS:
I tried debugging and trying to find the problem with the path. The value of readableStreamForFile.path is: "/home/mrpimp/linuxProjects/hardhat-nft/images/randomNft/pug.png"
I've also tried using the clone of this repository and I got the same error. My best guess is that Pinata updated their library recently or that there is a problem with my computer which seems unlikely.