Fix ETH Ropsten: websocket: read limit exceeded #490

Geth sets maxRequestContentLength to 5M.
However, Ropsten contains blocks of largers size (for example 599281).
These which cannot be fetched using API.

Fixed by hacky way of modifying the geth source before
the build of the project.
Will submit PR to go-ethereum with final fix.
pull/541/head
Martin Boehm 2020-11-25 22:13:16 +01:00 committed by jagdeep sidhu
parent 5a2fff4362
commit 0ec9c7a132
1 changed files with 2 additions and 0 deletions

View File

@ -35,6 +35,8 @@ prepare-sources:
@ [ -n "`ls /src 2> /dev/null`" ] || (echo "/src doesn't exist or is empty" 1>&2 && exit 1)
rm -rf $(BLOCKBOOK_SRC)
cp -r /src $(BLOCKBOOK_SRC)
cd $(BLOCKBOOK_SRC) && go mod download
sed -i 's/maxRequestContentLength\ =\ 1024\ \*\ 1024\ \*\ 5/maxRequestContentLength = 1024 * 1024 * 20/g' $(GOPATH)/pkg/mod/github.com/ethereum/go-ethereum*/rpc/http.go
generate-data:
cd $(BLOCKBOOK_SRC) && packr clean && packr