diff --git a/.xrefcheck.yaml b/.xrefcheck.yaml deleted file mode 100644 index a1c87cb6104..00000000000 --- a/.xrefcheck.yaml +++ /dev/null @@ -1,63 +0,0 @@ -# Parameters of repository traversal. -traversal: - # Files and folders which we pretend do not exist - # (so they are neither analyzed nor can be referenced). - ignored: - # Git files - - .git - # Build artifacts - - _build - - _opam - # Git submodules - - src/external - - src/lib/marlin - - src/lib/crypto/proof-systems - - src/lib/snarky - - frontend/wallet/tablecloth - # Unsure of the relevance anymore - - frontend/wallet/README.md - -# Verification parameters. -verification: - # On 'anchor not found' error, how much similar anchors should be displayed as - # hint. Number should be between 0 and 1, larger value means stricter filter. - anchorSimilarityThreshold: 0.5 - - # When checking external references, how long to wait on request before - # declaring "Response timeout". - externalRefCheckTimeout: 10s - - # Prefixes of files, references in which should not be analyzed. - notScanned: - - .github/pull_request_template.md - - .github/issue_template.md - - .github/PULL_REQUEST_TEMPLATE - - .github/ISSUE_TEMPLATE - - # Glob patterns describing the files which do not physically exist in the - # repository but should be treated as existing nevertheless. - virtualFiles: - - ../../../issues - - ../../../issues/* - - ../../../pulls - - ../../../pulls/* - - # POSIX extended regular expressions that match external references - # that have to be ignored (not verified). - # It is an optional parameter, so it can be omitted. - ignoreRefs: - - "https://github.com/.*" # Otherwise Resource unavailable (429 too many requests) - - # Check localhost links. - checkLocalhost: false - - # Skip links which return 403 or 401 code. - ignoreAuthFailures: true - -# Parameters of scanners for various file types. -scanners: - markdown: - # Flavor of markdown, e.g. GitHub-flavor. - # - # This affects which anchors are generated for headers. - flavor: GitHub diff --git a/buildkite/scripts/fuzzy-zkapp-test.sh b/buildkite/scripts/fuzzy-zkapp-test.sh index 04b2ebb7e78..bc62bcd4a79 100755 --- a/buildkite/scripts/fuzzy-zkapp-test.sh +++ b/buildkite/scripts/fuzzy-zkapp-test.sh @@ -21,7 +21,7 @@ export LIBP2P_NIXLESS=1 PATH=/usr/lib/go/bin:$PATH GO=/usr/lib/go/bin/go # skip running all of the tests that have already succeeded, since dune will # only retry those tests that failed. echo "--- Run fuzzy zkapp tests" -time dune exec "${path}" --profile="${profile}" -j16 -- --timeout "${timeout}" --individual-test-timeout "${individual_test_timeout}" --seed "${RANDOM}" +time dune exec "${path}" --profile="${profile}" -- --timeout "${timeout}" --individual-test-timeout "${individual_test_timeout}" --seed "${RANDOM}" STATUS=$? if [ "$STATUS" -ne 0 ]; then ./scripts/link-coredumps.sh && exit "$STATUS" diff --git a/buildkite/scripts/unit-test.sh b/buildkite/scripts/unit-test.sh index b38ad7d94a8..4cb4c5d29bd 100755 --- a/buildkite/scripts/unit-test.sh +++ b/buildkite/scripts/unit-test.sh @@ -21,10 +21,10 @@ export LIBP2P_NIXLESS=1 PATH=/usr/lib/go/bin:$PATH GO=/usr/lib/go/bin/go time make build echo "--- Build all targets" -dune build "${path}" --profile="${profile}" -j8 +dune build "${path}" --profile="${profile}" echo "--- Check for changes to verification keys" -time dune runtest "src/app/print_blockchain_snark_vk" --profile="${profile}" -j8 +time dune runtest "src/app/print_blockchain_snark_vk" --profile="${profile}" # Turn on the proof-cache assertion, so that CI will fail if the proofs need to # be updated. @@ -35,8 +35,8 @@ export ERROR_ON_PROOF=true # skip running all of the tests that have already succeeded, since dune will # only retry those tests that failed. echo "--- Run unit tests" -time dune runtest "${path}" --profile="${profile}" -j8 || \ +time dune runtest "${path}" --profile="${profile}" || \ (./scripts/link-coredumps.sh && \ echo "--- Retrying failed unit tests" && \ - time dune runtest "${path}" --profile="${profile}" -j8 || \ + time dune runtest "${path}" --profile="${profile}" || \ (./scripts/link-coredumps.sh && false)) diff --git a/buildkite/src/Constants/ContainerImages.dhall b/buildkite/src/Constants/ContainerImages.dhall index 51d266b64fe..b17bd8ccaff 100644 --- a/buildkite/src/Constants/ContainerImages.dhall +++ b/buildkite/src/Constants/ContainerImages.dhall @@ -14,6 +14,6 @@ , ubuntu2004 = "ubuntu:20.04" , postgres = "postgres:12.4-alpine" , xrefcheck = - "serokell/xrefcheck@sha256:8fbb35a909abc353364f1bd3148614a1160ef3c111c0c4ae84e58fdf16019eeb" + "dkhamsing/awesome_bot@sha256:a8adaeb3b3bd5745304743e4d8a6d512127646e420544a6d22d9f58a07f35884" , nixos = "gcr.io/o1labs-192920/nix-unstable:1.0.0" } diff --git a/buildkite/src/Jobs/Lint/Xrefcheck.dhall b/buildkite/src/Jobs/Lint/Xrefcheck.dhall index c8fead2e93d..d586f08c5cf 100644 --- a/buildkite/src/Jobs/Lint/Xrefcheck.dhall +++ b/buildkite/src/Jobs/Lint/Xrefcheck.dhall @@ -12,8 +12,6 @@ let Cmd = ../../Lib/Cmds.dhall let Command = ../../Command/Base.dhall -let Docker = ../../Command/Docker/Type.dhall - let Size = ../../Command/Size.dhall let B/SoftFail = B.definitions/commandStep/properties/soft_fail/Type @@ -23,7 +21,8 @@ in Pipeline.build , spec = JobSpec::{ , dirtyWhen = [ SelectFiles.strictly SelectFiles::{ exts = Some [ "md" ] } - , SelectFiles.strictly (SelectFiles.contains ".xrefcheck.yml") + , SelectFiles.strictlyStart + (SelectFiles.contains "buildkite/src/Jobs/Lint/Xrefcheck.dhall") ] , path = "Lint" , name = "Xrefcheck" @@ -36,15 +35,27 @@ in Pipeline.build , steps = [ Command.build Command.Config::{ - , commands = [] : List Cmd.Type + , commands = + [ Cmd.runInDocker + Cmd.Docker::{ + , image = (../../Constants/ContainerImages.dhall).xrefcheck + } + ( "awesome_bot -allow-dupe " + ++ "--allow-redirect " + ++ "--allow 403,401 " + ++ "--skip-save-results " + ++ "--files " + ++ "`find . -name \"*.md\" " + ++ "! -path \"./src/lib/crypto/kimchi_bindings/*\" " + ++ "! -path \"./src/lib/crypto/proof-systems/*\" " + ++ "! -path \"./src/external/*\" " + ++ "` " + ) + ] , label = "Verifies references in markdown" , key = "xrefcheck" , target = Size.Small , soft_fail = Some (B/SoftFail.Boolean True) - , docker = Some Docker::{ - , image = (../../Constants/ContainerImages.dhall).xrefcheck - , shell = None (List Text) - } } ] }