Open marsrobertson opened 1 year ago
Because GTCR front-end is using Kleros node, I was thinking - let's just use Kleros IPFS node for uploading.
When running this repo on localhost - uploading works.
When running code from this repo in my own project - uploading does not work 🤷♀️
Code from this repo: https://github.com/kleros/gtcr/blob/9acd78d79e49cf023c9724b60fd79093faf7af10/src/utils/ipfs-publish.js
My stanalone version: https://plnkr.co/edit/kMigKchizDCDPJMg?preview
To run on localhost: python3 -m http.server
EDIT / UPDATE:
Request that works ----> OK status ----> CORS setup properly
Request with wrong data format ---> 500 status -----> no CORS on error codes
Basically problems with https://www.jsdelivr.com/package/npm/buffer VS Uint8Array
Kleros node: https://ipfs.kleros.io/ipfs/QmcpSAbiwZC3W4pu5ZfEuin94EMtreuEoTBqFigBp114hy
Default: https://gateway.ipfs.io/ipfs/QmcpSAbiwZC3W4pu5ZfEuin94EMtreuEoTBqFigBp114hy
(by the time you click it might have propagated)
EDIT / UPDATE: I've clicked now and it works. Probably some indexing delay.
I used https://app.pinata.cloud/ to upload new policies and then change arbitration params.