update URL and document Nim bug blocking further genericizing cleanups (#3483)

This commit is contained in:
tersec 2022-03-11 15:03:47 +00:00 committed by GitHub
parent d0183ccd77
commit 21b71bd29c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with 11 additions and 3 deletions

View File

@ -236,6 +236,14 @@ type
blck*: BlockRef
## The block associated with the state found in data
# TODO when Nim 1.2 support is dropped, make these generic. 1.2 generates
# invalid C code, which gcc refuses to compile. Example test case:
# type
# OnBlockAdded[T] = proc(x: T)
# OnPhase0BlockAdded = OnBlockAdded[int]
# proc f(x: OnPhase0BlockAdded) = discard
# const nilCallback = OnPhase0BlockAdded(nil)
# f(nilCallback)
OnPhase0BlockAdded* = proc(
blckRef: BlockRef,
blck: phase0.TrustedSignedBeaconBlock,

View File

@ -98,7 +98,7 @@ proc readBootEnr*(path: string): seq[string] {.raises: [IOError, Defect].} =
proc loadEth2NetworkMetadata*(path: string, eth1Network = none(Eth1Network)): Eth2NetworkMetadata
{.raises: [CatchableError, Defect].} =
# Load data in eth2-networks format
# https://github.com/eth2-clients/eth2-networks/
# https://github.com/eth-clients/eth2-networks
try:
let

View File

@ -11,8 +11,8 @@ REPO_URL=https://github.com/ethereum/consensus-specs.git
VALID=".*\\.\\(md\\|py\\|yaml\\|sol\\)"
UNCHANGED_SPEC_FILES=$(comm -12 --check-order <(git clone --branch "${PREV_VERSION}" --config advice.detachedHead=false --depth 1 --quiet "${REPO_URL}" "${TMPDIR1}" && cd "${TMPDIR1}" && find . -type f -regex "${VALID}" -print0 | xargs -0 sha256sum | sort) <(git clone --branch "${NEXT_VERSION}" --config advice.detachedHead=false --depth 1 --quiet "${REPO_URL}" "${TMPDIR2}" && cd "${TMPDIR2}" && find . -type f -regex "${VALID}" -print0 | xargs -0 sha256sum | sort) | awk '{print $2}' | sed -e"s/^\.\///" | shuf)
# One can use this to automate the search andreplace with a tool such as
# https://github.com/kcoyner/rpl/ or just a find/sed combination, e.g.,:
# One can use this to automate the search and replace with a tool such as
# https://github.com/kcoyner/rpl/, or just a find/sed combination, e.g.,:
URL_BASE=https://github.com/ethereum/consensus-specs/blob/
FROM=${URL_BASE}${PREV_VERSION}/
TO=${URL_BASE}${NEXT_VERSION}/