this derivation will be built: /nix/store/81wkz1k0mhlb9sdjndlfinm0f657vy9b-nix-grpc-store-clang-tidy-0.1.0-beta.1.drv building '/nix/store/81wkz1k0mhlb9sdjndlfinm0f657vy9b-nix-grpc-store-clang-tidy-0.1.0-beta.1.drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> tribuchet: building on jamie nix-grpc-store-clang-tidy-0.1.0-beta.1> Running phase: unpackPhase nix-grpc-store-clang-tidy-0.1.0-beta.1> unpacking source archive /nix/store/3kkwqmd1mcjxg12w5kgfdw4dqsmrxsa0-source nix-grpc-store-clang-tidy-0.1.0-beta.1> source root is source nix-grpc-store-clang-tidy-0.1.0-beta.1> Running phase: patchPhase nix-grpc-store-clang-tidy-0.1.0-beta.1> Running phase: updateAutotoolsGnuConfigScriptsPhase nix-grpc-store-clang-tidy-0.1.0-beta.1> Running phase: configurePhase nix-grpc-store-clang-tidy-0.1.0-beta.1> mesonConfigurePhase flags: --prefix=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1 --libdir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/lib --libexecdir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/libexec --bindir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/bin --sbindir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/sbin --includedir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/include --mandir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/man --infodir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/info --localedir=/nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/locale -Dauto_features=enabled -Dwrap_mode=nodownload --buildtype=plain -Db_pch=false nix-grpc-store-clang-tidy-0.1.0-beta.1> The Meson build system nix-grpc-store-clang-tidy-0.1.0-beta.1> Version: 1.10.2 nix-grpc-store-clang-tidy-0.1.0-beta.1> Source dir: /build/source nix-grpc-store-clang-tidy-0.1.0-beta.1> Build dir: /build/source/build nix-grpc-store-clang-tidy-0.1.0-beta.1> Build type: native build nix-grpc-store-clang-tidy-0.1.0-beta.1> WARNING: Project does not target a minimum version but uses feature introduced in '1.1': meson.options file. Use meson_options.txt instead nix-grpc-store-clang-tidy-0.1.0-beta.1> Project name: nix-grpc-store nix-grpc-store-clang-tidy-0.1.0-beta.1> Project version: 0.1.0-beta.1 nix-grpc-store-clang-tidy-0.1.0-beta.1> C++ compiler for the host machine: clang++ (clang 22.1.8 "clang version 22.1.8") nix-grpc-store-clang-tidy-0.1.0-beta.1> C++ linker for the host machine: clang++ ld.bfd 2.46 nix-grpc-store-clang-tidy-0.1.0-beta.1> Host machine cpu family: x86_64 nix-grpc-store-clang-tidy-0.1.0-beta.1> Host machine cpu: x86_64 nix-grpc-store-clang-tidy-0.1.0-beta.1> Found pkg-config: YES (/nix/store/29d1c5xk6w3rwl7yvdfwl90whslv5h54-pkg-config-wrapper-0.29.2/bin/pkg-config) 0.29.2 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency grpc++ found: YES 1.83.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency protobuf found: YES 36.1.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency libzstd found: YES 1.5.7 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency threads found: YES nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency libcrypto found: YES 3.6.4 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency prometheus-cpp-core found: YES 1.3.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency prometheus-cpp-pull found: YES 1.3.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency absl_flat_hash_map found: YES 20260107 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency absl_hash found: YES 20260107 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency absl_synchronization found: YES 20260107 nix-grpc-store-clang-tidy-0.1.0-beta.1> Compiler for C++ supports arguments -Werror=thread-safety: YES nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency jemalloc found: YES 5.3.1_0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency nix-store found: YES 2.36.0pre20260920_5711f8fe nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency nix-util found: YES 2.36.0pre20260920_5711f8fe nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency libcurl found: YES 8.22.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency nlohmann_json found: YES 3.12.0 nix-grpc-store-clang-tidy-0.1.0-beta.1> Check usable header "jwt-cpp/traits/nlohmann-json/defaults.h" : YES nix-grpc-store-clang-tidy-0.1.0-beta.1> Program protoc found: YES (/nix/store/4hdzvycn5mkg3xm1ggscp3mxz8005c3m-protobuf-36.1/bin/protoc) nix-grpc-store-clang-tidy-0.1.0-beta.1> Program grpc_cpp_plugin found: YES (/nix/store/n81x7qakspm4bnm9q8cjdgjvvx6h691v-grpc-1.83.0/bin/grpc_cpp_plugin) nix-grpc-store-clang-tidy-0.1.0-beta.1> Program mold found: YES (/nix/store/vfvfq1k7436b6sidk1246m72j6944kv7-mold-unwrapped-wrapper-2.42.1/bin/mold) nix-grpc-store-clang-tidy-0.1.0-beta.1> Run-time dependency dl found: YES nix-grpc-store-clang-tidy-0.1.0-beta.1> Program tests/farm-client-test.sh found: YES (/build/source/tests/farm-client-test.sh) nix-grpc-store-clang-tidy-0.1.0-beta.1> Program tests/oidc-test.sh found: YES (/build/source/tests/oidc-test.sh) nix-grpc-store-clang-tidy-0.1.0-beta.1> Build targets in project: 11 nix-grpc-store-clang-tidy-0.1.0-beta.1> WARNING: Project specifies no minimum version but uses features which were added in versions: nix-grpc-store-clang-tidy-0.1.0-beta.1> * 1.1: {'meson.options file'} nix-grpc-store-clang-tidy-0.1.0-beta.1> nix-grpc-store-clang-tidy-0.1.0-beta.1> nix-grpc-store 0.1.0-beta.1 nix-grpc-store-clang-tidy-0.1.0-beta.1> nix-grpc-store-clang-tidy-0.1.0-beta.1> User defined options nix-grpc-store-clang-tidy-0.1.0-beta.1> auto_features: enabled nix-grpc-store-clang-tidy-0.1.0-beta.1> b_pch : false nix-grpc-store-clang-tidy-0.1.0-beta.1> bindir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/bin nix-grpc-store-clang-tidy-0.1.0-beta.1> buildtype : plain nix-grpc-store-clang-tidy-0.1.0-beta.1> includedir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/include nix-grpc-store-clang-tidy-0.1.0-beta.1> infodir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/info nix-grpc-store-clang-tidy-0.1.0-beta.1> libdir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/lib nix-grpc-store-clang-tidy-0.1.0-beta.1> libexecdir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/libexec nix-grpc-store-clang-tidy-0.1.0-beta.1> localedir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/locale nix-grpc-store-clang-tidy-0.1.0-beta.1> mandir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/share/man nix-grpc-store-clang-tidy-0.1.0-beta.1> prefix : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1 nix-grpc-store-clang-tidy-0.1.0-beta.1> sbindir : /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1/sbin nix-grpc-store-clang-tidy-0.1.0-beta.1> wrap_mode : nodownload nix-grpc-store-clang-tidy-0.1.0-beta.1> nix-grpc-store-clang-tidy-0.1.0-beta.1> Found ninja-1.13.2 at /nix/store/r8a159fqvj0mpczq0dq8d3dwdd2rsz8c-ninja-1.13.2/bin/ninja nix-grpc-store-clang-tidy-0.1.0-beta.1> mesonConfigurePhase: enabled\ parallel\ building nix-grpc-store-clang-tidy-0.1.0-beta.1> Running phase: buildPhase nix-grpc-store-clang-tidy-0.1.0-beta.1> [1/1] Generating nix_remote_proto with a custom command nix-grpc-store-clang-tidy-0.1.0-beta.1> [0/1] /nix/store/jaa89dphx07w3r26y7gh79a7b1mld5p4-meson-1.10.2/bin/meson --internal clangtidy /build/source /build/source/build --color always nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/client/plugin-loader.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/plugin-loader.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/plugin-loader.cc:10:10: error: 'cstdio' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 10 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/plugin-loader.cc:107:19: error: variable 'override' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 107 | if (const char *override = std::getenv("NIX_GRPC_PLUGIN_OVERRIDE")) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 108 | plugin = override; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | = nullptr nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/farm-client-test.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/farm-client-test.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:43:5: error: constructor does not initialize these fields: remote [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | std::optional remote; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 42 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | explicit Cache(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:61:24: error: method 'present' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | [[nodiscard]] auto present(const std::vector & keys) -> std::unordered_set nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:10: error: method 'publish' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:18: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:51: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:76: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:38: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:71: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:96: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:113:10: error: method 'completeRefs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 113 | void completeRefs(nix::Store & store, const nix::ValidPathInfo & info) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:17:8: error: constructor does not initialize these fields: url, tokenFile, clientCert, clientKey, pushArgv [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | struct Niks3Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | std::string url; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | std::string tokenFile; // bearer, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | std::string clientCert; // mTLS, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | PushProcess::Argv pushArgv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:40:5: error: constructor does not initialize these fields: baseUrl, bearer, clientCert, clientKey [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string baseUrl; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | std::shared_ptr bearer; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string clientCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | explicit Niks3Client(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:24: error: method 'post' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:29: error: 2 adjacent parameters of 'post' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:46: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:75: note: the last parameter in the range is 'body' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:52: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:61:5: error: constructor does not initialize these fields: argv, state, writeMutex, reader [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | explicit PushProcess(Argv argv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:10: error: method 'pushWait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:19: error: 2 adjacent parameters of 'pushWait' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:52: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:77: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:123:16: error: constructor does not initialize these fields: message, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | std::string status = "ok"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 127 | Signatures signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:130:9: error: constructor does not initialize these fields: sync, done [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | explicit Pending(size_t count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:136:16: error: constructor does not initialize these fields: status, message, path, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 136 | struct Ack nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 137 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 138 | std::string status; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 139 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 140 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | std::set signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:144:14: error: method 'ack' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 144 | auto ack(Ack msg) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:147:37: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | if (msg.status != "ok") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:14: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:49: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:162:14: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 162 | void fail(const std::string & message) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:171:14: error: method 'wait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | auto wait(const Cancelled & cancelled) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:184:16: error: constructor does not initialize these fields: left [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 184 | struct Inner nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | size_t left; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:193:12: error: constructor does not initialize these fields: stdinFd [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | nix::Pid pid; nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | std::shared_ptr stdinFd; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:206:10: error: method 'ensureChild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | void ensureChild(nix::Sync::WriteLock & lck) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:237:10: error: method 'readAcks' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | void readAcks(int acksFd) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:21:12: error: constructor does not initialize these fields: token [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string token; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:39:5: error: constructor does not initialize these fields: path, cached [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix::Sync cached; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | static auto mtime(const struct stat & info) -> struct timespec nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #ifdef __APPLE__ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | return info.st_mtimespec; nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #else nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | return info.st_mtim; nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #endif nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | explicit TokenFile(std::string path_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:46:10: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | auto get() -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:71:38: error: 2 adjacent parameters of 'collect' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | static auto collect(char * data, size_t size, size_t nmemb, void * userp) noexcept -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:71:45: note: the first parameter in the range is 'size' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | static auto collect(char * data, size_t size, size_t nmemb, void * userp) noexcept -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:71:58: note: the last parameter in the range is 'nmemb' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | static auto collect(char * data, size_t size, size_t nmemb, void * userp) noexcept -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:36: error: 2 adjacent parameters of 'makeProtocolVersion' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:49: note: the first parameter in the range is 'major' nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:64: note: the last parameter in the range is 'minor' nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:56: note: 'unsigned int' and 'int' may be implicitly converted nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:3:10: error: 'chrono' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 3 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:17:1: error: included header json_fwd.hpp is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:23:1: error: included header niks3-client.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #include "niks3-client.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | #include "http.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:37:5: error: constructor does not initialize these fields: base [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | std::string base; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | int failures = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | explicit Suite(std::string base) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:53:24: error: method 'log' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto log() const -> nlohmann::json nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:62:9: error: variable 'found' of type 'int' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | int found = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:148:29: error: 2 adjacent parameters of 'testCache' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 148 | void testCache(Suite & tst, const std::string & base, const std::string & mock) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:148:49: note: the first parameter in the range is 'base' nix-grpc-store-clang-tidy-0.1.0-beta.1> 148 | void testCache(Suite & tst, const std::string & base, const std::string & mock) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/farm-client-test.cc:148:75: note: the last parameter in the range is 'mock' nix-grpc-store-clang-tidy-0.1.0-beta.1> 148 | void testCache(Suite & tst, const std::string & base, const std::string & mock) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/scheduler-test.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/scheduler-test.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:3:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 3 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:46:20: error: variable 'minKey' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 3 | double minKey = ref.begin()->second; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = NAN nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:26: error: 4 adjacent parameters of 'hello' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:43: note: the first parameter in the range is 'addr' nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:141: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:49: note: 'int' and 'uint32_t' may be implicitly converted: 'int' -> 'uint32_t' (as 'unsigned int'), 'uint32_t' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:64: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:49: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:64: note: 'uint32_t' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | auto hello(Core & shard, std::string_view addr, uint32_t jobs, const std::vector & running = {}, std::vector features = {}, std::vector * superseded = nullptr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:75:64: note: 'uint32_t' and 'const int &' may be implicitly converted: 'uint32_t' (as 'unsigned int') -> 'const int &' (as 'int'), 'const int &' (as 'int') -> 'uint32_t' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:88:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 88 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:106:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 106 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:123:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:157:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 157 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:177:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:199:5: error: variable 'shard' of type 'Core' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 199 | Core shard; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:291:5: error: variable 'onBoth' of type 'int' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 291 | int onBoth = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:335:6: error: an exception may be thrown in function 'main' which should not throw exceptions [bugprone-exception-escape,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 335 | auto main() -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:134:13: note: frame #0: unhandled exception of type 'nix::Error' may be thrown in function 'set' here nix-grpc-store-clang-tidy-0.1.0-beta.1> 134 | throw nix::Error("IndexedHeap: id out of range"); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:35:13: note: frame #1: function 'testHeapAgainstMap' calls function 'set' here nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | heap.set(id, key); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-test.cc:337:5: note: frame #2: function 'main' calls function 'testHeapAgainstMap' here nix-grpc-store-clang-tidy-0.1.0-beta.1> 337 | testHeapAgainstMap(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/xfcc-test.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/xfcc-test.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:32:5: error: constructor does not initialize these fields: rest [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string_view rest; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | explicit Cursor(std::string_view input) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:47:10: error: method 'take' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | auto take() -> char nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:52:20: error: variable 'chr' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | char const chr = rest.front(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:58:10: error: method 'until' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | auto until(std::string_view stops) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:69:10: error: method 'remaining' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | auto remaining() -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:150:13: error: variable 'subjectCommonName' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | inline auto subjectCommonName(std::string_view value) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:197:10: error: method 'add' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | void add(std::string_view pattern) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:210:24: error: method 'matches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | [[nodiscard]] auto matches(const std::optional & peerCommonName) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/xfcc-test.cc:1:10: error: 'cassert' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 1 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/elector.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/elector.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:16:1: error: included header json_fwd.hpp is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 16 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:17:1: error: included header json.hpp is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:19:1: error: included header http.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | #include "http.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | #include "logfmt.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:30:8: error: constructor does not initialize these fields: stop, lead, buf [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | struct Reader nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | std::stop_token stop; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | std::function lead; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string buf; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:43:14: error: variable 'eol' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | for (size_t eol = 0; (eol = reader.buf.find('\n')) != std::string::npos;) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:63:1: error: constructor does not initialize these fields: onChange, thread [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | Elector::Elector(const Niks3Client & niks3_, std::function onChange_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/elector.cc:70:10: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | Elector::~Elector() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/elector.hh:6:10: error: 'chrono' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 6 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:17:8: error: constructor does not initialize these fields: url, tokenFile, clientCert, clientKey, pushArgv [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | struct Niks3Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | std::string url; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | std::string tokenFile; // bearer, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | std::string clientCert; // mTLS, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | PushProcess::Argv pushArgv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:40:5: error: constructor does not initialize these fields: baseUrl, bearer, clientCert, clientKey [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string baseUrl; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | std::shared_ptr bearer; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string clientCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | explicit Niks3Client(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:24: error: method 'post' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:29: error: 2 adjacent parameters of 'post' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:46: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:75: note: the last parameter in the range is 'body' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:52: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:61:5: error: constructor does not initialize these fields: argv, state, writeMutex, reader [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | explicit PushProcess(Argv argv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:10: error: method 'pushWait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:19: error: 2 adjacent parameters of 'pushWait' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:52: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:77: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:123:16: error: constructor does not initialize these fields: message, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | std::string status = "ok"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 127 | Signatures signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:130:9: error: constructor does not initialize these fields: sync, done [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | explicit Pending(size_t count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:136:16: error: constructor does not initialize these fields: status, message, path, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 136 | struct Ack nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 137 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 138 | std::string status; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 139 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 140 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | std::set signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:144:14: error: method 'ack' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 144 | auto ack(Ack msg) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:147:37: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | if (msg.status != "ok") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:14: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:49: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:162:14: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 162 | void fail(const std::string & message) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:171:14: error: method 'wait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | auto wait(const Cancelled & cancelled) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:184:16: error: constructor does not initialize these fields: left [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 184 | struct Inner nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | size_t left; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:193:12: error: constructor does not initialize these fields: stdinFd [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | nix::Pid pid; nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | std::shared_ptr stdinFd; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:206:10: error: method 'ensureChild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | void ensureChild(nix::Sync::WriteLock & lck) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:237:10: error: method 'readAcks' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | void readAcks(int acksFd) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:21:12: error: constructor does not initialize these fields: token [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string token; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:39:5: error: constructor does not initialize these fields: path, cached [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix::Sync cached; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | static auto mtime(const struct stat & info) -> struct timespec nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #ifdef __APPLE__ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | return info.st_mtimespec; nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #else nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | return info.st_mtim; nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #endif nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | explicit TokenFile(std::string path_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:46:10: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | auto get() -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/options.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/options.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:22:12: error: enum 'Role' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | enum class Role : std::uint8_t { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:51:7: error: constructor does not initialize these fields: rules, anonRole [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | class Acl nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | Role role; nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::vector rules; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | // Separate from the glob rules so '*' cannot grant anonymous access. nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | std::optional anonRole; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:53:12: error: constructor does not initialize these fields: pattern, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:70:10: error: method 'addRule' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | void addRule(std::string_view spec) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:95:24: error: method 'roleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | [[nodiscard]] auto roleFor(const std::optional & commonName) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:17:8: error: constructor does not initialize these fields: url, tokenFile, clientCert, clientKey, pushArgv [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | struct Niks3Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | std::string url; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | std::string tokenFile; // bearer, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | std::string clientCert; // mTLS, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | PushProcess::Argv pushArgv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:40:5: error: constructor does not initialize these fields: baseUrl, bearer, clientCert, clientKey [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string baseUrl; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | std::shared_ptr bearer; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string clientCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | explicit Niks3Client(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:24: error: method 'post' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:29: error: 2 adjacent parameters of 'post' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:46: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:75: note: the last parameter in the range is 'body' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:52: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:4:1: error: included header nix-compat.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 4 | #include "nix-compat.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 5 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:21:1: error: included header server_credentials.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:23:1: error: included header tls_credentials_options.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:26:1: error: included header file-system.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:27:1: error: included header strings.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:29:1: error: included header environment-variables.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:31:1: error: included header acl.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | #include "acl.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | #include "logfmt.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:36:1: error: included header xfcc.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | #include "xfcc.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:41:6: error: variable 'parseLogLevel' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | auto parseLogLevel(std::string_view value) -> LogLevel nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:65:39: error: 2 adjacent parameters of 'finishNiks3' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | void finishNiks3(Niks3Config & niks3, const std::string & tlsCert, const std::string & tlsKey) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:65:59: note: the first parameter in the range is 'tlsCert' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | void finishNiks3(Niks3Config & niks3, const std::string & tlsCert, const std::string & tlsKey) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:65:88: note: the last parameter in the range is 'tlsKey' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | void finishNiks3(Niks3Config & niks3, const std::string & tlsCert, const std::string & tlsKey) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:92:6: error: function 'parseOptions' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 92 | auto parseOptions(const std::vector & args) -> Options nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.cc:227:6: error: function 'makeServerCredentials' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 227 | auto makeServerCredentials(const Options & options) -> std::shared_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.hh:4:10: error: 'chrono' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 4 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:61:5: error: constructor does not initialize these fields: argv, state, writeMutex, reader [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | explicit PushProcess(Argv argv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:10: error: method 'pushWait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:19: error: 2 adjacent parameters of 'pushWait' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:52: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:77: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:123:16: error: constructor does not initialize these fields: message, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | std::string status = "ok"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 127 | Signatures signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:130:9: error: constructor does not initialize these fields: sync, done [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | explicit Pending(size_t count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:136:16: error: constructor does not initialize these fields: status, message, path, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 136 | struct Ack nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 137 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 138 | std::string status; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 139 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 140 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | std::set signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:144:14: error: method 'ack' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 144 | auto ack(Ack msg) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:147:37: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | if (msg.status != "ok") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:14: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:49: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:162:14: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 162 | void fail(const std::string & message) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:171:14: error: method 'wait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | auto wait(const Cancelled & cancelled) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:184:16: error: constructor does not initialize these fields: left [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 184 | struct Inner nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | size_t left; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:193:12: error: constructor does not initialize these fields: stdinFd [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | nix::Pid pid; nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | std::shared_ptr stdinFd; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:206:10: error: method 'ensureChild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | void ensureChild(nix::Sync::WriteLock & lck) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:237:10: error: method 'readAcks' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | void readAcks(int acksFd) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:21:12: error: constructor does not initialize these fields: token [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string token; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:39:5: error: constructor does not initialize these fields: path, cached [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix::Sync cached; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | static auto mtime(const struct stat & info) -> struct timespec nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #ifdef __APPLE__ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | return info.st_mtimespec; nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #else nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | return info.st_mtim; nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #endif nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | explicit TokenFile(std::string path_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:46:10: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | auto get() -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:32:5: error: constructor does not initialize these fields: rest [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string_view rest; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | explicit Cursor(std::string_view input) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:47:10: error: method 'take' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | auto take() -> char nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:52:20: error: variable 'chr' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | char const chr = rest.front(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:58:10: error: method 'until' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | auto until(std::string_view stops) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:69:10: error: method 'remaining' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | auto remaining() -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:150:13: error: variable 'subjectCommonName' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | inline auto subjectCommonName(std::string_view value) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:192:7: error: constructor does not initialize these fields: patterns [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 192 | class TrustedProxies nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | std::vector patterns; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:197:10: error: method 'add' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | void add(std::string_view pattern) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:210:24: error: method 'matches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | [[nodiscard]] auto matches(const std::optional & peerCommonName) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/auth.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/auth.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:22:12: error: enum 'Role' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | enum class Role : std::uint8_t { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:51:7: error: constructor does not initialize these fields: rules, anonRole [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | class Acl nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | Role role; nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::vector rules; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | // Separate from the glob rules so '*' cannot grant anonymous access. nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | std::optional anonRole; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:53:12: error: constructor does not initialize these fields: pattern, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:70:10: error: method 'addRule' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | void addRule(std::string_view spec) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:95:24: error: method 'roleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | [[nodiscard]] auto roleFor(const std::optional & commonName) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.cc:17:1: error: included header oidc.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | #include "oidc.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | #include "xfcc.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.cc:18:1: error: included header xfcc.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | #include "xfcc.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.cc:25:12: error: method 'identify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | auto Auth::identify(const grpc::ServerContextBase & context) const -> Caller nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.cc:50:12: error: method 'authorize' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 50 | auto Auth::authorize(const Caller & caller, std::string_view method, Role minRole) -> grpc::Status nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.cc:78:12: error: method 'authorize' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | auto Auth::authorize(const Caller & caller, std::string_view method, Role minRole, uint32_t buildMode) -> grpc::Status nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/auth.hh:5:10: error: 'cstdint' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 5 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/auth.hh:19:8: error: constructor does not initialize these fields: role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | struct Caller nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string name = "-"; // cert CN or oidc::, for logs and metrics nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::optional role; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/auth.hh:21:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:60:8: error: constructor does not initialize these fields: subject, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | struct Identity nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | std::string subject; // "oidc::" nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | std::optional role; // nullopt: verified but no rule matched nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:76:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:26: error: 2 adjacent parameters of 'providerFrom' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:46: note: the first parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:65: note: the last parameter in the range is 'prov' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:25: error: 2 adjacent parameters of 'lookupClaim' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:38: note: the first parameter in the range is 'claims' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:63: note: the last parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:251:8: error: constructor does not initialize these fields: kid, kty, crv, pem [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 251 | struct Jwk nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 252 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 253 | std::string kid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | std::string kty; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | std::string crv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | std::string pem; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:286:31: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | if (jwk.kty == "RSA") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:10: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:37: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:290:62: note: clone 2 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 290 | } else if (jwk.kty == "OKP" && jwk.crv == "Ed25519") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:294:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:300:8: error: constructor does not initialize these fields: at [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | struct FixedClock nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 302 | std::chrono::system_clock::time_point at; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:347:12: error: constructor does not initialize these fields: identity, error [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 347 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | std::optional identity; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | std::string error; // for logs, not for the client nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:355:5: error: constructor does not initialize these fields: refetchOnMiss, keys [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 355 | explicit Verifier(Config cfg, std::chrono::seconds refetchOnMiss = defaultRefetchOnMiss) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:10: error: method 'verify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:17: error: 2 adjacent parameters of 'verify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:37: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:82: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:44: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:377:12: error: constructor does not initialize these fields: lock, keys, fetched [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 377 | struct KeySet nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 378 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 379 | std::mutex lock; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 380 | std::vector keys; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 381 | // steady_clock starts at boot on Linux, so its epoch is not "long ago". nix-grpc-store-clang-tidy-0.1.0-beta.1> 382 | std::optional fetched; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:397:24: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 397 | [[nodiscard]] auto get(const Provider & provider, const std::string & url) const -> Json nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:417:24: error: method 'fetchKeys' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 417 | [[nodiscard]] auto fetchKeys(const Provider & provider) const -> std::vector nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:9: error: 2 adjacent parameters of 'fetchDue' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:62: note: the first parameter in the range is 'fetched' nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:443:47: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:10: error: method 'candidates' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:62: error: 2 adjacent parameters of 'candidates' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:78: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:59: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:21: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:10: error: method 'doVerify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:19: error: 2 adjacent parameters of 'doVerify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:39: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:84: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:32:5: error: constructor does not initialize these fields: rest [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string_view rest; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | explicit Cursor(std::string_view input) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:47:10: error: method 'take' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | auto take() -> char nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:52:20: error: variable 'chr' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | char const chr = rest.front(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:58:10: error: method 'until' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | auto until(std::string_view stops) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:69:10: error: method 'remaining' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | auto remaining() -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:150:13: error: variable 'subjectCommonName' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | inline auto subjectCommonName(std::string_view value) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:192:7: error: constructor does not initialize these fields: patterns [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 192 | class TrustedProxies nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | std::vector patterns; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:197:10: error: method 'add' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | void add(std::string_view pattern) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:210:24: error: method 'matches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | [[nodiscard]] auto matches(const std::optional & peerCommonName) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/oidc-test.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/oidc-test.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:22:12: error: enum 'Role' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | enum class Role : std::uint8_t { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:51:7: error: constructor does not initialize these fields: rules, anonRole [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | class Acl nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | Role role; nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::vector rules; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | // Separate from the glob rules so '*' cannot grant anonymous access. nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | std::optional anonRole; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:53:12: error: constructor does not initialize these fields: pattern, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:70:10: error: method 'addRule' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | void addRule(std::string_view spec) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:95:24: error: method 'roleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | [[nodiscard]] auto roleFor(const std::optional & commonName) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:60:8: error: constructor does not initialize these fields: subject, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | struct Identity nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | std::string subject; // "oidc::" nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | std::optional role; // nullopt: verified but no rule matched nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:76:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:26: error: 2 adjacent parameters of 'providerFrom' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:46: note: the first parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:65: note: the last parameter in the range is 'prov' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:25: error: 2 adjacent parameters of 'lookupClaim' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:38: note: the first parameter in the range is 'claims' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:63: note: the last parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:251:8: error: constructor does not initialize these fields: kid, kty, crv, pem [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 251 | struct Jwk nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 252 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 253 | std::string kid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | std::string kty; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | std::string crv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | std::string pem; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:286:31: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | if (jwk.kty == "RSA") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:10: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:37: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:290:62: note: clone 2 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 290 | } else if (jwk.kty == "OKP" && jwk.crv == "Ed25519") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:294:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:300:8: error: constructor does not initialize these fields: at [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | struct FixedClock nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 302 | std::chrono::system_clock::time_point at; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:347:12: error: constructor does not initialize these fields: identity, error [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 347 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | std::optional identity; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | std::string error; // for logs, not for the client nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:355:5: error: constructor does not initialize these fields: refetchOnMiss, keys [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 355 | explicit Verifier(Config cfg, std::chrono::seconds refetchOnMiss = defaultRefetchOnMiss) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:10: error: method 'verify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:17: error: 2 adjacent parameters of 'verify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:37: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:82: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:44: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:377:12: error: constructor does not initialize these fields: lock, keys, fetched [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 377 | struct KeySet nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 378 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 379 | std::mutex lock; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 380 | std::vector keys; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 381 | // steady_clock starts at boot on Linux, so its epoch is not "long ago". nix-grpc-store-clang-tidy-0.1.0-beta.1> 382 | std::optional fetched; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:397:24: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 397 | [[nodiscard]] auto get(const Provider & provider, const std::string & url) const -> Json nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:417:24: error: method 'fetchKeys' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 417 | [[nodiscard]] auto fetchKeys(const Provider & provider) const -> std::vector nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:9: error: 2 adjacent parameters of 'fetchDue' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:62: note: the first parameter in the range is 'fetched' nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:443:47: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:10: error: method 'candidates' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:62: error: 2 adjacent parameters of 'candidates' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:78: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:59: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:21: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:10: error: method 'doVerify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:19: error: 2 adjacent parameters of 'doVerify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:39: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:84: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:4:10: error: 'chrono' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 4 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:25:1: error: included header json_fwd.hpp is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:27:1: error: included header base-n.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:84:12: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 84 | enum class Kind : std::uint8_t { ec, rsa, pss, ed }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:86:8: error: constructor does not initialize these fields: pkey, kind, alg, kid [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | struct Key nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 88 | std::shared_ptr pkey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 89 | Kind kind; nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | std::string alg; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | std::string kid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:95:9: error: pointee of variable 'raw' of type 'EVP_PKEY *' (aka 'struct evp_pkey_st *') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | EVP_PKEY * raw = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:131:20: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | size_t len = pub.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:160:29: error: 2 adjacent parameters of 'sign' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 160 | [[nodiscard]] auto sign(const Json & claims, const std::string & headerAlg = "") const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:160:42: note: the first parameter in the range is 'claims' nix-grpc-store-clang-tidy-0.1.0-beta.1> 160 | [[nodiscard]] auto sign(const Json & claims, const std::string & headerAlg = "") const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:160:70: note: the last parameter in the range is 'headerAlg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 160 | [[nodiscard]] auto sign(const Json & claims, const std::string & headerAlg = "") const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:210:18: error: 2 adjacent parameters of 'writeConfig' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | auto writeConfig(const std::string & dir, const std::string & base) -> void nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:210:38: note: the first parameter in the range is 'dir' nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | auto writeConfig(const std::string & dir, const std::string & base) -> void nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:210:63: note: the last parameter in the range is 'base' nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | auto writeConfig(const std::string & dir, const std::string & base) -> void nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:233:10: error: 2 adjacent parameters of 'run' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | auto run(const std::string & dir, const std::string & base) -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:233:30: note: the first parameter in the range is 'dir' nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | auto run(const std::string & dir, const std::string & base) -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:233:55: note: the last parameter in the range is 'base' nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | auto run(const std::string & dir, const std::string & base) -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:235:5: error: variable 'check' of type 'Checks' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 235 | Checks check; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:266:60: error: '*' has higher precedence than '+'; add parentheses to explicitly specify the order of operations [readability-math-missing-parentheses,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 266 | check(!Verifier::fetchDue(justBooted, justBooted + onMiss * 2, true, onMiss), "known kid uses cached keys"); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ( ) nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/oidc-test.cc:365:29: error: parameter 'argv' is unused [misc-unused-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | auto main(int argc, char ** argv) -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*argv*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/client/channel.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> [1/1] (1/2) Processing file /build/source/src/client/channel.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/channel.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> [1/1] (2/2) Processing file /build/source/src/client/channel.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/channel.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:16:1: error: included header bio.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 16 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:18:1: error: included header pem.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:24:1: error: included header file-system.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:41:6: error: function 'readValidCert' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | auto readValidCert(const std::string &path) -> std::string { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:64:6: error: function 'defaultCaCert' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | auto defaultCaCert() -> std::string { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:76:6: error: function 'defaultClientCred' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | auto defaultClientCred(const char *envVar, const std::string &fileName) -> std::string { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:81:53: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | if (auto dataHome = nix::getEnv("XDG_DATA_HOME")) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:83:4: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | } else if (auto home = nix::getEnv("HOME")) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.cc:83:47: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | } else if (auto home = nix::getEnv("HOME")) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:5:10: error: 'exception' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 5 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:46:3: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | explicit StaticHeaders(std::shared_ptr headers) : headers(std::move(headers)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:62:5: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | explicit Factory(Headers hdrs) : headers(std::make_shared(std::move(hdrs))) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | auto CreateClientInterceptor(grpc::experimental::ClientRpcInfo * /*info*/) nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | -> grpc::experimental::Interceptor * override { nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | return new StaticHeaders(headers); // NOLINT(cppcoreguidelines-owning-memory): gRPC deletes it nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::shared_ptr headers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:80:3: error: constructor does not initialize these fields: path [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 79 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | explicit TokenFileCredentials(std::string path) : path(std::move(path)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:85:8: error: method 'GetMetadata' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 85 | auto GetMetadata(grpc::string_ref /*serviceUrl*/, grpc::string_ref /*methodName*/, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:87:64: error: pointer parameter 'metadata' can be pointer to const [readability-non-const-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | std::multimap * metadata) -> grpc::Status override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:95:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | } catch (std::exception & err) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/dispatcher-bench.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/dispatcher-bench.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:45:12: error: constructor does not initialize these fields: defaultSystem, present [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::string defaultSystem; // for Want/Hello with empty or "builtin" system nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | PresentFn present; // unset: nothing is ever Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:64:12: error: constructor does not initialize these fields: send [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | struct Client nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | sched::ClientId id = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | ClientSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:80:12: error: constructor does not initialize these fields: send, id [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | WorkerSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | std::optional id; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:95:5: error: function 'sendLock' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | ABSL_LOCK_RETURNED(mutex) auto sendLock() const -> const absl::Mutex & nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/0gyk1hdw37b47p2pra40hjf7xzl312lf-abseil-cpp-20260107.1-dev/include/absl/base/thread_annotations.h:170:31: note: expanded from macro 'ABSL_LOCK_RETURNED' nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | #define ABSL_LOCK_RETURNED(x) __attribute__((lock_returned(x))) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:77:9: error: constructor does not initialize these fields: method, start [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | std::string method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | prometheus::Histogram * hist = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | std::chrono::steady_clock::time_point start; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 74 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | // NOLINTNEXTLINE(bugprone-easily-swappable-parameters): method, then phase. nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | Phase(Metrics & metrics, std::string method, const std::string & phase) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:145:10: error: method 'buildInfo' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | void buildInfo( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:9: error: 4 adjacent parameters of 'buildInfo' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:29: note: the first parameter in the range is 'version' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:114: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:156:10: error: method 'buildSlots' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 156 | void buildSlots(unsigned count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: error: 4 adjacent parameters of 'schedSystem' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:56: note: the first parameter in the range is 'system' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:127: note: the last parameter in the range is 'count' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:205:5: error: constructor does not initialize these fields: exposer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | explicit Metrics(const std::string & listen) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:19: error: 2 adjacent parameters of 'countRpc' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:39: note: the first parameter in the range is 'method' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:67: note: the last parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: error: 3 adjacent parameters of 'countTunnelBytes' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:47: note: the first parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:86: note: the last parameter in the range is 'bytesOut' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: error: 3 adjacent parameters of 'countNarBytes' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:44: note: the first parameter in the range is 'direction' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:96: note: the last parameter in the range is 'bytes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/dispatcher-bench.cc:26:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/dispatcher.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/dispatcher.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:21:1: error: included header strings.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:22:1: error: included header types.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:38:1: error: constructor does not initialize these fields: clients, workers, statsAtMs, lookupQueue, lookupThreads [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | Dispatcher::Dispatcher(Config config_, Metrics & metrics) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:64:9: error: variable 'job' of type 'LookupJob' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | LookupJob job; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:102:18: error: variable 'afterUnlock' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 102 | void Dispatcher::afterUnlock(std::function func) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:112:18: error: variable 'debugLog' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 112 | void Dispatcher::debugLog(std::initializer_list fields) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:120:18: error: method 'systemFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 120 | auto Dispatcher::systemFor(std::string_view system) const -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:135:18: error: method 'lookup' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 135 | auto Dispatcher::lookup(const nix::remote::ClientMsgs & msgs) const -> std::vector nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:18: error: method 'revokeOn' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:27: error: 2 adjacent parameters of 'revokeOn' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:43: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:68: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:27: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:48: note: 'sched::WorkerId' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | void Dispatcher::revokeOn(sched::WorkerId wid, const std::string & drvPath) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:262:48: note: 'sched::WorkerId' and 'const int &' may be implicitly converted: 'sched::WorkerId' (as 'unsigned int') -> 'const int &' (as 'int'), 'const int &' (as 'int') -> 'sched::WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:306:18: error: method 'clientMsgs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 306 | void Dispatcher::clientMsgs(const ClientPtr & client, const nix::remote::ClientMsgs & msgs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:308:16: error: variable 'needs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 308 | const bool needs = nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 309 | config.present && std::ranges::any_of(msgs.msgs(), [](const nix::remote::ClientMsg & msg) -> bool { nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | = false nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.cc:395:18: error: method 'onCancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | void Dispatcher::onCancel(Client & client, const nix::remote::Cancel & cancel) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/dispatcher.hh:10:10: error: 'map' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 10 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/dispatcher.hh:45:12: error: constructor does not initialize these fields: defaultSystem, present [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::string defaultSystem; // for Want/Hello with empty or "builtin" system nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | PresentFn present; // unset: nothing is ever Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/dispatcher.hh:64:12: error: constructor does not initialize these fields: send [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | struct Client nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | sched::ClientId id = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | ClientSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/dispatcher.hh:80:12: error: constructor does not initialize these fields: send, id [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | WorkerSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | std::optional id; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/dispatcher.hh:95:5: error: function 'sendLock' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | ABSL_LOCK_RETURNED(mutex) auto sendLock() const -> const absl::Mutex & nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/0gyk1hdw37b47p2pra40hjf7xzl312lf-abseil-cpp-20260107.1-dev/include/absl/base/thread_annotations.h:170:31: note: expanded from macro 'ABSL_LOCK_RETURNED' nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | #define ABSL_LOCK_RETURNED(x) __attribute__((lock_returned(x))) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:77:9: error: constructor does not initialize these fields: method, start [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | std::string method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | prometheus::Histogram * hist = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | std::chrono::steady_clock::time_point start; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 74 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | // NOLINTNEXTLINE(bugprone-easily-swappable-parameters): method, then phase. nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | Phase(Metrics & metrics, std::string method, const std::string & phase) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:145:10: error: method 'buildInfo' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | void buildInfo( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:9: error: 4 adjacent parameters of 'buildInfo' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:29: note: the first parameter in the range is 'version' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:114: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:156:10: error: method 'buildSlots' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 156 | void buildSlots(unsigned count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: error: 4 adjacent parameters of 'schedSystem' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:56: note: the first parameter in the range is 'system' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:127: note: the last parameter in the range is 'count' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:205:5: error: constructor does not initialize these fields: exposer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | explicit Metrics(const std::string & listen) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:19: error: 2 adjacent parameters of 'countRpc' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:39: note: the first parameter in the range is 'method' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:67: note: the last parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: error: 3 adjacent parameters of 'countTunnelBytes' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:47: note: the first parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:86: note: the last parameter in the range is 'bytesOut' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: error: 3 adjacent parameters of 'countNarBytes' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:44: note: the first parameter in the range is 'direction' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:96: note: the last parameter in the range is 'bytes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/backend.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/backend.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:52:24: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | if (type == 0) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:55:10: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | } else if (type == 1) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:55:31: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | } else if (type == 1) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:66:8: error: constructor does not initialize these fields: text [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | struct BuildEvent nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:68:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:22:1: error: included header derived-path.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:23:1: error: included header outputs-spec.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:31:1: error: included header file-descriptor.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:33:1: error: included header unix-domain-socket.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:77:16: error: method 'connect' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | auto Backends::connect(nix::Store & store) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:88:16: error: method 'forBuild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 88 | auto Backends::forBuild(Cancelled cancelled, nix::Store & localStore) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:120:16: error: method 'storedBuild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 120 | auto Backends::storedBuild( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> 121 | Cancelled cancelled, nix-grpc-store-clang-tidy-0.1.0-beta.1> 122 | nix::Store & localStore, nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | const nix::StorePath & drvPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | nix::BuildMode mode, nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | Limits limits, nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | const BuildEventSink & sendLogLine) const -> nix::BuildResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:123:28: error: parameter 'drvPath' is unused [misc-unused-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | const nix::StorePath & drvPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*drvPath*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.cc:141:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:5:10: error: 'csignal' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 5 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:53:8: error: constructor does not initialize these fields: socketPath [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Backends nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string socketPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:82:5: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | if (event.kind == BuildEvent::Kind::phase) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:84:7: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 84 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:36: error: 2 adjacent parameters of 'makeProtocolVersion' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:49: note: the first parameter in the range is 'major' nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:64: note: the last parameter in the range is 'minor' nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:72:56: note: 'unsigned int' and 'int' may be implicitly converted nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | constexpr auto makeProtocolVersion(unsigned int major, uint8_t minor) -> V { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/path-info-wire.hh:24:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/tests/scheduler-grpc-bench.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/tests/scheduler-grpc-bench.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:64:12: error: constructor does not initialize these fields: send [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | struct Client nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | sched::ClientId id = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | ClientSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:80:12: error: constructor does not initialize these fields: send, id [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | WorkerSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | std::optional id; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:95:5: error: function 'sendLock' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | ABSL_LOCK_RETURNED(mutex) auto sendLock() const -> const absl::Mutex & nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/0gyk1hdw37b47p2pra40hjf7xzl312lf-abseil-cpp-20260107.1-dev/include/absl/base/thread_annotations.h:170:31: note: expanded from macro 'ABSL_LOCK_RETURNED' nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | #define ABSL_LOCK_RETURNED(x) __attribute__((lock_returned(x))) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:77:9: error: constructor does not initialize these fields: method, start [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | std::string method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | prometheus::Histogram * hist = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | std::chrono::steady_clock::time_point start; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 74 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | // NOLINTNEXTLINE(bugprone-easily-swappable-parameters): method, then phase. nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | Phase(Metrics & metrics, std::string method, const std::string & phase) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:145:10: error: method 'buildInfo' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | void buildInfo( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:9: error: 4 adjacent parameters of 'buildInfo' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:29: note: the first parameter in the range is 'version' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:114: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:156:10: error: method 'buildSlots' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 156 | void buildSlots(unsigned count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: error: 4 adjacent parameters of 'schedSystem' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:56: note: the first parameter in the range is 'system' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:127: note: the last parameter in the range is 'count' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' may be implicitly converted: 'const int &' (as 'int') -> 'size_t' (as 'unsigned long'), 'size_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:205:5: error: constructor does not initialize these fields: exposer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | explicit Metrics(const std::string & listen) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:19: error: 2 adjacent parameters of 'countRpc' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:39: note: the first parameter in the range is 'method' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:67: note: the last parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: error: 3 adjacent parameters of 'countTunnelBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:47: note: the first parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:86: note: the last parameter in the range is 'bytesOut' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: error: 3 adjacent parameters of 'countNarBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:44: note: the first parameter in the range is 'direction' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:96: note: the last parameter in the range is 'bytes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:28:8: error: constructor does not initialize these fields: queue [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | struct SendQueue nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | // About a minute of Expects at full rate. Beyond it the peer is stuck. nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | static constexpr size_t limit = 1U << 16U; nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | // Messages per Write. nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | static constexpr int maxBatch = 1024; nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | // Leaf lock, may be taken inside Dispatcher::mutex. nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | absl::Mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::deque queue ABSL_GUARDED_BY(mutex); nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:58:5: error: constructor does not initialize these fields: sendq [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | explicit SchedReactorBase(grpc::CallbackServerContext * ctx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:69:13: error: variable 'kick' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | bool kick = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:153:9: error: variable 'have' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 153 | bool have = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:183:9: error: variable 'fin' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 183 | bool fin = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:206:5: error: constructor does not initialize these fields: client [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | ScheduleReactor(grpc::CallbackServerContext * ctx, Dispatcher & disp) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:226:18: error: member 'disp' of type 'Dispatcher &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 226 | Dispatcher & disp; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:255:18: error: member 'disp' of type 'Dispatcher &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | Dispatcher & disp; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../tests/scheduler-grpc-bench.cc:18:10: error: 'atomic' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/client/build.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/build.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:33:1: error: included header derived-path.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:37:1: error: included header store-open.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:40:1: error: included header finally.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:41:1: error: included header repair-flag.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 42 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:49:1: error: included header nix_remote.grpc.pb.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 49 | #include "nix_remote.grpc.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 50 | #include "nix_remote.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:63:17: error: method 'uploadDrvClosure' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | void GrpcStore::uploadDrvClosure(Store & evalStore, const StorePath & drvPath, const Metadata & headers) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:64:16: error: variable 'closure' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | StorePathSet closure; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:67:16: error: variable 'missing' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | StorePathSet missing; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:147:5: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | printError("%s: %s, asking the scheduler again", job.drvPath.to_string(), firstLine(status.error_message())); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:158:17: error: method 'localEvalStore' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 158 | auto GrpcStore::localEvalStore(const StorePathSet & drvPaths) -> std::shared_ptr { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:170:19: error: constructor does not initialize these fields: mode, mutex, cv, ready, wantable, remaining [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | struct GrpcStore::Run { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | GrpcStore & store; nix-grpc-store-clang-tidy-0.1.0-beta.1> 172 | BuildMode mode; nix-grpc-store-clang-tidy-0.1.0-beta.1> 173 | Store & evalStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | std::map & jobs; nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | std::condition_variable cv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | std::deque ready; // assigned, cached, lost or dep-failed: a thread can finish it nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | std::deque wantable; // inputs done, Want not yet sent nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | size_t remaining; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:171:15: error: member 'store' of type 'GrpcStore &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | GrpcStore & store; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:173:11: error: member 'evalStore' of type 'Store &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 173 | Store & evalStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:174:30: error: member 'jobs' of type 'int &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | std::map & jobs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:185:8: error: method 'next' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | auto next() -> Job * { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:212:5: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 212 | debug("grpc: want %s", job.drvPath.to_string()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:369:24: note: expanded from macro 'debug' nix-grpc-store-clang-tidy-0.1.0-beta.1> 369 | #define debug(args...) printMsg(lvlDebug, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:306:9: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 306 | } catch (Interrupted &) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:310:9: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 310 | printError("%s: %s", job->drvPath.to_string(), err.what()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:336:22: error: method 'cachedResult' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 336 | [[nodiscard]] auto cachedResult(const Job & job) const -> BuildResult { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:347:8: error: method 'onMsgs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 347 | void onMsgs(const remote::SchedMsgs & msgs) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:358:11: error: variable 'job' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 358 | Job * job = found == byName.end() ? nullptr : found->second; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = nullptr nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:370:7: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 370 | debug("grpc: assigned %s -> %s", name, msg.assigned().worker_addr()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:369:24: note: expanded from macro 'debug' nix-grpc-store-clang-tidy-0.1.0-beta.1> 369 | #define debug(args...) printMsg(lvlDebug, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:498:5: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 498 | debug("grpc: scheduler at %s restarting, reconnecting", where); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:369:24: note: expanded from macro 'debug' nix-grpc-store-clang-tidy-0.1.0-beta.1> 369 | #define debug(args...) printMsg(lvlDebug, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:500:5: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 500 | printError("scheduler at %s: %s, reconnecting", where, GrpcStore::firstLine(status.error_message())); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:507:17: error: method 'scheduleUntilDone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 507 | auto GrpcStore::scheduleUntilDone(Run & run, const Metadata & headers, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:507:46: error: 2 adjacent parameters of 'scheduleUntilDone' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 507 | auto GrpcStore::scheduleUntilDone(Run & run, const Metadata & headers, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 508 | const std::function & setCtx) -> grpc::Status { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:507:63: note: the first parameter in the range is 'headers' nix-grpc-store-clang-tidy-0.1.0-beta.1> 507 | auto GrpcStore::scheduleUntilDone(Run & run, const Metadata & headers, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:508:86: note: the last parameter in the range is 'setCtx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 508 | const std::function & setCtx) -> grpc::Status { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:518:5: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 518 | debug("grpc: Schedule stream open, %d jobs", run.jobs.size()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:369:24: note: expanded from macro 'debug' nix-grpc-store-clang-tidy-0.1.0-beta.1> 369 | #define debug(args...) printMsg(lvlDebug, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:539:17: error: variable 'runJobs' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | void GrpcStore::runJobs(std::map & jobs, BuildMode buildMode, Store & evalStore) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:588:18: error: variable 'drvs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 588 | StorePathSet drvs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:606:16: error: variable 'opaque' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 606 | StorePathSet opaque; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:652:17: error: method 'basicForFarm' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 652 | auto GrpcStore::basicForFarm(Store & evalStore, const StorePath & drvPath, const Derivation & full) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:686:16: error: variable 'tops' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 686 | StorePathSet tops; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:693:16: error: variable 'outputs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 693 | StorePathSet outputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:707:16: error: variable 'valid' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 707 | StorePathSet valid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:716:17: error: method 'loadJobs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void GrpcStore::loadJobs(const std::vector & reqs, Store & evalStore, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/build.cc:764:17: error: variable 'throwOnFailedBuilds' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 764 | void GrpcStore::throwOnFailedBuilds(std::vector & results) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:46:3: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | explicit StaticHeaders(std::shared_ptr headers) : headers(std::move(headers)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:62:5: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | explicit Factory(Headers hdrs) : headers(std::make_shared(std::move(hdrs))) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | auto CreateClientInterceptor(grpc::experimental::ClientRpcInfo * /*info*/) nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | -> grpc::experimental::Interceptor * override { nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | return new StaticHeaders(headers); // NOLINT(cppcoreguidelines-owning-memory): gRPC deletes it nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::shared_ptr headers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:80:3: error: constructor does not initialize these fields: path [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 79 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | explicit TokenFileCredentials(std::string path) : path(std::move(path)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:85:8: error: method 'GetMetadata' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 85 | auto GetMetadata(grpc::string_ref /*serviceUrl*/, grpc::string_ref /*methodName*/, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:87:64: error: pointer parameter 'metadata' can be pointer to const [readability-non-const-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | std::multimap * metadata) -> grpc::Status override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:95:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | } catch (std::exception & err) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:54:5: error: constructor does not initialize these fields: mutex, grown, failure [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | std::condition_variable grown; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 49 | uint64_t written = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 50 | bool eof = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | std::exception_ptr failure; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | NarSpool() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:95:10: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | void fail(const std::exception_ptr & cause) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:142:88: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 142 | inline void demuxNarFrames(Reader & reader, const std::vector> & targets) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:172:5: error: constructor does not initialize these fields: authority, connections, narMutex, pending, narSizes [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 172 | NarFetcher( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:173:54: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 173 | std::function()> channelFactory, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:10: error: method 'recordOrder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:22: error: 2 adjacent parameters of 'recordOrder' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:50: note: the first parameter in the range is 'order' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:92: note: the last parameter in the range is 'sizes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:224:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | ~NarFetcher() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:233:11: error: constructor does not initialize these fields: stub, reader, thread [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | class Session nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 234 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 235 | friend class NarFetcher; nix-grpc-store-clang-tidy-0.1.0-beta.1> 236 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | std::unique_ptr stub; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 238 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 239 | std::unique_ptr> reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 240 | std::vector> targets; nix-grpc-store-clang-tidy-0.1.0-beta.1> 241 | std::jthread thread; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:243:14: error: method 'run' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 243 | void run() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:254:15: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:272:24: error: method 'narSizeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | [[nodiscard]] auto narSizeOf(const nix::StorePath & path) const -> uint64_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:279:10: error: method 'startPending' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 279 | void startPending() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:304:10: error: method 'startSession' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 304 | void startSession(const std::vector & paths) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:6:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 6 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:201:5: error: function 'getReference' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 201 | auto getReference() const -> StoreReference override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:212:5: error: function 'openStore' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 212 | auto openStore() const -> ref override; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:256:5: error: function 'connectHint' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | auto connectHint(const std::string & msg) const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:332:9: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 332 | printError("%s: %s, retrying", config->authority.to_string(), firstLine(status.error_message())); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:352:9: error: constructor does not initialize these fields: evalStore [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | std::shared_ptr evalStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | ref inner; nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 351 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 352 | GrpcBuilder(GrpcStore * store, std::shared_ptr evalStore, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:7: error: constructor does not initialize these fields: text, fields, act [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 405 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 406 | std::vector fields; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 407 | std::optional act; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 408 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 409 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:24: error: 2 adjacent parameters of 'BuildLogActivity' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:36: note: the first parameter in the range is 'text' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:69: note: the last parameter in the range is 'fields' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:420:9: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 420 | if (msg.has_log_line()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:422:11: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 422 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:466:12: error: constructor does not initialize these fields: dependants, inputs, failedInput, result, workerAddr, redirectAddr, unplaceableSince, unplaceableReason [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 466 | struct Job { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 467 | StorePath drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> 468 | BasicDerivation drv; nix-grpc-store-clang-tidy-0.1.0-beta.1> 469 | std::vector dependants; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 470 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 471 | size_t waiting = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 472 | uint64_t cpHintMs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 473 | unsigned bounced = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 474 | std::optional failedInput; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 475 | std::optional result; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 476 | // Set by the reader thread, consumed by a build thread. nix-grpc-store-clang-tidy-0.1.0-beta.1> 477 | std::string workerAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | // A second Assigned while building: the scheduler moved the drv to a nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | // worker that was already at it. Followed when the current one bounces. nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::string redirectAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:557:12: error: constructor does not initialize these fields: stream, reader, writer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 557 | struct Connection : RemoteStore::Connection nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 558 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 559 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 560 | friend struct GrpcStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> 561 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 562 | // RemoteStore::Connection speaks through FdSink/FdSource, so bridge the nix-grpc-store-clang-tidy-0.1.0-beta.1> 563 | // gRPC stream to a pair of pipes with pump threads. This keeps the nix-grpc-store-clang-tidy-0.1.0-beta.1> 564 | // blocking, ordered semantics the worker protocol relies on without nix-grpc-store-clang-tidy-0.1.0-beta.1> 565 | // reimplementing Source/Sink on top of gRPC. nix-grpc-store-clang-tidy-0.1.0-beta.1> 566 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 567 | std::unique_ptr stream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 568 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 569 | Pipe toRemote; // plugin writes → reader thread sends over gRPC nix-grpc-store-clang-tidy-0.1.0-beta.1> 570 | Pipe fromRemote; // writer thread receives from gRPC → plugin reads nix-grpc-store-clang-tidy-0.1.0-beta.1> 571 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 572 | std::jthread reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:613:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | ~GrpcStore() override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:619:24: error: rvalue reference parameter 'pathsToCopy' is never moved from inside the function body [cppcoreguidelines-rvalue-reference-param-not-moved,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 619 | PathsSource && pathsToCopy, Activity & act, RepairFlag repair, CheckSigsFlag checkSigs) override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:633:9: error: constructor does not initialize these fields: upstream [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 629 | std::unique_ptr upstream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 630 | AutoCloseFD fd; nix-grpc-store-clang-tidy-0.1.0-beta.1> 631 | bool complete = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 632 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 633 | explicit ReplayableNar(std::unique_ptr src) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:645:17: error: variable 'tee' of type 'LambdaSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 645 | LambdaSink tee([&](std::string_view data) -> void { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:652:23: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 652 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:667:13: error: variable 'replay' of type 'FdSource' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 667 | FdSource replay(fd.get()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/path-info-wire.hh:24:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:27: error: 2 adjacent parameters of 'readCoalesced' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:31: note: the first parameter in the range is 'sourceFd' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:57: note: the last parameter in the range is 'buf' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:72:19: error: variable 'ready' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | int const ready = ::poll(&pollFd, 1, got == 0 ? -1 : 0); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:52: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:59: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:90:41: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | return static_cast(got); // EOF; caller sees short (possibly zero) batch nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:48: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:55: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:97:33: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | return static_cast(got); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/client/store.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/store.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:46:3: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | explicit StaticHeaders(std::shared_ptr headers) : headers(std::move(headers)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:62:5: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | explicit Factory(Headers hdrs) : headers(std::make_shared(std::move(hdrs))) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | auto CreateClientInterceptor(grpc::experimental::ClientRpcInfo * /*info*/) nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | -> grpc::experimental::Interceptor * override { nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | return new StaticHeaders(headers); // NOLINT(cppcoreguidelines-owning-memory): gRPC deletes it nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::shared_ptr headers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:80:3: error: constructor does not initialize these fields: path [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 79 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | explicit TokenFileCredentials(std::string path) : path(std::move(path)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:85:8: error: method 'GetMetadata' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 85 | auto GetMetadata(grpc::string_ref /*serviceUrl*/, grpc::string_ref /*methodName*/, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:87:64: error: pointer parameter 'metadata' can be pointer to const [readability-non-const-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | std::multimap * metadata) -> grpc::Status override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:95:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | } catch (std::exception & err) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:54:5: error: constructor does not initialize these fields: mutex, grown, failure [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | std::condition_variable grown; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 49 | uint64_t written = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 50 | bool eof = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | std::exception_ptr failure; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | NarSpool() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:95:10: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | void fail(const std::exception_ptr & cause) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:142:88: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 142 | inline void demuxNarFrames(Reader & reader, const std::vector> & targets) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:172:5: error: constructor does not initialize these fields: authority, connections, narMutex, pending, narSizes [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 172 | NarFetcher( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:173:54: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 173 | std::function()> channelFactory, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:10: error: method 'recordOrder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:22: error: 2 adjacent parameters of 'recordOrder' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:50: note: the first parameter in the range is 'order' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:92: note: the last parameter in the range is 'sizes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:224:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | ~NarFetcher() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:233:11: error: constructor does not initialize these fields: stub, reader, thread [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | class Session nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 234 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 235 | friend class NarFetcher; nix-grpc-store-clang-tidy-0.1.0-beta.1> 236 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | std::unique_ptr stub; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 238 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 239 | std::unique_ptr> reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 240 | std::vector> targets; nix-grpc-store-clang-tidy-0.1.0-beta.1> 241 | std::jthread thread; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:243:14: error: method 'run' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 243 | void run() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:254:15: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:272:24: error: method 'narSizeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | [[nodiscard]] auto narSizeOf(const nix::StorePath & path) const -> uint64_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:279:10: error: method 'startPending' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 279 | void startPending() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:304:10: error: method 'startSession' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 304 | void startSession(const std::vector & paths) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:18:1: error: included header grpcpp.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:21:1: error: included header client_interceptor.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:23:1: error: included header sync_stream.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:26:1: error: included header globals.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:31:1: error: included header worker-protocol.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:33:1: error: included header file-system.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:37:1: error: included header util.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:40:1: error: included header nix_remote.grpc.pb.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | #include "nix_remote.grpc.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | #include "nix_remote.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:41:1: error: included header nix_remote.pb.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | #include "nix_remote.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 42 | #include "pump.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:77:17: error: method 'makeChannel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | auto GrpcStore::makeChannel(bool ownConnection) -> std::shared_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:101:1: error: constructor does not initialize these fields: creds, stub, sched, trustedOnce, trusted, prefetchMutex, prefetchedInfos, infoBatchMutex, infoBatchWakeup, infoBatchWorker [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 101 | GrpcStore::GrpcStore(const ref &config) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:159:17: error: method 'statusError' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 159 | auto GrpcStore::statusError(const grpc::Status & status, const char * opName) const -> Error nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.cc:172:17: error: method 'goneAway' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 172 | auto GrpcStore::goneAway(const grpc::Status & status) -> bool { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:6:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 6 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:201:5: error: function 'getReference' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 201 | auto getReference() const -> StoreReference override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:212:5: error: function 'openStore' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 212 | auto openStore() const -> ref override; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:256:5: error: function 'connectHint' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | auto connectHint(const std::string & msg) const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:332:9: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 332 | printError("%s: %s, retrying", config->authority.to_string(), firstLine(status.error_message())); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:352:9: error: constructor does not initialize these fields: evalStore [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | std::shared_ptr evalStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | ref inner; nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 351 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 352 | GrpcBuilder(GrpcStore * store, std::shared_ptr evalStore, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:410:7: error: constructor does not initialize these fields: text, fields, act [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 405 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 406 | std::vector fields; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 407 | std::optional act; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 408 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 409 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:410:24: error: 2 adjacent parameters of 'BuildLogActivity' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:410:36: note: the first parameter in the range is 'text' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:410:69: note: the last parameter in the range is 'fields' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:420:9: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 420 | if (msg.has_log_line()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:422:11: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 422 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:466:12: error: constructor does not initialize these fields: dependants, inputs, failedInput, result, workerAddr, redirectAddr, unplaceableSince, unplaceableReason [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 466 | struct Job { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 467 | StorePath drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> 468 | BasicDerivation drv; nix-grpc-store-clang-tidy-0.1.0-beta.1> 469 | std::vector dependants; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 470 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 471 | size_t waiting = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 472 | uint64_t cpHintMs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 473 | unsigned bounced = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 474 | std::optional failedInput; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 475 | std::optional result; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 476 | // Set by the reader thread, consumed by a build thread. nix-grpc-store-clang-tidy-0.1.0-beta.1> 477 | std::string workerAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | // A second Assigned while building: the scheduler moved the drv to a nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | // worker that was already at it. Followed when the current one bounces. nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::string redirectAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:557:12: error: constructor does not initialize these fields: stream, reader, writer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 557 | struct Connection : RemoteStore::Connection nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 558 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 559 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 560 | friend struct GrpcStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> 561 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 562 | // RemoteStore::Connection speaks through FdSink/FdSource, so bridge the nix-grpc-store-clang-tidy-0.1.0-beta.1> 563 | // gRPC stream to a pair of pipes with pump threads. This keeps the nix-grpc-store-clang-tidy-0.1.0-beta.1> 564 | // blocking, ordered semantics the worker protocol relies on without nix-grpc-store-clang-tidy-0.1.0-beta.1> 565 | // reimplementing Source/Sink on top of gRPC. nix-grpc-store-clang-tidy-0.1.0-beta.1> 566 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 567 | std::unique_ptr stream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 568 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 569 | Pipe toRemote; // plugin writes → reader thread sends over gRPC nix-grpc-store-clang-tidy-0.1.0-beta.1> 570 | Pipe fromRemote; // writer thread receives from gRPC → plugin reads nix-grpc-store-clang-tidy-0.1.0-beta.1> 571 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 572 | std::jthread reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:613:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | ~GrpcStore() override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:619:24: error: rvalue reference parameter 'pathsToCopy' is never moved from inside the function body [cppcoreguidelines-rvalue-reference-param-not-moved,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 619 | PathsSource && pathsToCopy, Activity & act, RepairFlag repair, CheckSigsFlag checkSigs) override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:633:9: error: constructor does not initialize these fields: upstream [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 629 | std::unique_ptr upstream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 630 | AutoCloseFD fd; nix-grpc-store-clang-tidy-0.1.0-beta.1> 631 | bool complete = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 632 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 633 | explicit ReplayableNar(std::unique_ptr src) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:645:17: error: variable 'tee' of type 'LambdaSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 645 | LambdaSink tee([&](std::string_view data) -> void { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:652:23: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 652 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/client/store.hh:667:13: error: variable 'replay' of type 'FdSource' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 667 | FdSource replay(fd.get()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/path-info-wire.hh:24:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:27: error: 2 adjacent parameters of 'readCoalesced' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:31: note: the first parameter in the range is 'sourceFd' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:57: note: the last parameter in the range is 'buf' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:72:19: error: variable 'ready' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | int const ready = ::poll(&pollFd, 1, got == 0 ? -1 : 0); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:52: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:59: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:90:41: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | return static_cast(got); // EOF; caller sees short (possibly zero) batch nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:48: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:55: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:97:33: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | return static_cast(got); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/client/transfer.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/client/transfer.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:46:3: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | explicit StaticHeaders(std::shared_ptr headers) : headers(std::move(headers)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:62:5: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | explicit Factory(Headers hdrs) : headers(std::make_shared(std::move(hdrs))) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | auto CreateClientInterceptor(grpc::experimental::ClientRpcInfo * /*info*/) nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | -> grpc::experimental::Interceptor * override { nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | return new StaticHeaders(headers); // NOLINT(cppcoreguidelines-owning-memory): gRPC deletes it nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::shared_ptr headers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:80:3: error: constructor does not initialize these fields: path [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 79 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | explicit TokenFileCredentials(std::string path) : path(std::move(path)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:85:8: error: method 'GetMetadata' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 85 | auto GetMetadata(grpc::string_ref /*serviceUrl*/, grpc::string_ref /*methodName*/, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:87:64: error: pointer parameter 'metadata' can be pointer to const [readability-non-const-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | std::multimap * metadata) -> grpc::Status override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:95:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | } catch (std::exception & err) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:54:5: error: constructor does not initialize these fields: mutex, grown, failure [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | std::condition_variable grown; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 49 | uint64_t written = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 50 | bool eof = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | std::exception_ptr failure; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | NarSpool() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:95:10: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | void fail(const std::exception_ptr & cause) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:142:88: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 142 | inline void demuxNarFrames(Reader & reader, const std::vector> & targets) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:172:5: error: constructor does not initialize these fields: authority, connections, narMutex, pending, narSizes [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 172 | NarFetcher( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:173:54: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 173 | std::function()> channelFactory, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:10: error: method 'recordOrder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:22: error: 2 adjacent parameters of 'recordOrder' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:50: note: the first parameter in the range is 'order' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:187:92: note: the last parameter in the range is 'sizes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 187 | void recordOrder(std::vector order, std::map sizes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:224:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | ~NarFetcher() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:233:11: error: constructor does not initialize these fields: stub, reader, thread [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | class Session nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 234 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 235 | friend class NarFetcher; nix-grpc-store-clang-tidy-0.1.0-beta.1> 236 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | std::unique_ptr stub; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 238 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 239 | std::unique_ptr> reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 240 | std::vector> targets; nix-grpc-store-clang-tidy-0.1.0-beta.1> 241 | std::jthread thread; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:243:14: error: method 'run' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 243 | void run() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:254:15: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:272:24: error: method 'narSizeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | [[nodiscard]] auto narSizeOf(const nix::StorePath & path) const -> uint64_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:279:10: error: method 'startPending' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 279 | void startPending() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/nar-fetcher.hh:304:10: error: method 'startSession' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 304 | void startSession(const std::vector & paths) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:6:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 6 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:201:5: error: function 'getReference' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 201 | auto getReference() const -> StoreReference override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:212:5: error: function 'openStore' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 212 | auto openStore() const -> ref override; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:256:5: error: function 'connectHint' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | auto connectHint(const std::string & msg) const -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:332:9: error: avoid do-while loops [cppcoreguidelines-avoid-do-while,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 332 | printError("%s: %s, retrying", config->authority.to_string(), firstLine(status.error_message())); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:365:29: note: expanded from macro 'printError' nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | #define printError(args...) printMsg(lvlError, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:363:34: note: expanded from macro 'printMsg' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | #define printMsg(level, args...) printMsgUsing(logger, level, args) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/mf4hwligj10vypiz8qsz90kl69i6vrk0-nix-util-2.36.0pre20260920_5711f8fe-dev/include/nix/util/logging.hh:357:5: note: expanded from macro 'printMsgUsing' nix-grpc-store-clang-tidy-0.1.0-beta.1> 357 | do { \ nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:352:9: error: constructor does not initialize these fields: evalStore [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | std::shared_ptr evalStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | ref inner; nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 351 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 352 | GrpcBuilder(GrpcStore * store, std::shared_ptr evalStore, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:7: error: constructor does not initialize these fields: text, fields, act [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 405 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 406 | std::vector fields; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 407 | std::optional act; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 408 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 409 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:24: error: 2 adjacent parameters of 'BuildLogActivity' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:36: note: the first parameter in the range is 'text' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:410:69: note: the last parameter in the range is 'fields' nix-grpc-store-clang-tidy-0.1.0-beta.1> 410 | BuildLogActivity(std::string text, std::vector fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:420:9: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 420 | if (msg.has_log_line()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:422:11: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 422 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:466:12: error: constructor does not initialize these fields: dependants, inputs, failedInput, result, workerAddr, redirectAddr, unplaceableSince, unplaceableReason [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 466 | struct Job { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 467 | StorePath drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> 468 | BasicDerivation drv; nix-grpc-store-clang-tidy-0.1.0-beta.1> 469 | std::vector dependants; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 470 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 471 | size_t waiting = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 472 | uint64_t cpHintMs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 473 | unsigned bounced = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 474 | std::optional failedInput; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 475 | std::optional result; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 476 | // Set by the reader thread, consumed by a build thread. nix-grpc-store-clang-tidy-0.1.0-beta.1> 477 | std::string workerAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | // A second Assigned while building: the scheduler moved the drv to a nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | // worker that was already at it. Followed when the current one bounces. nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::string redirectAddr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:557:12: error: constructor does not initialize these fields: stream, reader, writer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 557 | struct Connection : RemoteStore::Connection nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 558 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 559 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 560 | friend struct GrpcStore; nix-grpc-store-clang-tidy-0.1.0-beta.1> 561 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 562 | // RemoteStore::Connection speaks through FdSink/FdSource, so bridge the nix-grpc-store-clang-tidy-0.1.0-beta.1> 563 | // gRPC stream to a pair of pipes with pump threads. This keeps the nix-grpc-store-clang-tidy-0.1.0-beta.1> 564 | // blocking, ordered semantics the worker protocol relies on without nix-grpc-store-clang-tidy-0.1.0-beta.1> 565 | // reimplementing Source/Sink on top of gRPC. nix-grpc-store-clang-tidy-0.1.0-beta.1> 566 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> 567 | std::unique_ptr stream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 568 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 569 | Pipe toRemote; // plugin writes → reader thread sends over gRPC nix-grpc-store-clang-tidy-0.1.0-beta.1> 570 | Pipe fromRemote; // writer thread receives from gRPC → plugin reads nix-grpc-store-clang-tidy-0.1.0-beta.1> 571 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 572 | std::jthread reader; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:613:5: error: use '= default' to define a trivial destructor [modernize-use-equals-default,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | ~GrpcStore() override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:619:24: error: rvalue reference parameter 'pathsToCopy' is never moved from inside the function body [cppcoreguidelines-rvalue-reference-param-not-moved,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 619 | PathsSource && pathsToCopy, Activity & act, RepairFlag repair, CheckSigsFlag checkSigs) override nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:633:9: error: constructor does not initialize these fields: upstream [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 629 | std::unique_ptr upstream; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 630 | AutoCloseFD fd; nix-grpc-store-clang-tidy-0.1.0-beta.1> 631 | bool complete = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 632 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 633 | explicit ReplayableNar(std::unique_ptr src) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:645:17: error: variable 'tee' of type 'LambdaSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 645 | LambdaSink tee([&](std::string_view data) -> void { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:652:23: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 652 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/store.hh:667:13: error: variable 'replay' of type 'FdSource' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 667 | FdSource replay(fd.get()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:21:1: error: included header sync_stream.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:24:1: error: included header derived-path.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:28:1: error: included header worker-protocol.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:29:1: error: included header error.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:32:1: error: included header serialise.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:33:1: error: included header util.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:36:1: error: included header nix_remote.grpc.pb.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | #include "nix_remote.grpc.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | #include "nix_remote.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:38:1: error: included header path-info-wire.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | #include "path-info-wire.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | #include "pump.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:39:1: error: included header pump.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | #include "pump.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:43:17: error: method 'queryValidPathsRouted' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | auto GrpcStore::queryValidPathsRouted(const StorePathSet & paths, SubstituteFlag maybeSubstitute, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:57:16: error: variable 'res' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | StorePathSet res; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:64:17: error: method 'queryMissing' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | auto GrpcStore::queryMissing(const std::vector & targets) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:73:5: error: variable 'ctx' of type 'grpc::ClientContext' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:100:17: error: method 'queryPathInfosNative' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 100 | auto GrpcStore::queryPathInfosNative(const StorePathSet &paths) -> PathInfoMap { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:107:5: error: variable 'ctx' of type 'grpc::ClientContext' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 107 | grpc::ClientContext ctx; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:141:17: error: method 'runInfoBatches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | void GrpcStore::runInfoBatches(const std::stop_token & stop) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:152:22: error: variable 'paths' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 152 | StorePathSet paths; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:177:17: error: method 'queryPathInfoUncached' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | void GrpcStore::queryPathInfoUncached(const StorePath & path, InfoCallback callback) noexcept { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:203:17: error: method 'addMultipleToStoreRouted' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 203 | void GrpcStore::addMultipleToStoreRouted( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/transfer.cc:216:17: error: variable 'addMultipleToStoreOnce' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 216 | auto GrpcStore::addMultipleToStoreOnce( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/path-info-wire.hh:24:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:27: error: 2 adjacent parameters of 'readCoalesced' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:31: note: the first parameter in the range is 'sourceFd' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:57: note: the last parameter in the range is 'buf' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:72:19: error: variable 'ready' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | int const ready = ::poll(&pollFd, 1, got == 0 ? -1 : 0); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:52: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:59: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:90:41: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | return static_cast(got); // EOF; caller sees short (possibly zero) batch nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:48: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:55: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:97:33: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | return static_cast(got); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/main.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/main.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:66:8: error: constructor does not initialize these fields: text [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | struct BuildEvent nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:68:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:22:12: error: enum 'Role' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | enum class Role : std::uint8_t { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:51:7: error: constructor does not initialize these fields: rules, anonRole [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | class Acl nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | Role role; nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::vector rules; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | // Separate from the glob rules so '*' cannot grant anonymous access. nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | std::optional anonRole; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:53:12: error: constructor does not initialize these fields: pattern, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:70:10: error: method 'addRule' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | void addRule(std::string_view spec) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:95:24: error: method 'roleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | [[nodiscard]] auto roleFor(const std::optional & commonName) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.hh:19:8: error: constructor does not initialize these fields: role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | struct Caller nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string name = "-"; // cert CN or oidc::, for logs and metrics nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::optional role; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.hh:21:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:53:8: error: constructor does not initialize these fields: socketPath [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Backends nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string socketPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:82:5: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | if (event.kind == BuildEvent::Kind::phase) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:84:7: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 84 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:43:5: error: constructor does not initialize these fields: remote [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | std::optional remote; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 42 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | explicit Cache(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:61:24: error: method 'present' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | [[nodiscard]] auto present(const std::vector & keys) -> std::unordered_set nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:10: error: method 'publish' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:18: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:51: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:76: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:38: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:71: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:96: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:113:10: error: method 'completeRefs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 113 | void completeRefs(nix::Store & store, const nix::ValidPathInfo & info) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:45:8: error: constructor does not initialize these fields: since [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Expected nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | Clock::time_point since; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:52:12: error: constructor does not initialize these fields: mutex, cv, resultWire [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | struct Shared nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::condition_variable cv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | std::atomic revoked{false}; // scheduler moved the drv to a worker further along nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | std::atomic attached{0}; // callers waiting in attach(); the build outlives its first caller for them nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | bool finished = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::string resultWire; // BuildDerivationDone serialised nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:80:12: error: constructor does not initialize these fields: shared [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Admission nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | std::shared_ptr shared; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:91:9: error: parameter 3 is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | const std::vector> & outputs, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:95:5: error: function 'hello' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | auto hello() const -> nix::remote::WorkerMsg; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:108:5: error: function 'send' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 108 | auto send(const nix::remote::WorkerMsg & msg) const -> bool; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:111:21: error: member 'options' of type 'const Options &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 111 | const Options & options; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:112:15: error: member 'metrics' of type 'Metrics &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 112 | Metrics & metrics; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:114:12: error: constructor does not initialize these fields: expected [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 114 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 115 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 116 | std::unordered_map expected; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.hh:128:9: error: parameter 4 is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 128 | const std::vector> & outputs); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:45:12: error: constructor does not initialize these fields: defaultSystem, present [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::string defaultSystem; // for Want/Hello with empty or "builtin" system nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | PresentFn present; // unset: nothing is ever Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:64:12: error: constructor does not initialize these fields: send [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | struct Client nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | sched::ClientId id = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | ClientSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:80:12: error: constructor does not initialize these fields: send, id [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | WorkerSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | std::optional id; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:95:5: error: function 'sendLock' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | ABSL_LOCK_RETURNED(mutex) auto sendLock() const -> const absl::Mutex & nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/0gyk1hdw37b47p2pra40hjf7xzl312lf-abseil-cpp-20260107.1-dev/include/absl/base/thread_annotations.h:170:31: note: expanded from macro 'ABSL_LOCK_RETURNED' nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | #define ABSL_LOCK_RETURNED(x) __attribute__((lock_returned(x))) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/idle.hh:41:24: error: method 'idleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | [[nodiscard]] auto idleFor() const -> Clock::duration nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:9:10: error: 'algorithm' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 9 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:45:1: error: included header derived-path.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:62:1: error: included header unix-domain-socket.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:76:1: error: included header oidc.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | #include "oidc.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | #include "path-info-wire.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:77:1: error: included header path-info-wire.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | #include "path-info-wire.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | #include "metrics.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:91:37: error: variable 'stopSignal' can be made static or moved into an anonymous namespace to enforce internal linkage [misc-use-internal-linkage,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | volatile std::sig_atomic_t nixgrpc::stopSignal = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:100:24: error: member 'metrics' of type 'nixgrpc::Metrics &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 100 | nixgrpc::Metrics & metrics; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:101:28: error: member 'idle' of type 'nixgrpc::IdleTracker &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 101 | nixgrpc::IdleTracker & idle; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:103:21: error: member 'auth' of type 'nixgrpc::Auth &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 103 | nixgrpc::Auth & auth; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:105:28: error: member 'coord' of type 'nixgrpc::Coordinator &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 105 | nixgrpc::Coordinator & coord; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:112:24: error: method 'openLocalStore' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 112 | [[nodiscard]] auto openLocalStore() const -> nix::ref nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:119:10: error: method 'getStore' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 119 | auto getStore() -> nix::ref nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:130:10: error: method 'localDaemonGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | auto localDaemonGone(const std::exception & err) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:133:20: error: variable 'gone' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 133 | bool const gone = dynamic_cast(&err) != nullptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 134 | || (sys != nullptr && (sys->errNo == EPIPE || sys->errNo == ECONNRESET)); nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | = false nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:163:23: error: forwarding reference parameter 'func' is never forwarded inside the function body [cppcoreguidelines-missing-std-forward,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 163 | auto guarded(F && func) -> grpc::Status nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:185:81: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | void logDebug(std::initializer_list> fields) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:195:12: error: constructor does not initialize these fields: context, method [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | struct Rpc nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | grpc::ServerContext * context; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 198 | std::string_view method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:202:14: error: method 'done' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 202 | void done(const Fields & extra) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:230:5: error: constructor does not initialize these fields: storeUri, workerName, storeMutex, store [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 98 | NixRemoteService( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:231:9: error: 3 adjacent parameters of 'NixRemoteService' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 231 | std::string socketPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 232 | std::string storeUri, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | std::string workerName, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:231:21: note: the first parameter in the range is 'socketPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 231 | std::string socketPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:233:21: note: the last parameter in the range is 'workerName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 233 | std::string workerName, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:297:31: error: variable 'paths' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | nix::StorePathSet paths; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:591:9: error: 2 adjacent parameters of 'buildExpected' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 591 | const nixgrpc::BuildEventSink & log, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 592 | const std::map & outPaths, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:591:41: note: the first parameter in the range is 'log' nix-grpc-store-clang-tidy-0.1.0-beta.1> 591 | const nixgrpc::BuildEventSink & log, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:592:55: note: the last parameter in the range is 'outPaths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 592 | const std::map & outPaths, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:595:53: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 595 | std::vector> & outputs) -> grpc::Status nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:731:13: error: variable 'counting' of type 'nix::LambdaSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 731 | nix::LambdaSink counting([&](std::string_view data) -> void { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:796:6: error: an exception may be thrown in function 'main' which should not throw exceptions [bugprone-exception-escape,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 796 | auto main(int argc, char ** argv) -> int nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/main.cc:819:9: note: frame #0: unhandled exception of type 'nix::Error' may be thrown in function 'main' here nix-grpc-store-clang-tidy-0.1.0-beta.1> 819 | throw nix::Error("--idle-timeout requires systemd socket activation"); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:77:9: error: constructor does not initialize these fields: method, start [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | std::string method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | prometheus::Histogram * hist = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | std::chrono::steady_clock::time_point start; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 74 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | // NOLINTNEXTLINE(bugprone-easily-swappable-parameters): method, then phase. nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | Phase(Metrics & metrics, std::string method, const std::string & phase) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:145:10: error: method 'buildInfo' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | void buildInfo( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:9: error: 4 adjacent parameters of 'buildInfo' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:29: note: the first parameter in the range is 'version' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:114: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:156:10: error: method 'buildSlots' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 156 | void buildSlots(unsigned count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: error: 4 adjacent parameters of 'schedSystem' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:56: note: the first parameter in the range is 'system' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:127: note: the last parameter in the range is 'count' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' may be implicitly converted: 'const int &' (as 'int') -> 'size_t' (as 'unsigned long'), 'size_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:205:5: error: constructor does not initialize these fields: exposer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | explicit Metrics(const std::string & listen) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:19: error: 2 adjacent parameters of 'countRpc' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:39: note: the first parameter in the range is 'method' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:67: note: the last parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: error: 3 adjacent parameters of 'countTunnelBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:47: note: the first parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:86: note: the last parameter in the range is 'bytesOut' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: error: 3 adjacent parameters of 'countNarBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:44: note: the first parameter in the range is 'direction' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:96: note: the last parameter in the range is 'bytes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:17:8: error: constructor does not initialize these fields: url, tokenFile, clientCert, clientKey, pushArgv [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | struct Niks3Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | std::string url; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | std::string tokenFile; // bearer, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | std::string clientCert; // mTLS, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | PushProcess::Argv pushArgv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:40:5: error: constructor does not initialize these fields: baseUrl, bearer, clientCert, clientKey [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string baseUrl; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | std::shared_ptr bearer; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string clientCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | explicit Niks3Client(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:24: error: method 'post' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:29: error: 2 adjacent parameters of 'post' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:46: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:75: note: the last parameter in the range is 'body' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:52: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:60:8: error: constructor does not initialize these fields: subject, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | struct Identity nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | std::string subject; // "oidc::" nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | std::optional role; // nullopt: verified but no rule matched nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:76:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:26: error: 2 adjacent parameters of 'providerFrom' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:46: note: the first parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:65: note: the last parameter in the range is 'prov' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:25: error: 2 adjacent parameters of 'lookupClaim' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:38: note: the first parameter in the range is 'claims' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:63: note: the last parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:251:8: error: constructor does not initialize these fields: kid, kty, crv, pem [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 251 | struct Jwk nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 252 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 253 | std::string kid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | std::string kty; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | std::string crv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | std::string pem; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:286:31: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | if (jwk.kty == "RSA") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:10: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:37: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:290:62: note: clone 2 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 290 | } else if (jwk.kty == "OKP" && jwk.crv == "Ed25519") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:294:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:300:8: error: constructor does not initialize these fields: at [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | struct FixedClock nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 302 | std::chrono::system_clock::time_point at; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:347:12: error: constructor does not initialize these fields: identity, error [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 347 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | std::optional identity; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | std::string error; // for logs, not for the client nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:355:5: error: constructor does not initialize these fields: refetchOnMiss, keys [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 355 | explicit Verifier(Config cfg, std::chrono::seconds refetchOnMiss = defaultRefetchOnMiss) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:10: error: method 'verify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:17: error: 2 adjacent parameters of 'verify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:37: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:82: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:44: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:377:12: error: constructor does not initialize these fields: lock, keys, fetched [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 377 | struct KeySet nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 378 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 379 | std::mutex lock; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 380 | std::vector keys; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 381 | // steady_clock starts at boot on Linux, so its epoch is not "long ago". nix-grpc-store-clang-tidy-0.1.0-beta.1> 382 | std::optional fetched; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:397:24: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 397 | [[nodiscard]] auto get(const Provider & provider, const std::string & url) const -> Json nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:417:24: error: method 'fetchKeys' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 417 | [[nodiscard]] auto fetchKeys(const Provider & provider) const -> std::vector nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:9: error: 2 adjacent parameters of 'fetchDue' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:62: note: the first parameter in the range is 'fetched' nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:443:47: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:10: error: method 'candidates' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:62: error: 2 adjacent parameters of 'candidates' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:78: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:59: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:21: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:10: error: method 'doVerify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:19: error: 2 adjacent parameters of 'doVerify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:39: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:84: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.hh:21:8: error: constructor does not initialize these fields: idleTimeout, storeUri, tlsCert, tlsKey, clientCA, metricsListen, workerName, oidcConfig, schedulerAddr, schedulerTokenFile, advertise, storeDir [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Options nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string listen = "0.0.0.0:50051"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | std::optional idleTimeout; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | std::string socketPath = "/nix/var/nix/daemon-socket/socket"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | // Store URI for the native bulk RPCs. Defaults to the proxy socket. nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | std::string storeUri; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | std::string tlsCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string tlsKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | std::string clientCA; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | std::string metricsListen; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | std::string workerName; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | LogLevel logLevel = LogLevel::info; nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | Acl acl; nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | xfcc::TrustedProxies proxies; nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string oidcConfig; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:61:5: error: constructor does not initialize these fields: argv, state, writeMutex, reader [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | explicit PushProcess(Argv argv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:10: error: method 'pushWait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:19: error: 2 adjacent parameters of 'pushWait' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:52: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:77: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:123:16: error: constructor does not initialize these fields: message, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | std::string status = "ok"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 127 | Signatures signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:130:9: error: constructor does not initialize these fields: sync, done [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | explicit Pending(size_t count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:136:16: error: constructor does not initialize these fields: status, message, path, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 136 | struct Ack nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 137 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 138 | std::string status; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 139 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 140 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | std::set signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:144:14: error: method 'ack' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 144 | auto ack(Ack msg) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:147:37: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | if (msg.status != "ok") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:14: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:49: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:162:14: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 162 | void fail(const std::string & message) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:171:14: error: method 'wait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | auto wait(const Cancelled & cancelled) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:184:16: error: constructor does not initialize these fields: left [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 184 | struct Inner nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | size_t left; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:193:12: error: constructor does not initialize these fields: stdinFd [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | nix::Pid pid; nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | std::shared_ptr stdinFd; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:206:10: error: method 'ensureChild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | void ensureChild(nix::Sync::WriteLock & lck) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:237:10: error: method 'readAcks' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | void readAcks(int acksFd) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:260:11: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 260 | } catch (nix::EndOfFile &) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:262:11: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 262 | } catch (std::exception & err) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/socket-activation.hh:90:12: error: 2 adjacent parameters of 'acceptInto' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | acceptInto(const std::vector & listenFds, const std::shared_ptr & acceptor) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/socket-activation.hh:90:37: note: the first parameter in the range is 'listenFds' nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | acceptInto(const std::vector & listenFds, const std::shared_ptr & acceptor) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/socket-activation.hh:90:120: note: the last parameter in the range is 'acceptor' nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | acceptInto(const std::vector & listenFds, const std::shared_ptr & acceptor) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:21:12: error: constructor does not initialize these fields: token [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string token; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:39:5: error: constructor does not initialize these fields: path, cached [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix::Sync cached; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | static auto mtime(const struct stat & info) -> struct timespec nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #ifdef __APPLE__ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | return info.st_mtimespec; nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #else nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | return info.st_mtim; nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #endif nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | explicit TokenFile(std::string path_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:46:10: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | auto get() -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:32:5: error: constructor does not initialize these fields: rest [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string_view rest; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | explicit Cursor(std::string_view input) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:47:10: error: method 'take' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | auto take() -> char nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:52:20: error: variable 'chr' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | char const chr = rest.front(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:58:10: error: method 'until' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | auto until(std::string_view stops) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:69:10: error: method 'remaining' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | auto remaining() -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:150:13: error: variable 'subjectCommonName' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | inline auto subjectCommonName(std::string_view value) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:192:7: error: constructor does not initialize these fields: patterns [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 192 | class TrustedProxies nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | std::vector patterns; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:197:10: error: method 'add' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | void add(std::string_view pattern) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:210:24: error: method 'matches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | [[nodiscard]] auto matches(const std::optional & peerCommonName) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/path-info-wire.hh:24:5: error: variable 'sink' of type 'nix::StringSink' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | nix::StringSink sink; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:27: error: 2 adjacent parameters of 'readCoalesced' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:31: note: the first parameter in the range is 'sourceFd' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:65:57: note: the last parameter in the range is 'buf' nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | inline auto readCoalesced(int sourceFd, std::span buf) -> ssize_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:72:19: error: variable 'ready' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | int const ready = ::poll(&pollFd, 1, got == 0 ? -1 : 0); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:52: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:77:59: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:90:41: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 90 | return static_cast(got); // EOF; caller sees short (possibly zero) batch nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:48: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:95:55: error: narrowing conversion from constant value 18446744073709551615 (0xFFFFFFFFFFFFFFFF) of type 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | return got != 0 ? static_cast(got) : -1; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/pump.hh:97:33: error: narrowing conversion from 'size_t' (aka 'unsigned long') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | return static_cast(got); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> >>> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy --use-color -quiet -p /build/source/build /build/source/src/daemon/coordinator.cc nix-grpc-store-clang-tidy-0.1.0-beta.1> Errors encountered while running clang-tidy nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 5: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/82lxfl0n7xgxbigbbj84w73qcy4ps0i8-clang-tools-22.1.8/bin/clang-tidy: line 23: 182: not found nix-grpc-store-clang-tidy-0.1.0-beta.1> Error while processing /build/source/src/daemon/coordinator.cc. nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:66:8: error: constructor does not initialize these fields: text [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | struct BuildEvent nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | std::string text; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/build-log.hh:68:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | enum class Kind : std::uint8_t { line, phase } kind = Kind::line; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:46:3: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | explicit StaticHeaders(std::shared_ptr headers) : headers(std::move(headers)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:62:5: error: constructor does not initialize these fields: headers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | explicit Factory(Headers hdrs) : headers(std::make_shared(std::move(hdrs))) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | auto CreateClientInterceptor(grpc::experimental::ClientRpcInfo * /*info*/) nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | -> grpc::experimental::Interceptor * override { nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | return new StaticHeaders(headers); // NOLINT(cppcoreguidelines-owning-memory): gRPC deletes it nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::shared_ptr headers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:80:3: error: constructor does not initialize these fields: path [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 78 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 79 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | explicit TokenFileCredentials(std::string path) : path(std::move(path)) {} nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:85:8: error: method 'GetMetadata' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 85 | auto GetMetadata(grpc::string_ref /*serviceUrl*/, grpc::string_ref /*methodName*/, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/client/channel.hh:87:64: error: pointer parameter 'metadata' can be pointer to const [readability-non-const-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | std::multimap * metadata) -> grpc::Status override { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:22:12: error: enum 'Role' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | enum class Role : std::uint8_t { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:51:7: error: constructor does not initialize these fields: rules, anonRole [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 51 | class Acl nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | Role role; nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::vector rules; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | // Separate from the glob rules so '*' cannot grant anonymous access. nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | std::optional anonRole; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:53:12: error: constructor does not initialize these fields: pattern, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Rule nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string pattern; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:70:10: error: method 'addRule' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | void addRule(std::string_view spec) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/acl.hh:95:24: error: method 'roleFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | [[nodiscard]] auto roleFor(const std::optional & commonName) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.hh:19:8: error: constructor does not initialize these fields: role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | struct Caller nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string name = "-"; // cert CN or oidc::, for logs and metrics nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::optional role; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/auth.hh:21:16: error: enum 'Kind' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | enum class Kind : std::uint8_t { anonymous, named, badToken }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:53:8: error: constructor does not initialize these fields: socketPath [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | struct Backends nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::string socketPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:82:5: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | if (event.kind == BuildEvent::Kind::phase) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/backend.hh:84:7: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 84 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:43:5: error: constructor does not initialize these fields: remote [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | std::optional remote; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 41 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 42 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | explicit Cache(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:61:24: error: method 'present' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | [[nodiscard]] auto present(const std::vector & keys) -> std::unordered_set nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:10: error: method 'publish' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:18: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:51: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:87:76: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 87 | auto publish(const std::vector & paths, const Cancelled & cancelled = never) -> PushProcess::Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:38: error: 2 adjacent parameters of 'publish' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:71: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:97:96: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 97 | void publish(nix::Store & store, const std::vector & paths, const Cancelled & cancelled = never) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/cache.hh:113:10: error: method 'completeRefs' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 113 | void completeRefs(nix::Store & store, const nix::ValidPathInfo & info) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:25:1: error: included header create_channel.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:27:1: error: included header credentials.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:28:1: error: included header tls_certificate_provider.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:34:1: error: included header status.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:35:1: error: included header sync_stream.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:38:1: error: included header file-system.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:43:1: error: included header cache.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 43 | #include "cache.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 44 | #include "client/channel.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:44:1: error: included header channel.hh is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 44 | #include "client/channel.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | #include "logfmt.hh" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:47:1: error: included header nix_remote.grpc.pb.h is not used directly [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | #include "nix_remote.grpc.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | #include "nix_remote.pb.h" nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:70:1: error: constructor does not initialize these fields: state, sendFn [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 70 | Builder::Builder(const Options & options, Metrics & metrics) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:91:15: error: method 'onRevoke' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void Builder::onRevoke(const nix::remote::Revoke & rev) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:112:15: error: method 'admit' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 112 | auto Builder::admit(const std::string & drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:125:15: error: method 'finished' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | void Builder::finished( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:128:55: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 128 | const std::vector> & outputs, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:152:5: error: 2 adjacent parameters of 'sendDone' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 152 | const std::string & drvPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 153 | uint64_t assignId, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:152:25: note: the first parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 152 | const std::string & drvPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:153:14: note: the last parameter in the range is 'assignId' nix-grpc-store-clang-tidy-0.1.0-beta.1> 153 | uint64_t assignId, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:152:5: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 152 | const std::string & drvPath, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:153:5: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 153 | uint64_t assignId, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:153:5: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:155:55: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 155 | const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:195:15: error: method 'setDraining' can be made const [readability-make-member-function-const,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | void Builder::setDraining(bool draining) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:210:15: error: method 'send' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | auto Builder::send(const WorkerMsg & msg) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:216:15: error: method 'tick' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 216 | void Builder::tick() nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:292:5: error: variable 'tls' of type 'grpc::experimental::TlsChannelCredentialsOptions' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 292 | grpc::experimental::TlsChannelCredentialsOptions tls; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:296:24: error: no header providing "nix::Error" is directly included [misc-include-cleaner,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | throw nix::Error("loading CA certificates: %s", status.ToString()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:321:5: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 321 | if (active) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:323:7: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:340:1: error: constructor does not initialize these fields: builder, dispatcher, scheduler, sessionThread, elector [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 340 | Coordinator::Coordinator(const Options & options, Auth & auth, Metrics & metrics) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:406:20: error: variable 'elect' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 406 | const bool elect = options.niks3.enabled() && (!builder || !options.schedulerAddr.empty()); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = false nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:415:5: error: if with identical then and else branches [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 415 | if (options.schedulerAddr.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:417:7: note: else branch starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 417 | } else { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/coordinator.cc:455:9: error: variable 'restarting' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 455 | bool restarting = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:5:10: error: 'atomic' file not found [clang-diagnostic-error] nix-grpc-store-clang-tidy-0.1.0-beta.1> 5 | #include nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:45:8: error: constructor does not initialize these fields: since [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Expected nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | Clock::time_point since; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:52:12: error: constructor does not initialize these fields: mutex, cv, resultWire [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | struct Shared nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 54 | std::mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 55 | std::condition_variable cv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 56 | std::atomic revoked{false}; // scheduler moved the drv to a worker further along nix-grpc-store-clang-tidy-0.1.0-beta.1> 57 | std::atomic attached{0}; // callers waiting in attach(); the build outlives its first caller for them nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | bool finished = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 59 | std::string resultWire; // BuildDerivationDone serialised nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:80:12: error: constructor does not initialize these fields: shared [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Admission nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | std::shared_ptr shared; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:91:9: error: parameter 3 is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | const std::vector> & outputs, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:95:5: error: function 'hello' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | auto hello() const -> nix::remote::WorkerMsg; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:108:5: error: function 'send' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 108 | auto send(const nix::remote::WorkerMsg & msg) const -> bool; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:111:21: error: member 'options' of type 'const Options &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 111 | const Options & options; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:112:15: error: member 'metrics' of type 'Metrics &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 112 | Metrics & metrics; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:114:12: error: constructor does not initialize these fields: expected [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 114 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 115 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 116 | std::unordered_map expected; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> /build/source/build/../src/daemon/coordinator.hh:128:9: error: parameter 4 is const-qualified in the function declaration; const-qualification of parameters only has an effect in function definitions [readability-avoid-const-params-in-decls,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 128 | const std::vector> & outputs); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:45:12: error: constructor does not initialize these fields: defaultSystem, present [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 45 | struct Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | std::string defaultSystem; // for Want/Hello with empty or "builtin" system nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 48 | PresentFn present; // unset: nothing is ever Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:64:12: error: constructor does not initialize these fields: send [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 64 | struct Client nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | sched::ClientId id = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | ClientSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:80:12: error: constructor does not initialize these fields: send, id [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 80 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 82 | WorkerSend send; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 83 | std::optional id; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/dispatcher.hh:95:5: error: function 'sendLock' should be marked [[nodiscard]] [modernize-use-nodiscard,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 95 | ABSL_LOCK_RETURNED(mutex) auto sendLock() const -> const absl::Mutex & nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | [[nodiscard]] nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/0gyk1hdw37b47p2pra40hjf7xzl312lf-abseil-cpp-20260107.1-dev/include/absl/base/thread_annotations.h:170:31: note: expanded from macro 'ABSL_LOCK_RETURNED' nix-grpc-store-clang-tidy-0.1.0-beta.1> 170 | #define ABSL_LOCK_RETURNED(x) __attribute__((lock_returned(x))) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:77:9: error: constructor does not initialize these fields: method, start [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | std::string method; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 72 | prometheus::Histogram * hist = nullptr; nix-grpc-store-clang-tidy-0.1.0-beta.1> 73 | std::chrono::steady_clock::time_point start; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 74 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 75 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | // NOLINTNEXTLINE(bugprone-easily-swappable-parameters): method, then phase. nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | Phase(Metrics & metrics, std::string method, const std::string & phase) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:145:10: error: method 'buildInfo' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | void buildInfo( nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:9: error: 4 adjacent parameters of 'buildInfo' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:29: note: the first parameter in the range is 'version' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:146:114: note: the last parameter in the range is 'features' nix-grpc-store-clang-tidy-0.1.0-beta.1> 146 | const std::string & version, const std::string & worker, const std::string & system, const std::string & features) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:156:10: error: method 'buildSlots' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 156 | void buildSlots(unsigned count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: error: 4 adjacent parameters of 'schedSystem' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:56: note: the first parameter in the range is 'system' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:127: note: the last parameter in the range is 'count' nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:36: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | [[nodiscard]] auto schedSystem(const std::string & system, const std::string & features, const std::string & kind, size_t count) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:186:120: note: 'const int &' and 'size_t' may be implicitly converted: 'const int &' (as 'int') -> 'size_t' (as 'unsigned long'), 'size_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:205:5: error: constructor does not initialize these fields: exposer [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | explicit Metrics(const std::string & listen) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:19: error: 2 adjacent parameters of 'countRpc' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:39: note: the first parameter in the range is 'method' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:213:67: note: the last parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 213 | void countRpc(const std::string & method, const std::string & commonName) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: error: 3 adjacent parameters of 'countTunnelBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:47: note: the first parameter in the range is 'commonName' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:86: note: the last parameter in the range is 'bytesOut' nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:27: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 218 | void countTunnelBytes(const std::string & commonName, uint64_t bytesIn, uint64_t bytesOut) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:218:59: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: error: 3 adjacent parameters of 'countNarBytes' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:44: note: the first parameter in the range is 'direction' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:96: note: the last parameter in the range is 'bytes' nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:24: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 224 | void countNarBytes(const std::string & direction, const std::string & commonName, uint64_t bytes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/metrics.hh:224:87: note: 'const int &' and 'uint64_t' may be implicitly converted: 'const int &' (as 'int') -> 'uint64_t' (as 'unsigned long'), 'uint64_t' (as 'unsigned long') -> 'const int &' (as 'int') nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:17:8: error: constructor does not initialize these fields: url, tokenFile, clientCert, clientKey, pushArgv [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 17 | struct Niks3Config nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 18 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | std::string url; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | std::string tokenFile; // bearer, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | std::string clientCert; // mTLS, optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | PushProcess::Argv pushArgv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:40:5: error: constructor does not initialize these fields: baseUrl, bearer, clientCert, clientKey [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | std::string baseUrl; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | std::shared_ptr bearer; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string clientCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::string clientKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 38 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 39 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 40 | explicit Niks3Client(const Niks3Config & cfg) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:24: error: method 'post' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:29: error: 2 adjacent parameters of 'post' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:46: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:75: note: the last parameter in the range is 'body' nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/niks3-client.hh:53:52: note: 'int' and 'const int &' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 53 | [[nodiscard]] auto post(std::string_view path, const nlohmann::json & body) const -> std::unique_ptr nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:60:8: error: constructor does not initialize these fields: subject, role [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 60 | struct Identity nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 62 | std::string subject; // "oidc::" nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 63 | std::optional role; // nullopt: verified but no rule matched nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:76:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 76 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:26: error: 2 adjacent parameters of 'providerFrom' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:46: note: the first parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:123:65: note: the last parameter in the range is 'prov' nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | inline auto providerFrom(const std::string & name, const Json & prov, bool allowInsecure) -> Provider nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:25: error: 2 adjacent parameters of 'lookupClaim' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:38: note: the first parameter in the range is 'claims' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:63: note: the last parameter in the range is 'name' nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:191:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | inline auto lookupClaim(const Json & claims, std::string_view name) -> const Json * nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:251:8: error: constructor does not initialize these fields: kid, kty, crv, pem [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 251 | struct Jwk nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 252 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 253 | std::string kid; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 254 | std::string kty; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | std::string crv; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 256 | std::string pem; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:286:31: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | if (jwk.kty == "RSA") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:10: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:288:37: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 288 | } else if (jwk.kty == "EC") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:290:62: note: clone 2 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 290 | } else if (jwk.kty == "OKP" && jwk.crv == "Ed25519") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:294:7: error: empty catch statements hide issues; to handle exceptions appropriately, consider re-throwing, handling, or avoiding catch altogether [bugprone-empty-catch,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | } catch (...) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:300:8: error: constructor does not initialize these fields: at [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | struct FixedClock nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 302 | std::chrono::system_clock::time_point at; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:347:12: error: constructor does not initialize these fields: identity, error [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 347 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 348 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 349 | std::optional identity; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 350 | std::string error; // for logs, not for the client nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:355:5: error: constructor does not initialize these fields: refetchOnMiss, keys [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 355 | explicit Verifier(Config cfg, std::chrono::seconds refetchOnMiss = defaultRefetchOnMiss) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:10: error: method 'verify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:17: error: 2 adjacent parameters of 'verify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:37: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:82: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:363:44: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 363 | auto verify(const std::string & token, std::chrono::system_clock::time_point now = std::chrono::system_clock::now()) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:377:12: error: constructor does not initialize these fields: lock, keys, fetched [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 377 | struct KeySet nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 378 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 379 | std::mutex lock; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 380 | std::vector keys; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 381 | // steady_clock starts at boot on Linux, so its epoch is not "long ago". nix-grpc-store-clang-tidy-0.1.0-beta.1> 382 | std::optional fetched; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:397:24: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 397 | [[nodiscard]] auto get(const Provider & provider, const std::string & url) const -> Json nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:417:24: error: method 'fetchKeys' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 417 | [[nodiscard]] auto fetchKeys(const Provider & provider) const -> std::vector nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:9: error: 2 adjacent parameters of 'fetchDue' of similar type ('int') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:442:62: note: the first parameter in the range is 'fetched' nix-grpc-store-clang-tidy-0.1.0-beta.1> 442 | std::optional fetched, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:443:47: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 443 | std::chrono::steady_clock::time_point now, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:10: error: method 'candidates' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:62: error: 2 adjacent parameters of 'candidates' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:456:78: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 456 | auto candidates(const Provider & provider, KeySet & set, const Decoded & token, nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:59: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:457:21: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 457 | std::chrono::system_clock::time_point now) -> VerifierBuilder nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:10: error: method 'doVerify' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:19: error: 2 adjacent parameters of 'doVerify' of similar type are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:39: note: the first parameter in the range is 'token' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:84: note: the last parameter in the range is 'now' nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/oidc.hh:493:46: note: 'const int &' and 'int' parameters accept and bind the same kind of values nix-grpc-store-clang-tidy-0.1.0-beta.1> 493 | auto doVerify(const std::string & token, std::chrono::system_clock::time_point now) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/options.hh:21:8: error: constructor does not initialize these fields: idleTimeout, storeUri, tlsCert, tlsKey, clientCA, metricsListen, workerName, oidcConfig, schedulerAddr, schedulerTokenFile, advertise, storeDir [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Options nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string listen = "0.0.0.0:50051"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | std::optional idleTimeout; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | std::string socketPath = "/nix/var/nix/daemon-socket/socket"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | // Store URI for the native bulk RPCs. Defaults to the proxy socket. nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | std::string storeUri; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | std::string tlsCert; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string tlsKey; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | std::string clientCA; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | std::string metricsListen; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | std::string workerName; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | LogLevel logLevel = LogLevel::info; nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | Acl acl; nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | xfcc::TrustedProxies proxies; nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | std::string oidcConfig; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:61:5: error: constructor does not initialize these fields: argv, state, writeMutex, reader [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 61 | explicit PushProcess(Argv argv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:10: error: method 'pushWait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:19: error: 2 adjacent parameters of 'pushWait' of similar type ('const int &') are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:52: note: the first parameter in the range is 'paths' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:86:77: note: the last parameter in the range is 'cancelled' nix-grpc-store-clang-tidy-0.1.0-beta.1> 86 | auto pushWait(const std::vector & paths, const Cancelled & cancelled = never) -> Signatures nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:123:16: error: constructor does not initialize these fields: message, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 123 | struct Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 124 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 125 | std::string status = "ok"; nix-grpc-store-clang-tidy-0.1.0-beta.1> 126 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 127 | Signatures signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:130:9: error: constructor does not initialize these fields: sync, done [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 130 | explicit Pending(size_t count) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:136:16: error: constructor does not initialize these fields: status, message, path, signatures [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 136 | struct Ack nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 137 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 138 | std::string status; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 139 | std::string message; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 140 | std::string path; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 141 | std::set signatures; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:144:14: error: method 'ack' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 144 | auto ack(Ack msg) -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:147:37: error: repeated branch body in conditional chain [bugprone-branch-clone,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 147 | if (msg.status != "ok") { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:14: note: end of the original nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:150:49: note: clone 1 starts here nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | } else if (!msg.signatures.empty()) { nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:162:14: error: method 'fail' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 162 | void fail(const std::string & message) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:171:14: error: method 'wait' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 171 | auto wait(const Cancelled & cancelled) -> Result nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:184:16: error: constructor does not initialize these fields: left [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 184 | struct Inner nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 185 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 186 | size_t left; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:193:12: error: constructor does not initialize these fields: stdinFd [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | struct State nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 195 | nix::Pid pid; nix-grpc-store-clang-tidy-0.1.0-beta.1> 196 | std::shared_ptr stdinFd; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:206:10: error: method 'ensureChild' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | void ensureChild(nix::Sync::WriteLock & lck) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/push.hh:237:10: error: method 'readAcks' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 237 | void readAcks(int acksFd) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:28:8: error: constructor does not initialize these fields: queue [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | struct SendQueue nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | // About a minute of Expects at full rate. Beyond it the peer is stuck. nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | static constexpr size_t limit = 1U << 16U; nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | // Messages per Write. nix-grpc-store-clang-tidy-0.1.0-beta.1> 33 | static constexpr int maxBatch = 1024; nix-grpc-store-clang-tidy-0.1.0-beta.1> 34 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 35 | // Leaf lock, may be taken inside Dispatcher::mutex. nix-grpc-store-clang-tidy-0.1.0-beta.1> 36 | absl::Mutex mutex; nix-grpc-store-clang-tidy-0.1.0-beta.1> 37 | std::deque queue ABSL_GUARDED_BY(mutex); nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:58:5: error: constructor does not initialize these fields: sendq [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | explicit SchedReactorBase(grpc::CallbackServerContext * ctx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:69:13: error: variable 'kick' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | bool kick = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:153:9: error: variable 'have' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 153 | bool have = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:183:9: error: variable 'fin' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 183 | bool fin = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:206:5: error: constructor does not initialize these fields: client [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 206 | ScheduleReactor(grpc::CallbackServerContext * ctx, Dispatcher & disp) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:226:18: error: member 'disp' of type 'Dispatcher &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 226 | Dispatcher & disp; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/sched-reactor.hh:255:18: error: member 'disp' of type 'Dispatcher &' is a reference [cppcoreguidelines-avoid-const-or-ref-data-members,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 255 | Dispatcher & disp; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:65:7: error: constructor does not initialize these fields: pos [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | class IndexedHeap nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 66 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 67 | std::vector> heap; nix-grpc-store-clang-tidy-0.1.0-beta.1> 68 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: error: 2 adjacent parameters of 'place' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:23: note: the first parameter in the range is 'idx' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:53: note: the last parameter in the range is 'item' nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:16: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:71:28: note: 'size_t' and 'int' may be implicitly converted: 'size_t' (as 'unsigned long') -> 'int', 'int' -> 'size_t' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 71 | void place(size_t idx, std::pair item) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:77:10: error: method 'siftUp' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 77 | void siftUp(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:91:10: error: method 'siftDown' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 91 | void siftDown(size_t idx) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:94:22: error: variable 'len' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 94 | const size_t len = heap.size(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:20: note: the first parameter in the range is 'drv' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:32: note: the last parameter in the range is 'key' nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:131:25: note: 'DrvId' and 'double' may be implicitly converted: 'DrvId' (as 'unsigned int') -> 'double', 'double' -> 'DrvId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 131 | void set(DrvId drv, double key) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:174:7: error: constructor does not initialize these fields: free, pos, tracked [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 174 | class FreeIndex nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 175 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 176 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 177 | static constexpr int32_t maxSlots = 63; nix-grpc-store-clang-tidy-0.1.0-beta.1> 178 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 179 | private: nix-grpc-store-clang-tidy-0.1.0-beta.1> 180 | std::vector free; // may go negative (draining below running) nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 181 | std::vector pos; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 182 | std::vector tracked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:191:10: error: method 'check' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 191 | void check(WorkerId wid) const nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: error: 2 adjacent parameters of 'set' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:23: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:36: note: the last parameter in the range is 'val' nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:14: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:221:28: note: 'WorkerId' and 'int32_t' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int32_t' (as 'int'), 'int32_t' (as 'int') -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 221 | void set(WorkerId wid, int32_t val) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:272:8: error: constructor does not initialize these fields: clients [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 272 | struct Assign nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 273 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 274 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 275 | WorkerId worker = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 276 | uint64_t assignId = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 277 | std::vector clients; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:280:8: error: constructor does not initialize these fields: drvPath, inputs, system, features, followers [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 280 | struct Entry nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 281 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 282 | std::string drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 283 | std::vector inputs; // for locality only nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 284 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 285 | std::vector features; // required nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 286 | std::vector followers; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:293:8: error: constructor does not initialize these fields: addr, systems, features, running [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | struct Worker nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 294 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 295 | std::string addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | std::vector systems; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 297 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 298 | int32_t maxJobs = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> 299 | bool up = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 300 | bool draining = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> 301 | std::vector running; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:307:5: error: constructor does not initialize these fields: drvIds, freeIds, workerIds, workers, systems [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 307 | explicit Core(Config cfg = {}) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:317:10: error: method 'drvId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 317 | auto drvId(std::string_view path) -> DrvId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:323:9: error: variable 'drv' of type 'DrvId' (aka 'unsigned int') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 323 | DrvId drv = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:338:24: error: method 'findDrv' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 338 | [[nodiscard]] auto findDrv(std::string_view path) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:344:10: error: method 'workerId' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 344 | auto workerId(std::string_view addr) -> WorkerId nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:365:24: error: method 'queued' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 365 | [[nodiscard]] auto queued() const -> size_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:367:9: error: variable 'total' of type 'size_t' (aka 'unsigned long') can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 367 | size_t total = 0; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:385:12: error: constructor does not initialize these fields: drvPath, inputs, system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 385 | struct WantInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 386 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 387 | std::string_view drvPath; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 388 | std::vector inputs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 389 | std::string_view system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 390 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:395:10: error: method 'want' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 395 | auto want(ClientId client, WantInfo info, double nowMs) -> WantResult nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:10: error: method 'cancel' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: error: 2 adjacent parameters of 'cancel' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:26: note: the first parameter in the range is 'client' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:51: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:17: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:429:34: note: 'ClientId' and 'int' may be implicitly converted: 'ClientId' (as 'unsigned long') -> 'int', 'int' -> 'ClientId' (as 'unsigned long') nix-grpc-store-clang-tidy-0.1.0-beta.1> 429 | auto cancel(ClientId client, std::string_view drvPath) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:10: error: method 'clientGone' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:463:76: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 463 | void clientGone(ClientId client, std::vector> & revokes) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:478:12: error: constructor does not initialize these fields: addr, systems, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 478 | struct HelloInfo nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 479 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 480 | std::string_view addr; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 481 | std::vector systems; // first is the native one nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 482 | std::vector features; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: error: 2 adjacent parameters of 'done' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:19: note: the first parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:41: note: the last parameter in the range is 'drvPath' nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:10: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:24: note: 'WorkerId' and 'int' may be implicitly converted: 'WorkerId' (as 'unsigned int') -> 'int', 'int' -> 'WorkerId' (as 'unsigned int') nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:539:105: error: all parameters should be named in a function [readability-named-parameter,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 539 | done(WorkerId wid, std::string_view drvPath, const std::vector> & outputs) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | /*unused*/ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:604:24: error: method 'placeable' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 604 | [[nodiscard]] auto placeable(DrvId drv) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:610:12: error: constructor does not initialize these fields: system, features [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 610 | struct StatsKey nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 611 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 612 | std::string system; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 613 | std::string features; // sorted, comma-joined nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:704:10: error: method 'retire' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 704 | void retire(DrvId drv) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:10: error: method 'rememberBuilder' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: error: 2 adjacent parameters of 'rememberBuilder' of convertible types are easily swapped by mistake [bugprone-easily-swappable-parameters,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:43: note: the first parameter in the range is 'path' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:58: note: the last parameter in the range is 'wid' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:26: note: nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:716:49: note: 'int' and 'WorkerId' may be implicitly converted: 'int' -> 'WorkerId' (as 'unsigned int'), 'WorkerId' (as 'unsigned int') -> 'int' nix-grpc-store-clang-tidy-0.1.0-beta.1> 716 | void rememberBuilder(std::string_view path, WorkerId wid, uint64_t size) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:774:24: error: method 'freeOf' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 774 | [[nodiscard]] auto freeOf(WorkerId wid) const -> int32_t nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:784:10: error: method 'refreshFree' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 784 | void refreshFree(WorkerId wid) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:810:24: error: method 'emptiestFor' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 810 | [[nodiscard]] auto emptiestFor(const Entry & ent) const -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/scheduler.hh:865:16: error: narrowing conversion from 'WorkerId' (aka 'unsigned int') to signed type 'int' is implementation-defined [bugprone-narrowing-conversions,cppcoreguidelines-narrowing-conversions,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 865 | return picked; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:21:12: error: constructor does not initialize these fields: token [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | struct Cached nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | std::string token; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:39:5: error: constructor does not initialize these fields: path, cached [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 19 | nix::Sync cached; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 20 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 21 | static auto mtime(const struct stat & info) -> struct timespec nix-grpc-store-clang-tidy-0.1.0-beta.1> 22 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | #ifdef __APPLE__ nix-grpc-store-clang-tidy-0.1.0-beta.1> 24 | return info.st_mtimespec; nix-grpc-store-clang-tidy-0.1.0-beta.1> 25 | #else nix-grpc-store-clang-tidy-0.1.0-beta.1> 26 | return info.st_mtim; nix-grpc-store-clang-tidy-0.1.0-beta.1> 27 | #endif nix-grpc-store-clang-tidy-0.1.0-beta.1> 28 | } nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | explicit TokenFile(std::string path_) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/token-file.hh:46:10: error: method 'get' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 46 | auto get() -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:32:5: error: constructor does not initialize these fields: rest [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 29 | std::string_view rest; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> 30 | nix-grpc-store-clang-tidy-0.1.0-beta.1> 31 | public: nix-grpc-store-clang-tidy-0.1.0-beta.1> 32 | explicit Cursor(std::string_view input) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:47:10: error: method 'take' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 47 | auto take() -> char nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:52:20: error: variable 'chr' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | char const chr = rest.front(); nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:58:10: error: method 'until' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 58 | auto until(std::string_view stops) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:69:10: error: method 'remaining' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 69 | auto remaining() -> std::string_view nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:150:13: error: variable 'subjectCommonName' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 150 | inline auto subjectCommonName(std::string_view value) -> std::optional nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:192:7: error: constructor does not initialize these fields: patterns [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 192 | class TrustedProxies nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> 193 | { nix-grpc-store-clang-tidy-0.1.0-beta.1> 194 | std::vector patterns; nix-grpc-store-clang-tidy-0.1.0-beta.1> | nix-grpc-store-clang-tidy-0.1.0-beta.1> | {} nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:197:10: error: method 'add' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 197 | void add(std::string_view pattern) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/daemon/xfcc.hh:210:24: error: method 'matches' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 210 | [[nodiscard]] auto matches(const std::optional & peerCommonName) const -> bool nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:81:10: error: method 'header' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 81 | void header(const std::string & line) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:101:5: error: constructor does not initialize these fields: curl, headers, url, payload, body_ [cppcoreguidelines-pro-type-member-init,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 65 | Call(std::string url_, const std::string & bearer, const std::optional & body) nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 129 | auto perform() -> long nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ ~~~~~ nix-grpc-store-clang-tidy-0.1.0-beta.1> | static nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 23 | inline auto logfmtValue(std::string_view value) -> std::string nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 52 | enum class LogLevel : std::uint8_t { info, debug }; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 293 | bool dynamic = false; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | const nix-grpc-store-clang-tidy-0.1.0-beta.1> ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] nix-grpc-store-clang-tidy-0.1.0-beta.1> 296 | nix::StorePathSet srcs; nix-grpc-store-clang-tidy-0.1.0-beta.1> | ^ nix-grpc-store-clang-tidy-0.1.0-beta.1> | = 0 nix-grpc-store-clang-tidy-0.1.0-beta.1> FAILED: [code=1] meson-internal__clang-tidy nix-grpc-store-clang-tidy-0.1.0-beta.1> /nix/store/jaa89dphx07w3r26y7gh79a7b1mld5p4-meson-1.10.2/bin/meson --internal clangtidy /build/source /build/source/build --color always nix-grpc-store-clang-tidy-0.1.0-beta.1> ninja: build stopped: subcommand failed. error: Cannot build '/nix/store/81wkz1k0mhlb9sdjndlfinm0f657vy9b-nix-grpc-store-clang-tidy-0.1.0-beta.1.drv'. Reason: builder failed with exit code 1. Output paths: /nix/store/m5g1qc4aqq6gsans1lpvlgn09q4w271z-nix-grpc-store-clang-tidy-0.1.0-beta.1 Last 25 log lines: > ../src/http.hh:129:10: error: method 'perform' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] > 129 | auto perform() -> long > | ^ > | static > ../src/http.hh:145:24: error: method 'retryAfter' can be made static [readability-convert-member-functions-to-static,-warnings-as-errors] > 145 | [[nodiscard]] auto retryAfter() const -> std::chrono::seconds > | ^ ~~~~~ > | static > ../src/logfmt.hh:23:13: error: variable 'logfmtValue' is non-const and globally accessible, consider making it const [cppcoreguidelines-avoid-non-const-global-variables,-warnings-as-errors] > 23 | inline auto logfmtValue(std::string_view value) -> std::string > | ^ > ../src/logfmt.hh:52:12: error: enum 'LogLevel' uses a larger base type ('int', size: 4 bytes) than necessary for its value set, consider using 'std::uint8_t' (1 byte) as the base type to reduce its size [performance-enum-size,-warnings-as-errors] > 52 | enum class LogLevel : std::uint8_t { info, debug }; > | ^ > ../src/nix-compat.hh:293:3: error: variable 'dynamic' of type 'bool' can be declared 'const' [misc-const-correctness,-warnings-as-errors] > 293 | bool dynamic = false; > | ^ > | const > ../src/nix-compat.hh:296:23: error: variable 'srcs' is not initialized [cppcoreguidelines-init-variables,-warnings-as-errors] > 296 | nix::StorePathSet srcs; > | ^ > | = 0 > FAILED: [code=1] meson-internal__clang-tidy > /nix/store/jaa89dphx07w3r26y7gh79a7b1mld5p4-meson-1.10.2/bin/meson --internal clangtidy /build/source /build/source/build --color always > ninja: build stopped: subcommand failed. For full logs, run: nix log /nix/store/81wkz1k0mhlb9sdjndlfinm0f657vy9b-nix-grpc-store-clang-tidy-0.1.0-beta.1.drv