Skip to content

feat: Add binary signatures and multiple os package improvements #7297

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 46 commits into from
Jul 15, 2025

Conversation

ausias-armesto
Copy link
Contributor

@ausias-armesto ausias-armesto commented Jul 10, 2025

This Pr provide:

  • pipeline enhancements
  • New feature to launch the generation of the Homebrew Formula at https://github.com/hoprnet/homebrew-hoprd
  • Binary signatures
  • Remove labels while releasing, like load tests
  • Rename linux packages to be compliant with debian format
  • Add most of lintian suggestions so the package is debian compliant
  • Improve install and uninstall scripts of the linux package
  • Generate the changelog in different formats (github, debian, rpm)

@Copilot Copilot AI review requested due to automatic review settings July 10, 2025 09:42
Copy link
Contributor

coderabbitai bot commented Jul 10, 2025

📝 Walkthrough

"""

Walkthrough

This set of changes introduces major improvements to packaging, release, and workflow automation. It refactors packaging scripts, enhances changelog generation, updates workflow files for more flexible packaging and artifact signing, and revises documentation and installation scripts. Several new scripts are added for pre/post install/uninstall logic, and artifact handling is made more robust and secure.

Changes

Files/Group Change Summary
.github/workflows/build-binaries.yaml Refactored artifact upload to include cryptographic signing, SHA256 hashing, and dynamic artifact naming; indentation fix for case statement.
.github/workflows/build.yaml Added matrix for packager (deb/rpm/archlinux) and file extensions; updated job names and inputs for packaging workflow.
.github/workflows/close-release.yaml Removed "singapore" release option; simplified changelog generation; updated PR label list.
.github/workflows/create-release.yaml Moved changelog generation earlier; changed asset upload path; added repository dispatch to Homebrew tap; improved milestone closing logic.
.github/workflows/package.yaml Added required packager and extension inputs; concurrency per packager; updated artifact naming and upload; consolidated package testing.
.gitignore Added ignore rules for deploy/nfpm/changelog* and privatekey.asc.
deploy/nfpm/README.md Updated package download/install instructions, filenames, URLs, and added environment variable setup guidance.
deploy/nfpm/copyright New copyright file for Debian packaging, specifying license and project metadata.
deploy/nfpm/hoprd-sample.cfg.yaml Changed database data directory path.
deploy/nfpm/nfpm.yaml Expanded metadata, updated maintainer, improved descriptions, added dependencies, permissions, and documentation files; added script hooks.
deploy/nfpm/package-post-install.sh Refactored to remove user prompts; added default env vars and log level; improved file permissions and identity validation.
deploy/nfpm/package-post-uninstall.sh New script for post-uninstall cleanup (user/group and directory removal).
deploy/nfpm/package-pre-install.sh New script for pre-install environment validation (env vars, config, RPC provider, network, identity password).
deploy/nfpm/package-pre-uninstall.sh Simplified to only stop/disable service and reload systemd; removed user/group and directory deletion logic.
deploy/nfpm/test-package-tool.sh Updated GCP project/zone/network; improved image selection by architecture; fixed file permission handling on VM.
justfile Renamed/removed packaging recipes; added changelog generation and improved Debian changelog handling; skip Arch Linux ARM64 tests.
scripts/download-workflow-binaries.sh Refactored to extract all zips to a temp dir and move by extension; removed per-platform grouping/zipping.
scripts/generate-changelog.sh Major rewrite: new parameters, dynamic milestone lookup, structured entry processing, multiple output formats (GitHub, JSON, Debian, RPM), improved metadata extraction, and error handling.
flake.nix Excluded two files from treefmt formatting checks; added sign-file app for GPG signing of files.
nix/ciShell.nix Added gnupg and perl to shell packages.
deploy/nfpm/install-hoprd-package.sh Enabled errtrace, reduced error trap sleep, and prefixed Debian install commands with sudo.

Sequence Diagram(s)

sequenceDiagram
    participant GitHub Actions
    participant Packaging Script
    participant GPG
    participant Artifact Store

    GitHub Actions->>Packaging Script: Build binary for target
    Packaging Script->>Packaging Script: Rename/copy binary with target suffix
    Packaging Script->>GPG: Import private key, sign binary, generate SHA256 hash, sign hash
    Packaging Script->>Artifact Store: Upload binary, signature, hash, hash signature
Loading
sequenceDiagram
    participant User
    participant Pre-Install Script
    participant System

    User->>Pre-Install Script: Run package-pre-install.sh
    Pre-Install Script->>System: Check env vars, config, RPC provider, network, identity password
    Pre-Install Script-->>User: Error and exit if validation fails
    Pre-Install Script-->>System: Allow install if all checks pass
Loading
sequenceDiagram
    participant GitHub Actions
    participant Changelog Script
    participant GitHub API

    GitHub Actions->>Changelog Script: Generate changelog (with version/format)
    Changelog Script->>GitHub API: Query milestones/issues/PRs
    GitHub API-->>Changelog Script: Return data
    Changelog Script->>GitHub Actions: Output formatted changelog
Loading

Possibly related PRs

  • hoprnet/hoprnet#7277: Adds ArchLinux packaging support and testing steps in CI workflows, related to packaging and testing improvements.
  • hoprnet/hoprnet#7251: Introduces initial packaging workflow and job for multiple Linux targets, related to packaging workflows and artifact handling.
  • hoprnet/hoprnet#6681: Modifies .github/workflows/build-binaries.yaml focusing on manual triggering and inputs, related to build workflow changes.

Suggested labels

binary:x86_64-linux, docker-production-build, smart-contracts

Suggested reviewers

  • Teebor-Choka
  • tolbrino
    """

📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between cccdfef and 35a1d64.

📒 Files selected for processing (1)
  • flake.nix (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (1)
  • flake.nix
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Lint / Lint
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: Docs / Rust

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate docstrings to generate docstrings for this PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@ausias-armesto ausias-armesto self-assigned this Jul 10, 2025
@ausias-armesto ausias-armesto added binary:x86_64-linux Build x86_64-linux binary binary:aarch64-darwin Build aarch64-darwin binary binary:x86_64-darwin Build x86_64-darwin binary labels Jul 10, 2025
@github-actions github-actions bot added dependencies Pull requests that update a dependency file toolchain Developer and product happiness crate:hopr-lib labels Jul 10, 2025
Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR enhances the release pipeline and adds a Homebrew formula for macOS installations of hoprd.

  • Revamped the generate-changelog.sh script to produce GitHub, JSON, Debian, and RPM formats with entry validation.
  • Integrated changelog generation into the Justfile packaging steps and updated nfpm configurations.
  • Added Debian pre/post install/uninstall scripts and a new Homebrew formula (hoprd.rb), plus workflow updates for artifact naming.

Reviewed Changes

Copilot reviewed 15 out of 18 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
scripts/generate-changelog.sh Rework changelog generator to support multiple formats and metadata extraction
justfile Integrate changelog generation into packaging pipeline
hopr/hopr-lib/Cargo.toml Bump library version from 3.0.0-rc.1 to 3.0.0
deploy/nfpm/test-package-tool.sh Update GCP zone, network defaults, and ARM image selection logic
deploy/nfpm/package-pre-uninstall.sh Simplify pre-uninstall logic, switch to Bash, and silence service commands
deploy/nfpm/package-pre-install.sh Add environment variable checks and validations before install
deploy/nfpm/package-post-uninstall.sh Introduce post-uninstall script to remove user/group and data folders
deploy/nfpm/package-post-install.sh Enhance post-install: merge safe/module vars, add log-level, tighten permissions, reorganize flow
deploy/nfpm/nfpm.yaml Extend nfpm metadata (sections, file_info), update maintainer, and hook pre/post scripts
deploy/nfpm/hoprd-sample.cfg.yaml Adjust default data directory path
deploy/nfpm/copyright Add Debian copyright file
deploy/nfpm/README.md Update install/uninstall instructions, sync file naming, and fix URLs
deploy/Formula/hoprd.rb Add Homebrew formula for macOS (hoprd and hopli)
.github/workflows/package.yaml Generate dynamic artifact names with version & arch
.github/workflows/close-release.yaml Remove obsolete load_tests label from release workflow
Comments suppressed due to low confidence (6)

deploy/nfpm/nfpm.yaml:76

  • postremove invokes the pre-uninstall script. It should call package-post-uninstall.sh to clean up user/group and data as intended.
  postremove: ./deploy/nfpm/package-pre-uninstall.sh

deploy/nfpm/README.md:43

  • The downloaded RPM file is named hoprd_${arch}.rpm but this command installs hoprd-${arch}-linux.rpm, causing a mismatch. Update the install command to match the downloaded filename.
sudo -E dnf install -y ./hoprd-${arch}-linux.rpm

deploy/nfpm/README.md:64

  • The downloaded Arch package is named hoprd_${arch}.pkg.tar.zst, but the install command uses hoprd-${arch}-linux.pkg.tar.zst. Align these filenames.
sudo pacman --noconfirm -U hoprd-${arch}-linux.pkg.tar.zst

.github/workflows/package.yaml:79

  • Typo in the artifact prefix: hord_ should be hoprd_ to match the project name.
          echo "package_file_name=hord_${current_version}_${architecture}" | tee -a $GITHUB_OUTPUT

scripts/generate-changelog.sh:81

  • The section_performance+"..." line is missing the = for appending. It should be section_performance+="* ${title} by @${author} in #${id}\n" so entries are actually added.
      section_performance+"* ${title} by @${author} in #${id}\n"

deploy/nfpm/package-post-install.sh:1

  • [nitpick] Replacing #!/usr/bin/env bash with #!/bin/bash can reduce portability. Consider reverting or ensuring /bin/bash exists on all targets.
#!/bin/bash

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 16

🔭 Outside diff range comments (1)
deploy/nfpm/README.md (1)

70-70: Fix incorrect pacman uninstall command.

The command pacman del is not valid. Use pacman -R for removal.

-sudo pacman del hoprd
+sudo pacman -R hoprd
♻️ Duplicate comments (5)
deploy/nfpm/package-pre-uninstall.sh (1)

1-2: Strict mode still omits -u.
Same concern raised previously: unset vars won’t abort.

deploy/nfpm/package-post-uninstall.sh (1)

2-2: Add the -u flag for unset variable detection.

The script is missing -u in its strict mode flags to catch unset variables.

-set -Eeo pipefail
+set -Eeuo pipefail
deploy/nfpm/README.md (1)

16-16: Typo in addres. It should be address.

deploy/nfpm/package-pre-install.sh (1)

1-1: Add set -euo pipefail for better error handling.

deploy/Formula/hoprd.rb (1)

143-143: Remove duplicate mkpath call.

🧹 Nitpick comments (10)
.gitignore (1)

212-214: Pattern looks good, but scope-check the wildcard.

deploy/nfpm/changelog* will also match something like deploy/nfpm/changelog-generator.py.
If you only intend to ignore the generated markdown/plain-text changelogs (e.g. changelog, changelog.md), narrow the pattern:

-deploy/nfpm/changelog*
+deploy/nfpm/changelog*
+!deploy/nfpm/changelog-generator.py   # keep scripts

Optional but keeps unrelated files in git if you add tooling later.

hopr/hopr-lib/Cargo.toml (1)

3-3: Version bump acknowledged — ensure workspace metadata updated.

All downstream crates that depend on hopr-lib = { version = "3.0.0-rc.1" … } must be updated (or use workspace = true).
No action if the workspace root handles publishing, but worth a grep before tagging the release.

deploy/Formula/README.md (2)

1-1: Markdown heading missing space

# Homebrew Formula lacks a space after the hash, violating MD018 and rendering oddly in some viewers.

-# Homebrew Formula
+# Homebrew Formula

12-16: Use fenced blocks consistently

The instructions mix bash code fences with inline commands. Wrapping the whole install snippet in one fenced block improves readability.

Minor, but keeps the doc polished.

.github/workflows/build-binaries.yaml (1)

137-144: New publish-artifact action – ensure secrets & pinning

Great move to a signed publish step. Two points:

  1. hoprnet/hopr-workflows/actions/publish-artifact@ausias/publish-gcp-artifact is referenced by branch, not commit hash – this weakens supply-chain immutability.
  2. The action requires GPG_PRIVATE_KEY; confirm the secret is configured in all repositories/environments that trigger this workflow, or the build will fail late.

Pin to a commit SHA and document the secret requirement in the workflow description.

deploy/nfpm/package-pre-install.sh (2)

49-49: Simplify redundant condition check.

The ! -z test is redundant when checking specific values.

-  if [ ! -z "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
+  if [[ -n "${HOPRD_NETWORK}" && "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then

57-57: Fix grammar in error message.

-      errors+="- There is an existing identity file at /etc/hoprd/hopr.id from previous installation, You have to provide its password via 'HOPRD_PASSWORD' environment variable or delete the identity file.\n"
+      errors+="- There is an existing identity file at /etc/hoprd/hopr.id from previous installation. You have to provide its password via 'HOPRD_PASSWORD' environment variable or delete the identity file.\n"
scripts/generate-changelog.sh (2)

101-101: Separate variable declaration from assignment to avoid masking return values.

Shellcheck recommends declaring and assigning separately to catch command failures.

For line 101:

-  local change_log_content="$(printf '%s\n' "${changelog_entries[@]}" | jq -s -c '.')"
+  local change_log_content
+  change_log_content="$(printf '%s\n' "${changelog_entries[@]}" | jq -s -c '.')"

Apply similar changes to lines 142-145.

Also applies to: 142-145


229-229: Enhance comment about Arch Linux changelog format.

-  deb|archlinux) # archlinux does not have a specific format, we will use the debian format
+  deb|archlinux) # Arch Linux packages don't have a standard changelog format, so we use Debian format for consistency
deploy/Formula/hoprd.rb (1)

366-369: Use Ruby naming conventions.

Ruby uses snake_case for variables, not camelCase.

-    isInvalid = address.nil? || address.empty? || address == "0x0000000000000000000000000000000000000000"
-    isValid = address.match?(/\A0x[a-fA-F0-9]{40}\z/)
-    return isValid && !isInvalid
+    is_invalid = address.nil? || address.empty? || address == "0x0000000000000000000000000000000000000000"
+    is_valid = address.match?(/\A0x[a-fA-F0-9]{40}\z/)
+    return is_valid && !is_invalid
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 943af8f and 2c7ffb0.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (20)
  • .github/workflows/build-binaries.yaml (2 hunks)
  • .github/workflows/close-release.yaml (1 hunks)
  • .github/workflows/create-release.yaml (1 hunks)
  • .github/workflows/package.yaml (3 hunks)
  • .gitignore (1 hunks)
  • deploy/Formula/README.md (1 hunks)
  • deploy/Formula/hoprd.rb (1 hunks)
  • deploy/nfpm/README.md (3 hunks)
  • deploy/nfpm/copyright (1 hunks)
  • deploy/nfpm/hoprd-sample.cfg.yaml (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/package-pre-uninstall.sh (1 hunks)
  • deploy/nfpm/test-package-tool.sh (2 hunks)
  • hopr/hopr-lib/Cargo.toml (1 hunks)
  • justfile (2 hunks)
  • scripts/download-workflow-binaries.sh (1 hunks)
  • scripts/generate-changelog.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (20)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
.gitignore (4)
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-09-25T14:16:43.307Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
deploy/nfpm/package-pre-uninstall.sh (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
scripts/download-workflow-binaries.sh (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
deploy/nfpm/package-post-uninstall.sh (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
.github/workflows/close-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
.github/workflows/create-release.yaml (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/hoprd-sample.cfg.yaml (3)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
deploy/nfpm/copyright (4)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
hopr/hopr-lib/Cargo.toml (13)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6531
File: hopr/hopr-lib/src/lib.rs:1110-1132
Timestamp: 2024-11-03T20:57:55.015Z
Learning: In `hopr/hopr-lib/src/lib.rs`, the `establish_max_retries` field is of type `u32`, so it cannot be negative. Therefore, handling negative values for this configuration parameter is unnecessary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6313
File: hopr/hopr-lib/src/lib.rs:0-0
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The types `IndexerTransportEvent`, `Network`, `PeerEligibility`, and `PeerOrigin` in the `hopr/hopr-lib/src/lib.rs` file are internal to the transport mechanism and do not require public documentation.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-09-28T21:05:38.392Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
.github/workflows/package.yaml (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/Formula/README.md (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
justfile (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
deploy/nfpm/nfpm.yaml (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/nfpm/README.md (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: hopr/hopr-lib/src/lib.rs:564-564
Timestamp: 2024-10-21T15:15:11.701Z
Learning: In `hopr/hopr-lib/src/lib.rs`, when adding configuration options like `fast_sync` to `IndexerConfig`, inline code comments are not necessary if the feature is documented elsewhere.
deploy/nfpm/package-pre-install.sh (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
.github/workflows/build-binaries.yaml (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6651
File: nix/rust-package.nix:35-39
Timestamp: 2024-11-20T08:43:53.099Z
Learning: In the `nix/rust-package.nix` file, replacing hardcoded interpreter paths with `${stdenv.hostPlatform.platform.dynamicLinker}` doesn't work as intended, so hardcoded interpreter paths are necessary.
deploy/Formula/hoprd.rb (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
scripts/generate-changelog.sh (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/package-post-install.sh (15)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
🧬 Code Graph Analysis (1)
deploy/nfpm/package-post-install.sh (1)
deploy/Formula/hoprd.rb (1)
  • generate_identity_file (305-343)
🪛 markdownlint-cli2 (0.17.2)
deploy/Formula/README.md

1-1: No space after hash on atx style heading

(MD018, no-missing-space-atx)

🪛 Brakeman (7.0.2)
deploy/Formula/hoprd.rb

[medium] 50-50: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 28-28: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 35-35: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 60-60: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 53-53: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 171-171: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 57-57: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 38-38: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 31-31: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 73-73: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 19-19: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 12-12: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 346-346: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 322-322: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 22-22: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 69-69: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 76-76: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 172-172: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 66-66: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 15-15: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)

🪛 RuboCop (1.75.5)
deploy/Formula/hoprd.rb

[convention] 84-150: Assignment Branch Condition size for install is too high. [<1, 38, 1> 38.03/23]

(Metrics/AbcSize)


[convention] 240-262: Assignment Branch Condition size for generate_env_vars is too high. [<16, 19, 14> 28.51/23]

(Metrics/AbcSize)


[convention] 240-262: Cyclomatic complexity for generate_env_vars is too high. [14/7]

(Metrics/CyclomaticComplexity)


[convention] 240-262: Perceived complexity for generate_env_vars is too high. [15/8]

(Metrics/PerceivedComplexity)


[convention] 305-343: Assignment Branch Condition size for generate_identity_file is too high. [<12, 29, 7> 32.16/23]

(Metrics/AbcSize)


[warning] 312-312: Useless assignment to variable - success.

(Lint/UselessAssignment)


[warning] 386-386: Useless assignment to variable - stderr. Use _ or _stderr as a variable name to indicate that it won't be used.

(Lint/UselessAssignment)


[convention] 405-446: Assignment Branch Condition size for show_installation_summary is too high. [<1, 31, 4> 31.27/23]

(Metrics/AbcSize)

🪛 Shellcheck (0.10.0)
scripts/generate-changelog.sh

[warning] 58-58: section_performance appears unused. Verify use (or export if used externally).

(SC2034)


[warning] 101-101: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 129-129: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 142-142: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 143-143: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 145-145: Declare and assign separately to avoid masking return values.

(SC2155)

deploy/nfpm/package-post-install.sh

[warning] 193-193: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (14)
  • GitHub Check: tests-smoke (rest_api)
  • GitHub Check: tests-smoke (win_prob)
  • GitHub Check: tests-smoke (redeeming)
  • GitHub Check: tests-smoke (integration)
  • GitHub Check: tests-smoke (websocket_api)
  • GitHub Check: tests-smoke (session)
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: hopli-aarch64-darwin / binary
  • GitHub Check: hoprd-x86_64-linux / binary
  • GitHub Check: hopli-x86_64-darwin / binary
  • GitHub Check: hoprd-aarch64-darwin / binary
  • GitHub Check: hoprd-x86_64-darwin / binary
  • GitHub Check: tests-unit
  • GitHub Check: tests-unit-nightly
🔇 Additional comments (16)
deploy/nfpm/hoprd-sample.cfg.yaml (1)

4-4: Verify runtime assumptions after data-dir change.

/var/lib/hoprd previously contained sub-folder data/. Double-check that:

  1. Post-install script creates /var/lib/hoprd with correct ownership.
  2. Application code does not append /data internally (would now resolve to /var/lib/hoprd/data again).

A quick grep through hoprd for "/var/lib/hoprd/data" call-sites is advisable.

.github/workflows/close-release.yaml (1)

85-88: load_tests label removed – double-check downstream label-based conditionals

Dropping load_tests cleans up the PR metadata here, but other workflows (e.g. build-matrix triggers or auto-label checks) might still look for that label.
Please grep the workflows for load_tests to ensure we don’t silently break conditional executions.

.github/workflows/create-release.yaml (1)

127-132: Path switch to dist/bin/* – make sure the directory is populated

The upload loop now targets ./dist/bin/*.
If scripts/download-workflow-binaries.sh or the packaging job fails to place files there, the loop will exit successfully but upload nothing, silently breaking the release artefacts.

Consider adding an explicit fail-if-empty guard:

-for artifact in ./dist/bin/* ./dist/packages/*; do
+shopt -s nullglob
+for artifact in ./dist/bin/* ./dist/packages/*; do
   …
 done
+[ "${#artifact[@]}" -gt 0 ] || { echo "❌ No artefacts found"; exit 1; }
deploy/nfpm/package-post-uninstall.sh (1)

17-18: LGTM! Good use of || true for safe directory removal.

The directory removal commands appropriately use || true to prevent script failure if directories don't exist.

deploy/nfpm/nfpm.yaml (3)

6-14: LGTM! Improved package metadata with detailed description.

The package metadata updates include a more descriptive multi-line description that clearly explains the HOPR node components and their purpose.


27-36: LGTM! Explicit file permissions enhance security.

Adding explicit file permissions and ownership for binaries is a good security practice that ensures consistent deployment across different systems.


54-61: LGTM! Added documentation files with proper packaging.

The addition of copyright and changelog files with appropriate packaging rules (deb-specific) follows Debian packaging standards.

justfile (2)

44-46: LGTM! Well-implemented changelog generation with format-specific handling.

The changelog generation logic correctly handles different packaging formats, with appropriate compression for Debian packages and license line removal for Debian-specific requirements.


60-63: LGTM! Smart conditional skip for unsupported architecture.

The conditional skip for archlinux aarch64-linux appropriately handles the current limitation in GCP images while providing clear feedback to users.

.github/workflows/package.yaml (2)

75-79: LGTM! Dynamic package naming improves artifact consistency.

The package file name generation logic correctly extracts version and architecture information, creating consistent naming across all package formats. The architecture suffix removal aligns with the expected naming conventions.


132-144: LGTM! Consistent artifact naming across all package types.

The artifact upload steps now use the dynamic package_file_name output, ensuring consistent naming for Debian, RPM, and Arch Linux packages.

deploy/nfpm/test-package-tool.sh (3)

6-10: LGTM! Infrastructure updates for better resource availability.

The zone and network changes move to more standard GCP configurations that should provide better resource availability and simpler networking setup.


15-31: LGTM! Architecture-specific VM image selection.

The enhanced get_vm_image function now correctly selects ARM64-specific images for aarch64-linux architecture, ensuring proper testing on the target platform.


48-48: LGTM! Consistent architecture naming.

The architecture check now uses "aarch64-linux" format, which aligns with the naming conventions used throughout the packaging system.

deploy/nfpm/package-pre-install.sh (1)

26-28: Fix logic error in RPC provider validation.

The condition should check if the file doesn't exist OR if it exists but doesn't contain the variable. Current logic with AND operator is incorrect.

-  if [ -f "/etc/hoprd/hoprd.env" ] && ! grep -q "^HOPRD_PROVIDER=" /etc/hoprd/hoprd.env; then
+  if [ ! -f "/etc/hoprd/hoprd.env" ] || ! grep -q "^HOPRD_PROVIDER=" /etc/hoprd/hoprd.env; then
⛔ Skipped due to learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6626
File: hoprd/rest-api/src/preconditions.rs:39-40
Timestamp: 2024-11-12T13:48:55.855Z
Learning: When reviewing authentication logic in Rust code (e.g., in `hoprd/rest-api/src/preconditions.rs`), ensure that path validations are explicit by naming all supported paths, instead of using permissive patterns like `contains`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6520
File: hopr/hopr-lib/src/lib.rs:682-688
Timestamp: 2024-10-15T19:23:49.668Z
Learning: In the `Hopr` struct, the `get_provider` method is called infrequently, so caching its result is not necessary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
deploy/nfpm/package-post-install.sh (1)

210-211: Confirm recursive ownership for /etc/hoprd, /var/lib/hoprd, and /var/log/hoprd

The change from

- chown -R hoprd:hoprd /etc/hoprd
- chown -R hoprd:hoprd /var/lib/hoprd /var/log/hoprd

to

chown hoprd:hoprd /etc/hoprd
chown hoprd:hoprd /var/lib/hoprd /var/log/hoprd

may miss nested directories if they’re ever created at runtime. We didn’t find any subdirectories in the repo, but these paths are populated when the package is installed. Please verify whether any subdirectories could appear under these directories; if so, revert to using chown -R to ensure ownership is applied recursively.

• File: deploy/nfpm/package-post-install.sh Lines: 210–211

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 13

🔭 Outside diff range comments (1)
deploy/nfpm/nfpm.yaml (1)

72-77: postremove script points to the wrong file

Responsibility for user/group & folder cleanup was moved to package-post-uninstall.sh, yet postremove still references package-pre-uninstall.sh.

-  postremove: ./deploy/nfpm/package-pre-uninstall.sh
+  postremove: ./deploy/nfpm/package-post-uninstall.sh
♻️ Duplicate comments (5)
deploy/nfpm/package-post-uninstall.sh (1)

2-2: Add the missing -u flag for stricter error handling.

The script should include the -u flag to catch unset variables, as noted in previous reviews.

-set -Eeo pipefail
+set -Eeuo pipefail
deploy/nfpm/package-pre-uninstall.sh (1)

2-2: Enable -u to fail on unset variables

Previous feedback still applies: set -Eeo pipefail omits -u. Add it to catch typos and missing env vars.

-set -Eeo pipefail
+set -Eeuo pipefail
deploy/nfpm/README.md (1)

16-16: Typo in addres. It should be address.

deploy/nfpm/package-pre-install.sh (1)

1-1: For better portability and error checking, add set -euo pipefail immediately after the shebang.

deploy/Formula/hoprd.rb (1)

142-143: Duplicate mkpath call for var/lib/hoprd appears one line earlier. Remove the redundant line to simplify the code.

🧹 Nitpick comments (11)
deploy/Formula/README.md (1)

1-1: Fix markdown formatting for the main heading.

Add a space after the hash for proper markdown formatting.

-# Homebrew Formula
+# Homebrew Formula
deploy/nfpm/test-package-tool.sh (1)

44-46: Avoid passing a parameter you never read

create_action calls get_vm_image "${DISTRIBUTION}", yet the function only references the global $DISTRIBUTION and ignores $1.
Either drop the argument at the call-site or switch the function to use $1 for clarity.

-get_vm_image() {
-  case "${DISTRIBUTION}" in
+get_vm_image() {
+  local distro=$1
+  case "${distro}" in
deploy/nfpm/nfpm.yaml (1)

54-61: Missing file permissions for hoprd.service

Systemd unit files should be world-readable; explicitly add file_info to avoid distro defaults differing.

-  - src: ./deploy/nfpm/hoprd.service
-    dst: /usr/lib/systemd/system/hoprd.service
+  - src: ./deploy/nfpm/hoprd.service
+    dst: /usr/lib/systemd/system/hoprd.service
+    file_info:
+      mode: 0644
+      owner: root
+      group: root
deploy/nfpm/package-pre-uninstall.sh (1)

6-7: daemon-reexec rarely needed here

systemctl daemon-reexec restarts PID 1 and is heavier than daemon-reload; for simple unit removal daemon-reload suffices and is faster.

.github/workflows/package.yaml (1)

45-53: Duplicate mkdir -p ./dist/bin

Lines 46 and 52 create the same directory. One is enough.

deploy/nfpm/package-pre-install.sh (1)

49-49: Simplify the condition check.

Use the more idiomatic -n test instead of ! -z.

-  if [ ! -z "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
+  if [ -n "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
deploy/nfpm/package-post-install.sh (1)

189-189: Remove extra space in the mv command.

There's an unnecessary space after the path.

-    mv /etc/hoprd/hopr0.id /etc/hoprd/hopr.id 
+    mv /etc/hoprd/hopr0.id /etc/hoprd/hopr.id
deploy/Formula/hoprd.rb (3)

8-9: Remove commented-out local file URLs.

Dead code should be removed rather than left commented.

Remove lines 8-9 and 46-47 entirely.

Also applies to: 46-47


312-312: Remove unused variable assignment.

The variable success is assigned but never used.

-        success = system("/bin/sh", "-c", cmd)
+        system("/bin/sh", "-c", cmd)

366-368: Follow Ruby naming conventions for variables.

Variable names should use snake_case instead of camelCase.

-    isInvalid = address.nil? || address.empty? || address == "0x0000000000000000000000000000000000000000"
-    isValid = address.match?(/\A0x[a-fA-F0-9]{40}\z/)
-    return isValid && !isInvalid
+    is_invalid = address.nil? || address.empty? || address == "0x0000000000000000000000000000000000000000"
+    is_valid = address.match?(/\A0x[a-fA-F0-9]{40}\z/)
+    return is_valid && !is_invalid
scripts/generate-changelog.sh (1)

96-96: Use printf instead of echo -e for better portability.

The -e flag for echo is not POSIX compliant and may not work in all shells.

-  echo -e ${change_log_content}
+  printf '%b\n' "${change_log_content}"

Apply similar changes to lines 102, 169, and 207.

Also applies to: 102-102, 169-169, 207-207

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 943af8f and 2c7ffb0.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (20)
  • .github/workflows/build-binaries.yaml (2 hunks)
  • .github/workflows/close-release.yaml (1 hunks)
  • .github/workflows/create-release.yaml (1 hunks)
  • .github/workflows/package.yaml (3 hunks)
  • .gitignore (1 hunks)
  • deploy/Formula/README.md (1 hunks)
  • deploy/Formula/hoprd.rb (1 hunks)
  • deploy/nfpm/README.md (3 hunks)
  • deploy/nfpm/copyright (1 hunks)
  • deploy/nfpm/hoprd-sample.cfg.yaml (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/package-pre-uninstall.sh (1 hunks)
  • deploy/nfpm/test-package-tool.sh (2 hunks)
  • hopr/hopr-lib/Cargo.toml (1 hunks)
  • justfile (2 hunks)
  • scripts/download-workflow-binaries.sh (1 hunks)
  • scripts/generate-changelog.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (21)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
deploy/nfpm/copyright (4)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
deploy/nfpm/package-pre-install.sh (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/Formula/README.md (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
deploy/nfpm/package-post-install.sh (15)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
scripts/download-workflow-binaries.sh (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
deploy/nfpm/package-pre-uninstall.sh (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
deploy/Formula/hoprd.rb (11)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
deploy/nfpm/nfpm.yaml (11)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/nfpm/test-package-tool.sh (1)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
.github/workflows/package.yaml (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
.gitignore (4)
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-09-25T14:16:43.307Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
deploy/nfpm/hoprd-sample.cfg.yaml (3)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
.github/workflows/close-release.yaml (7)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
hopr/hopr-lib/Cargo.toml (13)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6531
File: hopr/hopr-lib/src/lib.rs:1110-1132
Timestamp: 2024-11-03T20:57:55.015Z
Learning: In `hopr/hopr-lib/src/lib.rs`, the `establish_max_retries` field is of type `u32`, so it cannot be negative. Therefore, handling negative values for this configuration parameter is unnecessary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6313
File: hopr/hopr-lib/src/lib.rs:0-0
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The types `IndexerTransportEvent`, `Network`, `PeerEligibility`, and `PeerOrigin` in the `hopr/hopr-lib/src/lib.rs` file are internal to the transport mechanism and do not require public documentation.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-09-28T21:05:38.392Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
.github/workflows/build-binaries.yaml (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6651
File: nix/rust-package.nix:35-39
Timestamp: 2024-11-20T08:43:53.099Z
Learning: In the `nix/rust-package.nix` file, replacing hardcoded interpreter paths with `${stdenv.hostPlatform.platform.dynamicLinker}` doesn't work as intended, so hardcoded interpreter paths are necessary.
.github/workflows/create-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
deploy/nfpm/README.md (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
justfile (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
scripts/generate-changelog.sh (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/package-post-uninstall.sh (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
🧬 Code Graph Analysis (2)
deploy/nfpm/package-post-install.sh (1)
deploy/Formula/hoprd.rb (1)
  • generate_identity_file (305-343)
deploy/Formula/hoprd.rb (2)
misc/platform/src/file.rs (2)
  • write (42-54)
  • join (25-36)
deploy/nfpm/package-post-install.sh (1)
  • generate_identity_file (184-200)
🪛 markdownlint-cli2 (0.17.2)
deploy/Formula/README.md

1-1: No space after hash on atx style heading

(MD018, no-missing-space-atx)

🪛 Shellcheck (0.10.0)
deploy/nfpm/package-post-install.sh

[warning] 193-193: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

scripts/generate-changelog.sh

[warning] 58-58: section_performance appears unused. Verify use (or export if used externally).

(SC2034)


[warning] 101-101: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 129-129: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 142-142: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 143-143: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 145-145: Declare and assign separately to avoid masking return values.

(SC2155)

🪛 Brakeman (7.0.2)
deploy/Formula/hoprd.rb

[medium] 50-50: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 28-28: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 35-35: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 60-60: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 53-53: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 171-171: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 57-57: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 38-38: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 31-31: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 73-73: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 19-19: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 12-12: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 346-346: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 322-322: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 22-22: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 69-69: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 76-76: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 172-172: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 66-66: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 15-15: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)

🪛 RuboCop (1.75.5)
deploy/Formula/hoprd.rb

[convention] 84-150: Assignment Branch Condition size for install is too high. [<1, 38, 1> 38.03/23]

(Metrics/AbcSize)


[convention] 240-262: Assignment Branch Condition size for generate_env_vars is too high. [<16, 19, 14> 28.51/23]

(Metrics/AbcSize)


[convention] 240-262: Cyclomatic complexity for generate_env_vars is too high. [14/7]

(Metrics/CyclomaticComplexity)


[convention] 240-262: Perceived complexity for generate_env_vars is too high. [15/8]

(Metrics/PerceivedComplexity)


[convention] 305-343: Assignment Branch Condition size for generate_identity_file is too high. [<12, 29, 7> 32.16/23]

(Metrics/AbcSize)


[warning] 312-312: Useless assignment to variable - success.

(Lint/UselessAssignment)


[warning] 386-386: Useless assignment to variable - stderr. Use _ or _stderr as a variable name to indicate that it won't be used.

(Lint/UselessAssignment)


[convention] 405-446: Assignment Branch Condition size for show_installation_summary is too high. [<1, 31, 4> 31.27/23]

(Metrics/AbcSize)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (9)
  • GitHub Check: tests-smoke (win_prob)
  • GitHub Check: tests-smoke (redeeming)
  • GitHub Check: tests-smoke (integration)
  • GitHub Check: tests-smoke (session)
  • GitHub Check: hopli-aarch64-darwin / binary
  • GitHub Check: hopli-x86_64-darwin / binary
  • GitHub Check: hoprd-aarch64-darwin / binary
  • GitHub Check: hoprd-x86_64-darwin / binary
  • GitHub Check: tests-unit
🔇 Additional comments (9)
.gitignore (1)

213-214: Addition looks good – keeps generated changelogs out of VCS

The new pattern is scoped to deploy/nfpm/ and should not hide any source artefacts.
No action needed.

.github/workflows/close-release.yaml (1)

87-88: No lingering load_tests references found
A ripgrep search across all YAML, SH, TS, JS, and PY files returned zero matches; it’s safe to remove the load_tests label.

deploy/nfpm/hoprd-sample.cfg.yaml (1)

4-4: Validate path change for data directory

A search for “/var/lib/hoprd/data” returned no matches, but please ensure the following are all addressed when switching to /var/lib/hoprd:

  • Post-install scripts create /var/lib/hoprd with the correct ownership and permissions.
  • Upgrade/migration instructions move existing data from /var/lib/hoprd/data into the new directory.
  • Any hard-coded defaults (in code, systemd unit files, documentation, backups, etc.) are updated to reference /var/lib/hoprd.
hopr/hopr-lib/Cargo.toml (1)

3-3: Version bump acknowledged

Stable 3.0.0 release replaces -rc.1; no other metadata touched.
Remember to cargo update -p hopr-lib in dependent crates before publishing.

.github/workflows/create-release.yaml (1)

129-129: LGTM! Path update aligns with artifact extraction changes.

The change from ./dist/binaries/* to ./dist/bin/* correctly reflects the updated artifact extraction logic in the download script.

scripts/download-workflow-binaries.sh (1)

39-45: LGTM! Improved artifact organization.

The logic to separate package files from binaries into different directories is well-implemented and aligns with the workflow changes. The file extension check correctly identifies package formats.

justfile (2)

44-46: LGTM! Changelog generation and Debian-specific handling.

The changelog generation logic is well-implemented, with appropriate gzip compression for Debian packages and license line removal for compliance.


60-63: LGTM! Appropriate handling of unsupported platform combination.

The conditional logic to skip archlinux aarch64-linux testing is reasonable given the platform limitation mentioned in the comment.

deploy/nfpm/test-package-tool.sh (1)

48-52: Quote variable in test to avoid word-splitting

[ "${ARCHITECTURE}" == "aarch64-linux" ] is fine today, but quoting the literal RHS prevents shell-check warnings and future editing slip-ups.

-if [ "${ARCHITECTURE}" == "aarch64-linux" ]; then
+if [ "${ARCHITECTURE}" == "aarch64-linux" ]; then   # already quoted LHS/RHS – OK

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 12

🔭 Outside diff range comments (1)
deploy/nfpm/README.md (1)

69-71: pacman uninstall command is incorrect

pacman del is not a valid sub-command. Use pacman -Rns hoprd (or -R).

-sudo pacman del hoprd
+sudo pacman -Rns hoprd
♻️ Duplicate comments (6)
deploy/nfpm/package-pre-uninstall.sh (1)

1-2: Strict mode still omits -u (undefined vars) – same comment as before

deploy/nfpm/package-post-uninstall.sh (1)

2-2: Enable “unset variable” detection in strict mode

The script omits -u, so accidental typos like $SUDO_USER being unset won’t fail fast.

-set -Eeo pipefail
+set -Eeuo pipefail
deploy/nfpm/README.md (1)

15-17: Spelling: “addres” → “address”

The same typo recurs in all three installation snippets – please correct.

deploy/nfpm/package-pre-install.sh (2)

1-2: Add error handling flags for better script robustness.

For better portability and error checking, add set -euo pipefail immediately after the shebang.

Apply this diff:

 #!/bin/bash
+set -euo pipefail

1-2: Add defensive bash flags for safer execution
Please enable set -euo pipefail right after the shebang to abort on the first error, catch unset variables, and make pipe failures visible.

 #!/bin/bash
+set -euo pipefail
deploy/Formula/hoprd.rb (1)

143-143: Remove duplicate mkpath call.

Duplicate mkpath call for var/lib/hoprd appears one line earlier. Remove the redundant line to simplify the code.

Apply this diff:

   (var/"lib/hoprd").mkpath
-  (var/"lib/hoprd").mkpath
   (etc/"hoprd").mkpath
🧹 Nitpick comments (11)
.gitignore (1)

213-214: Pattern is correct but consider narrowing the wildcard to avoid future clashes

deploy/nfpm/changelog* will also ignore unrelated files such as changelog_backup.txt that might be added later for debugging.
If you only intend to ignore the autogenerated changelog and changelog.gz, narrow the pattern:

-deploy/nfpm/changelog*
+deploy/nfpm/changelog
+deploy/nfpm/changelog.gz
deploy/nfpm/hoprd-sample.cfg.yaml (1)

4-4: Changing data dir may break existing nodes – add migration note

Switching from /var/lib/hoprd/data to /var/lib/hoprd alters the expected DB path. Existing installations will keep their database in the old sub-directory and the daemon may start with an empty state.

Please:

  1. Confirm code detects the old path and migrates automatically, or
  2. Document a manual move in release notes / post-install script.
deploy/Formula/README.md (1)

1-1: Fix markdown formatting issue.

Add a space after the hash in the heading to comply with markdown standards.

-# Homebrew Formula
+# Homebrew Formula
.github/workflows/package.yaml (1)

45-53: Redundant mkdir -p ./dist/bin and missing jq availability check

  1. mkdir -p ./dist/bin appears twice – once is enough.
  2. The script relies on jq, which isn’t guaranteed on self-hosted runners. Explicitly install it or fail fast.
-          mkdir -p ./dist/bin
...
-          mkdir -p ./dist/bin
+          mkdir -p ./dist/bin
+          if ! command -v jq >/dev/null; then
+            echo "jq not found – installing..."
+            sudo apt-get update && sudo apt-get install -y jq
+          fi
deploy/nfpm/test-package-tool.sh (1)

15-31: Simplify get_vm_image and avoid double return

Multiple early returns and duplicated logic make the function hard to scan. Also, the function accepts no parameters, yet callers pass one.

get_vm_image() {
-  case "${DISTRIBUTION}" in
+  case "${DISTRIBUTION}" in
   deb)
-    if [ "${ARCHITECTURE}" == "aarch64-linux" ]; then
-      echo "projects/debian-cloud/global/images/family/debian-12-arm64"
-      return
-    else 
-      echo "projects/debian-cloud/global/images/family/debian-12"
-      return
-    fi
+    suffix=$([ "${ARCHITECTURE}" = "aarch64-linux" ] && echo "-arm64")
+    echo "projects/debian-cloud/global/images/family/debian-12${suffix}"
     ;;
   rpm)
-    if [ "${ARCHITECTURE}" == "aarch64-linux" ]; then
-      echo "projects/centos-cloud/global/images/family/centos-stream-9-arm64"
-      return
-    else
-      echo "projects/centos-cloud/global/images/family/centos-stream-9"
-      return
-    fi
+    suffix=$([ "${ARCHITECTURE}" = "aarch64-linux" ] && echo "-arm64")
+    echo "projects/centos-cloud/global/images/family/centos-stream-9${suffix}"
     ;;

Also drop the extra argument in the call (image=$(get_vm_image)).

deploy/nfpm/README.md (1)

5-8: Fix typos in project metadata

  • “operativa systems” ➔ “operating systems”
  • “readhat” ➔ “redhat”

These errors appear in introductory bullet points.

deploy/nfpm/package-pre-install.sh (2)

49-49: Use consistent syntax and prefer -n over ! -z.

Apply this diff for better consistency:

-  if [ ! -z "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
+  if [[ -n "${HOPRD_NETWORK}" && "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then

49-51: Minor style: prefer -n over ! -z for non-empty checks
While both work, [ -n "${VAR}" ] is the idiomatic POSIX way to test for non-empty strings and reads better.

-if [ ! -z "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
+if [ -n "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
deploy/Formula/hoprd.rb (2)

12-12: Consider using Ruby's built-in methods for fetching SHA256.

While the current approach works, using Ruby's Net::HTTP or open-uri would be more idiomatic and avoid shell execution.

Would you like me to provide an example using Ruby's built-in HTTP methods to fetch the SHA256 checksum?


312-312: Remove unused variable assignment.

The success variable is assigned but never used.

Apply this diff:

-        success = system("/bin/sh", "-c", cmd)
+        system("/bin/sh", "-c", cmd)
scripts/generate-changelog.sh (1)

142-145: Separate variable declarations from assignments for better error handling.

Declaring and assigning in the same line can mask command failures.

Apply this pattern throughout:

-  local distribution=$(get_release_type)
-  local urgency=$(get_urgency_level "${current_version}")
+  local distribution
+  local urgency
+  distribution=$(get_release_type)
+  urgency=$(get_urgency_level "${current_version}")
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 943af8f and 2c7ffb0.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (20)
  • .github/workflows/build-binaries.yaml (2 hunks)
  • .github/workflows/close-release.yaml (1 hunks)
  • .github/workflows/create-release.yaml (1 hunks)
  • .github/workflows/package.yaml (3 hunks)
  • .gitignore (1 hunks)
  • deploy/Formula/README.md (1 hunks)
  • deploy/Formula/hoprd.rb (1 hunks)
  • deploy/nfpm/README.md (3 hunks)
  • deploy/nfpm/copyright (1 hunks)
  • deploy/nfpm/hoprd-sample.cfg.yaml (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/package-pre-uninstall.sh (1 hunks)
  • deploy/nfpm/test-package-tool.sh (2 hunks)
  • hopr/hopr-lib/Cargo.toml (1 hunks)
  • justfile (2 hunks)
  • scripts/download-workflow-binaries.sh (1 hunks)
  • scripts/generate-changelog.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (21)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/nfpm/hoprd-sample.cfg.yaml (3)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
.github/workflows/create-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
.github/workflows/close-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
hopr/hopr-lib/Cargo.toml (13)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6531
File: hopr/hopr-lib/src/lib.rs:1110-1132
Timestamp: 2024-11-03T20:57:55.015Z
Learning: In `hopr/hopr-lib/src/lib.rs`, the `establish_max_retries` field is of type `u32`, so it cannot be negative. Therefore, handling negative values for this configuration parameter is unnecessary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6313
File: hopr/hopr-lib/src/lib.rs:0-0
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The types `IndexerTransportEvent`, `Network`, `PeerEligibility`, and `PeerOrigin` in the `hopr/hopr-lib/src/lib.rs` file are internal to the transport mechanism and do not require public documentation.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6795
File: Cargo.toml:62-64
Timestamp: 2025-01-22T09:55:51.820Z
Learning: The axum WebSocket message handling changes for version 0.8.2 (switching from Vec<u8> to Bytes for binary messages) are covered by end-to-end tests in the hoprnet project.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
scripts/download-workflow-binaries.sh (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
deploy/Formula/README.md (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
justfile (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
.github/workflows/package.yaml (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/nfpm/package-pre-install.sh (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/Formula/hoprd.rb (11)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
scripts/generate-changelog.sh (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/README.md (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: hopr/hopr-lib/src/lib.rs:564-564
Timestamp: 2024-10-21T15:15:11.701Z
Learning: In `hopr/hopr-lib/src/lib.rs`, when adding configuration options like `fast_sync` to `IndexerConfig`, inline code comments are not necessary if the feature is documented elsewhere.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
.github/workflows/build-binaries.yaml (11)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6651
File: nix/rust-package.nix:35-39
Timestamp: 2024-11-20T08:43:53.099Z
Learning: In the `nix/rust-package.nix` file, replacing hardcoded interpreter paths with `${stdenv.hostPlatform.platform.dynamicLinker}` doesn't work as intended, so hardcoded interpreter paths are necessary.
deploy/nfpm/copyright (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
.gitignore (4)
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-09-25T14:16:43.307Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
deploy/nfpm/nfpm.yaml (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/nfpm/package-pre-uninstall.sh (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
deploy/nfpm/test-package-tool.sh (1)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/package-post-install.sh (15)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
deploy/nfpm/package-post-uninstall.sh (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
🧬 Code Graph Analysis (2)
deploy/Formula/hoprd.rb (2)
misc/platform/src/file.rs (2)
  • write (42-54)
  • join (25-36)
deploy/nfpm/package-post-install.sh (1)
  • generate_identity_file (184-200)
deploy/nfpm/package-post-install.sh (1)
deploy/Formula/hoprd.rb (1)
  • generate_identity_file (305-343)
🪛 markdownlint-cli2 (0.17.2)
deploy/Formula/README.md

1-1: No space after hash on atx style heading

(MD018, no-missing-space-atx)

🪛 Brakeman (7.0.2)
deploy/Formula/hoprd.rb

[medium] 50-50: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 28-28: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 35-35: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 60-60: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 53-53: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 171-171: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 57-57: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 38-38: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 31-31: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 73-73: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 19-19: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 12-12: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 346-346: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 322-322: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 22-22: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 69-69: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 76-76: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 172-172: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 66-66: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 15-15: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)

🪛 RuboCop (1.75.5)
deploy/Formula/hoprd.rb

[convention] 84-150: Assignment Branch Condition size for install is too high. [<1, 38, 1> 38.03/23]

(Metrics/AbcSize)


[convention] 240-262: Assignment Branch Condition size for generate_env_vars is too high. [<16, 19, 14> 28.51/23]

(Metrics/AbcSize)


[convention] 240-262: Cyclomatic complexity for generate_env_vars is too high. [14/7]

(Metrics/CyclomaticComplexity)


[convention] 240-262: Perceived complexity for generate_env_vars is too high. [15/8]

(Metrics/PerceivedComplexity)


[convention] 305-343: Assignment Branch Condition size for generate_identity_file is too high. [<12, 29, 7> 32.16/23]

(Metrics/AbcSize)


[warning] 312-312: Useless assignment to variable - success.

(Lint/UselessAssignment)


[warning] 386-386: Useless assignment to variable - stderr. Use _ or _stderr as a variable name to indicate that it won't be used.

(Lint/UselessAssignment)


[convention] 405-446: Assignment Branch Condition size for show_installation_summary is too high. [<1, 31, 4> 31.27/23]

(Metrics/AbcSize)

🪛 Shellcheck (0.10.0)
scripts/generate-changelog.sh

[warning] 58-58: section_performance appears unused. Verify use (or export if used externally).

(SC2034)


[warning] 101-101: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 129-129: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 142-142: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 143-143: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 145-145: Declare and assign separately to avoid masking return values.

(SC2155)

deploy/nfpm/package-post-install.sh

[warning] 193-193: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (5)
  • GitHub Check: tests-smoke (win_prob)
  • GitHub Check: hopli-aarch64-darwin / binary
  • GitHub Check: hopli-x86_64-darwin / binary
  • GitHub Check: hoprd-aarch64-darwin / binary
  • GitHub Check: hoprd-x86_64-darwin / binary
🔇 Additional comments (15)
.github/workflows/close-release.yaml (1)

87-88: Removal of load_tests label looks good – double-check downstream consumers

No issues spotted, but please verify no other workflow still relies on the load_tests label being present on close-release PRs.
If nothing depends on it, safe to merge.

hopr/hopr-lib/Cargo.toml (1)

3-3: Version bump acknowledged

No further action required.

.github/workflows/create-release.yaml (1)

129-129: Path change aligns with updated artifact extraction logic.

The change from ./dist/binaries/* to ./dist/bin/* correctly matches the updated artifact extraction logic in scripts/download-workflow-binaries.sh, which now extracts non-package artifacts directly to ./dist/bin/ instead of platform-specific subdirectories.

deploy/nfpm/copyright (1)

1-8: Well-formatted copyright file following Debian standards.

The copyright file correctly follows the Debian copyright format version 1.0, with proper upstream information, copyright attribution, and license specification. The comment about static linking to libyaml provides useful context for distribution compatibility.

scripts/download-workflow-binaries.sh (1)

39-45: Improved artifact organization with proper package/binary separation.

The logic correctly separates package files (.deb, .rpm, .pkg.tar.zst) from binary artifacts, extracting them to appropriate directories (./dist/packages and ./dist/bin respectively). This aligns with the updated workflow expectations and simplifies the artifact structure by removing platform-specific subdirectories.

deploy/Formula/README.md (1)

2-36: Comprehensive development instructions for Homebrew formula.

The README provides clear, step-by-step instructions for installing, testing, and uninstalling the Homebrew formula during development. The inclusion of verbose and debug flags is helpful for troubleshooting, and the thorough cleanup process ensures complete uninstallation.

justfile (2)

44-46: Enhanced packaging with format-specific changelog handling.

The changelog generation and Debian-specific processing (gzip compression and license removal) correctly handle the different requirements for various package formats. The logic properly uses conditional execution to apply format-specific transformations only when needed.


60-63: Appropriate skip condition for unsupported platform combination.

The conditional skip for archlinux aarch64-linux is well-implemented, providing a clear explanation and graceful exit for unsupported combinations in GCP images.

deploy/nfpm/package-pre-install.sh (3)

6-22: LGTM!

The function correctly validates Ethereum addresses using appropriate regex patterns and provides clear error messages.


61-75: LGTM!

The main execution flow properly accumulates all validation errors and presents them clearly to the user before failing the installation.


66-75: Clear, user-friendly error aggregation looks good
The final report block is concise and actionable. Nice touch!

deploy/nfpm/nfpm.yaml (1)

6-69: LGTM!

The package metadata improvements are well-structured:

  • Appropriate section classification as "net"
  • Comprehensive multi-line description
  • Proper file permissions and ownership settings
  • Good inclusion of documentation files
deploy/Formula/hoprd.rb (1)

14-24: Add GPG availability check before verification.

The GPG verification will fail if GPG is not installed. Consider checking for GPG availability first.

Add this check at the beginning of the install method:

def install
  unless system("which", "gpg", out: File::NULL, err: File::NULL)
    opoo "GPG not found. Skipping signature verification."
    ENV["SKIP_GPG_VERIFY"] = "1"
  end
  # ... rest of install method
end

Then wrap GPG verification calls:

system "gpg --verify hoprd-aarch64-darwin.sig hoprd-aarch64-darwin" unless ENV["SKIP_GPG_VERIFY"]
deploy/nfpm/package-post-install.sh (1)

259-260: Review the order of function calls for password dependency.

The generate_identity_file function uses ${HOPRD_PASSWORD}, but this variable is only set with a default value inside generate_env_file. This could lead to issues if HOPRD_PASSWORD is not already set in the environment.

Consider either:

  1. Ensuring HOPRD_PASSWORD is set before calling generate_identity_file, or
  2. Swapping the order back to call generate_env_file first
-generate_identity_file
 generate_env_file
+generate_identity_file
scripts/generate-changelog.sh (1)

6-7: LGTM!

The milestone lookup correctly uses jq --arg which safely handles the version parameter, preventing any injection issues.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 13

♻️ Duplicate comments (4)
deploy/nfpm/package-post-uninstall.sh (1)

1-2: Add -u to strict-mode flags
Same remark as previous scripts; please use set -Eeuo pipefail.

deploy/nfpm/package-pre-uninstall.sh (1)

1-2: Enable -u in strict mode as well
shellcheck (SC3044) still warns here.

deploy/nfpm/package-pre-install.sh (1)

1-2: Add error handling flags for robustness.

For better portability and error checking, add set -euo pipefail immediately after the shebang.

 #!/bin/bash
+set -euo pipefail
 
deploy/Formula/hoprd.rb (1)

142-143: Remove duplicate directory creation.

Duplicate mkpath call for var/lib/hoprd appears one line earlier.

     (var/"lib/hoprd").mkpath
-    (var/"lib/hoprd").mkpath
     (etc/"hoprd").mkpath
🧹 Nitpick comments (8)
deploy/Formula/README.md (2)

11-11: Capitalize “URL” for consistency

urlURL keeps terminology uniform across docs.


17-18: Wrap shell command in a fenced block

brew services start hoprd is rendered as plain text; enclosing it in the existing bash fence improves copy-paste UX.

.github/workflows/package.yaml (1)

48-53: Duplicate directory creation

mkdir -p ./dist/bin is executed twice (lines 46 and 52). One invocation is enough.

deploy/nfpm/package-pre-install.sh (2)

30-35: Add error handling for curl commands.

The curl commands could fail due to network issues. Consider checking curl's exit status for clearer error messages.

     # Perform a POST request to check RPC provider
-    rpc_response=$(curl -s -X POST -H "Content-Type: application/json" \
-      --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":1}' http://localhost:8545)
+    if ! rpc_response=$(curl -s -X POST -H "Content-Type: application/json" \
+      --data '{"jsonrpc":"2.0","method":"web3_clientVersion","params":[],"id":1}' http://localhost:8545 2>/dev/null); then
+      errors+="- Failed to connect to local RPC provider at http://localhost:8545. The 'HOPRD_PROVIDER' environment variable is required.\n"
+    elif ! echo "$rpc_response" | jq -e '.result' > /dev/null; then
+      errors+="- The 'HOPRD_PROVIDER' environment variable is required. You can get it from https://docs.hoprnet.org/node/custom-rpc-provider\n"
+    fi
 
-    if ! echo "$rpc_response" | jq -e '.result' > /dev/null; then
-      errors+="- The 'HOPRD_PROVIDER' environment variable is required. You can get it from https://docs.hoprnet.org/node/custom-rpc-provider\n"
-    fi

49-49: Use idiomatic test for non-empty strings.

Replace double negation with the more readable -n test.

-  if [ ! -z "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
+  if [ -n "${HOPRD_NETWORK}" ] && [[ "${HOPRD_NETWORK}" != "dufour" && "${HOPRD_NETWORK}" != "rotsee" ]]; then
deploy/Formula/hoprd.rb (2)

312-312: Remove unused variable assignment.

The success variable is assigned but never used.

-        success = system("/bin/sh", "-c", cmd)
+        system("/bin/sh", "-c", cmd)

386-386: Use underscore for unused variable.

The stderr variable is captured but never used.

-    stdout, stderr, status = Open3.capture3(
+    stdout, _stderr, status = Open3.capture3(
scripts/generate-changelog.sh (1)

142-145: Separate variable declarations from assignments.

To avoid masking return values, declare and assign variables separately.

-  local distribution=$(get_release_type)
-  local urgency=$(get_urgency_level "${current_version}")
-  local maintainer="Hoprnet <tech@hoprnet.org>"
-  local date="$(date -R)"
+  local distribution
+  distribution=$(get_release_type)
+  local urgency
+  urgency=$(get_urgency_level "${current_version}")
+  local maintainer="Hoprnet <tech@hoprnet.org>"
+  local date
+  date="$(date -R)"
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 943af8f and 2c7ffb0.

⛔ Files ignored due to path filters (1)
  • Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (20)
  • .github/workflows/build-binaries.yaml (2 hunks)
  • .github/workflows/close-release.yaml (1 hunks)
  • .github/workflows/create-release.yaml (1 hunks)
  • .github/workflows/package.yaml (3 hunks)
  • .gitignore (1 hunks)
  • deploy/Formula/README.md (1 hunks)
  • deploy/Formula/hoprd.rb (1 hunks)
  • deploy/nfpm/README.md (3 hunks)
  • deploy/nfpm/copyright (1 hunks)
  • deploy/nfpm/hoprd-sample.cfg.yaml (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/package-pre-uninstall.sh (1 hunks)
  • deploy/nfpm/test-package-tool.sh (2 hunks)
  • hopr/hopr-lib/Cargo.toml (1 hunks)
  • justfile (2 hunks)
  • scripts/download-workflow-binaries.sh (1 hunks)
  • scripts/generate-changelog.sh (1 hunks)
🧰 Additional context used
🧠 Learnings (21)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/Formula/hoprd.rb (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
hopr/hopr-lib/Cargo.toml (13)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6531
File: hopr/hopr-lib/src/lib.rs:1110-1132
Timestamp: 2024-11-03T20:57:55.015Z
Learning: In `hopr/hopr-lib/src/lib.rs`, the `establish_max_retries` field is of type `u32`, so it cannot be negative. Therefore, handling negative values for this configuration parameter is unnecessary.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6511
File: Cargo.toml:77-77
Timestamp: 2024-09-28T21:05:38.392Z
Learning: The `float-cmp` crate is used in the `hopr-primitive-types` crate.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6313
File: hopr/hopr-lib/src/lib.rs:0-0
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The types `IndexerTransportEvent`, `Network`, `PeerEligibility`, and `PeerOrigin` in the `hopr/hopr-lib/src/lib.rs` file are internal to the transport mechanism and do not require public documentation.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/nfpm/package-post-install.sh (15)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
deploy/nfpm/copyright (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
.github/workflows/package.yaml (12)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/nfpm/nfpm.yaml (11)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: common/primitive-types/Cargo.toml:24-24
Timestamp: 2024-11-01T09:32:55.651Z
Learning: In the hoprnet project, dependency versions are defined in the workspace Cargo.toml, so it's not necessary to specify them in individual package Cargo.toml files.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/nfpm/test-package-tool.sh (1)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
scripts/generate-changelog.sh (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/package-post-uninstall.sh (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
deploy/nfpm/hoprd-sample.cfg.yaml (5)
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: chain/api/Cargo.toml:50-53
Timestamp: 2024-11-01T15:26:53.058Z
Learning: In `chain/api/Cargo.toml`, it's acceptable to declare the same dependency `hopr-db-sql` in both `[dependencies]` and `[dev-dependencies]` with different features, especially when additional features are only needed for tests.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
deploy/Formula/README.md (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
.github/workflows/build-binaries.yaml (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6651
File: nix/rust-package.nix:35-39
Timestamp: 2024-11-20T08:43:53.099Z
Learning: In the `nix/rust-package.nix` file, replacing hardcoded interpreter paths with `${stdenv.hostPlatform.platform.dynamicLinker}` doesn't work as intended, so hardcoded interpreter paths are necessary.
deploy/nfpm/package-pre-install.sh (14)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-07-28T07:26:06.634Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
.github/workflows/create-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
.gitignore (4)
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-09-25T14:16:43.307Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6508
File: rustfmt.toml:6-6
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The directory `ethereum/bindings/src/codegen` is generated and may not exist in the project structure but should still be included in the `ignore` directive in `rustfmt.toml` to prevent formatting of generated code.
justfile (3)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
deploy/nfpm/package-pre-uninstall.sh (9)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
scripts/download-workflow-binaries.sh (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
.github/workflows/close-release.yaml (6)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: .github/labeler.yml:95-106
Timestamp: 2025-05-26T22:04:22.750Z
Learning: In .github/labeler.yml, both legacy crate labels (like hopr-path, hopr-platform) and new crate labels (like hopr-chain-actions, hopr-chain-api) can coexist in the same file. When new crate labels are added, it doesn't necessarily mean old ones are deprecated or should be removed.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
deploy/nfpm/README.md (10)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6366
File: hoprd/rest-api/src/network.rs:32-49
Timestamp: 2024-10-09T06:16:18.170Z
Learning: Error messages in the `price` function within `hoprd/rest-api/src/network.rs` must remain unchanged to maintain backwards-compatibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
🧬 Code Graph Analysis (2)
deploy/Formula/hoprd.rb (1)
deploy/nfpm/package-post-install.sh (1)
  • generate_identity_file (184-200)
deploy/nfpm/package-post-install.sh (1)
deploy/Formula/hoprd.rb (1)
  • generate_identity_file (305-343)
🪛 Brakeman (7.0.2)
deploy/Formula/hoprd.rb

[medium] 50-50: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 28-28: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 35-35: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 60-60: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 53-53: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 171-171: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 57-57: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 38-38: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 31-31: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 73-73: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 19-19: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 12-12: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 346-346: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 322-322: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 22-22: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 69-69: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 76-76: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 172-172: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 66-66: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)


[medium] 15-15: Possible command injection
Type: Command Injection
Confidence: Medium
More info: https://brakemanscanner.org/docs/warning_types/command_injection/

(Command Injection)

🪛 RuboCop (1.75.5)
deploy/Formula/hoprd.rb

[convention] 84-150: Assignment Branch Condition size for install is too high. [<1, 38, 1> 38.03/23]

(Metrics/AbcSize)


[convention] 240-262: Assignment Branch Condition size for generate_env_vars is too high. [<16, 19, 14> 28.51/23]

(Metrics/AbcSize)


[convention] 240-262: Cyclomatic complexity for generate_env_vars is too high. [14/7]

(Metrics/CyclomaticComplexity)


[convention] 240-262: Perceived complexity for generate_env_vars is too high. [15/8]

(Metrics/PerceivedComplexity)


[convention] 305-343: Assignment Branch Condition size for generate_identity_file is too high. [<12, 29, 7> 32.16/23]

(Metrics/AbcSize)


[warning] 312-312: Useless assignment to variable - success.

(Lint/UselessAssignment)


[warning] 386-386: Useless assignment to variable - stderr. Use _ or _stderr as a variable name to indicate that it won't be used.

(Lint/UselessAssignment)


[convention] 405-446: Assignment Branch Condition size for show_installation_summary is too high. [<1, 31, 4> 31.27/23]

(Metrics/AbcSize)

🪛 Shellcheck (0.10.0)
deploy/nfpm/package-post-install.sh

[warning] 193-193: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

scripts/generate-changelog.sh

[warning] 58-58: section_performance appears unused. Verify use (or export if used externally).

(SC2034)


[warning] 101-101: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 129-129: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 142-142: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 143-143: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 145-145: Declare and assign separately to avoid masking return values.

(SC2155)

🪛 markdownlint-cli2 (0.17.2)
deploy/Formula/README.md

11-11: Bare URL used

(MD034, no-bare-urls)


33-33: Bare URL used

(MD034, no-bare-urls)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: hopli-x86_64-darwin / binary
  • GitHub Check: hoprd-aarch64-darwin / binary
  • GitHub Check: hoprd-x86_64-darwin / binary
🔇 Additional comments (16)
.gitignore (1)

213-213: Changelog artefacts correctly ignored

Adding deploy/nfpm/changelog* keeps auto-generated changelogs out of VCS – good housekeeping.

.github/workflows/close-release.yaml (1)

87-87: load_tests label removal looks safe

None of the remaining workflows key off load_tests, so trimming it here is fine.

deploy/nfpm/hoprd-sample.cfg.yaml (1)

4-4: Path change may break existing deployments

Switching from /var/lib/hoprd/data to /var/lib/hoprd alters default state-dir semantics. Verify:

  1. Pre-/post-install scripts create & chown the new location.
  2. Migration/backup instructions cover users already running with the old path.
  3. Any hard-coded references in docs, service files, or integration tests are updated.
hopr/hopr-lib/Cargo.toml (1)

3-3: Confirm workspace consistency after version bump

Bumping to 3.0.0 is straightforward, but double-check that:

  • workspace package.version overrides don’t re-pin the crate back to an RC tag.
  • Release tagging script and Homebrew formula pull the same version string.

No code change required if those align.

.github/workflows/create-release.yaml (1)

129-129: LGTM! Path update aligns with artifact extraction changes.

The change from ./dist/binaries/* to ./dist/bin/* correctly reflects the updated artifact extraction logic in scripts/download-workflow-binaries.sh, which now extracts binaries flatly into ./dist/bin instead of platform-specific subdirectories.

scripts/download-workflow-binaries.sh (1)

39-45: LGTM! Improved artifact organization logic.

The enhanced extraction logic properly separates packages from binaries, making the artifact handling more organized and predictable. This change aligns well with the updated packaging workflows and simplifies downstream processing.

deploy/nfpm/test-package-tool.sh (3)

6-10: LGTM! Infrastructure configuration updated.

The zone change from "europe-west3-a" to "europe-west4-a" and the network/subnet simplification to "default" values are reasonable infrastructure updates that likely improve availability and simplify network configuration.


15-30: LGTM! Architecture-specific VM image selection implemented.

The enhanced get_vm_image function now properly selects ARM64 or standard images based on the architecture, ensuring correct VM provisioning for both x86_64 and aarch64 architectures across Debian and CentOS distributions.


48-48: LGTM! Architecture naming convention aligned.

The update to check for "aarch64-linux" instead of "aarch64" is consistent with the architecture naming convention used throughout the codebase and other scripts.

justfile (2)

44-46: LGTM! Enhanced packaging with changelog generation and Debian-specific handling.

The additions properly implement:

  • Changelog generation with packager-specific formatting
  • Debian-specific gzip compression for changelog
  • License field removal for Debian packages (as it's handled differently)

These changes align with standard packaging practices for different Linux distributions.


60-63: LGTM! Appropriate skip condition for unsupported combination.

The conditional skip for archlinux on aarch64-linux is a sensible approach when the combination is not yet supported in GCP images, preventing unnecessary test failures while maintaining clear documentation of the limitation.

deploy/nfpm/nfpm.yaml (3)

6-15: LGTM! Improved package metadata and description.

The changes enhance the package definition with:

  • More appropriate section classification ("net" instead of "default")
  • Updated maintainer contact information
  • Comprehensive multi-line description explaining the HOPR node and its components

These improvements provide better package discoverability and user understanding.


27-51: LGTM! Explicit file permissions and ownership specified.

The addition of explicit file_info sections with mode, owner, and group specifications follows packaging best practices and ensures consistent file permissions across different installation environments.


54-69: LGTM! Documentation files and placeholder manual pages added.

The addition of copyright and changelog files improves package compliance and user documentation. The commented-out manual page entries provide a clear roadmap for future enhancements.

.github/workflows/package.yaml (1)

129-146: Verify path/name alignment after renaming

The artifacts are uploaded from dist/packages/hoprd-<target>.{deb,rpm,archlinux} but the new package_file_name uses underscores. Ensure the file names written by just package still match these paths, otherwise the upload will silently fail.

scripts/generate-changelog.sh (1)

58-58: Include performance section in output.

The section_performance variable is defined but not included in the sections loop, so performance improvements won't appear in the changelog.

   # The exclamation mark (!) in ${!section} is used for indirect variable expansion in Bash. It allows you to reference the value of a variable whose name is stored in another variable.
-  for section in section_feature section_fix section_refactor section_documentation section_performance section_other; do
+  for section in section_feature section_fix section_refactor section_documentation section_performance section_other; do
     if [[ ${!section} == *"-"* ]]; then
       change_log_content+="${!section}\n"
     fi
   done

Wait, I see section_performance is already in the loop. The issue is that the condition checks for *"-"* but performance entries use * not -. This needs a different fix:

   # The exclamation mark (!) in ${!section} is used for indirect variable expansion in Bash. It allows you to reference the value of a variable whose name is stored in another variable.
   for section in section_feature section_fix section_refactor section_documentation section_performance section_other; do
-    if [[ ${!section} == *"-"* ]]; then
+    if [[ ${!section} == *"* "* ]] || [[ ${!section} == *"- "* ]]; then
       change_log_content+="${!section}\n"
     fi
   done

Also applies to: 90-94

⛔ Skipped due to learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.

@ausias-armesto ausias-armesto removed binary:x86_64-linux Build x86_64-linux binary binary:aarch64-darwin Build aarch64-darwin binary binary:x86_64-darwin Build x86_64-darwin binary labels Jul 10, 2025
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

♻️ Duplicate comments (7)
scripts/generate-changelog.sh (5)

80-81: Missing += operator – entries silently ignored

section_performance is never appended to because the assignment operator is missing.
The loop builds the string but nothing is stored, so the Performance section will always be empty.

-      section_performance+"* ${title} by @${author} in #${id}\n"
+      section_performance+="* ${title} by @${author} in #${id}\n"

90-92: Bullet-point detection still wrong

Only section_fix uses a dash; the rest use an asterisk.
With the current check most sections are skipped, producing an incomplete changelog.

-    if [[ ${!section} == *"-"* ]]; then
+    if [[ ${!section} == *"*"* ]]; then

95-95: Unquoted variable expansion can mangle the output

echo -e ${change_log_content} is subject to word-splitting and globbing; content that contains * or ? will be expanded by the shell.

-  echo -e ${change_log_content}
+  echo -e "${change_log_content}"

6-9: No error handling when milestone not found

gh api may return an empty string; subsequent calls will fail in confusing ways.

 milestone_number=$(gh api repos/:owner/:repo/milestones | jq -r --arg version "${current_version}" ' to_entries[] | select(.value.title | test($version)).value.number')
+if [[ -z "${milestone_number}" ]]; then
+  echo "[ERROR] No milestone matching ${current_version} was found" >&2
+  exit 1
+fi

12-14: Quote the argument inside jq_decode

Unquoted $1 is unsafe; filenames containing spaces or glob characters will break decoding.

-  echo ${1} | base64 --decode
+  echo "${1}" | base64 --decode
deploy/nfpm/package-post-install.sh (2)

193-196: Fix stdout/stderr redirection order

ShellCheck SC2069 is still triggered – 2>&1 must come after the stdout redirect:

-    if IDENTITY_PASSWORD=${HOPRD_PASSWORD} hopli identity read --identity-from-path /etc/hoprd/hopr.id | grep "^Identity addresses: \\[\\]" 2>&1 >/dev/null; then
+    if IDENTITY_PASSWORD=${HOPRD_PASSWORD} hopli identity read --identity-from-path /etc/hoprd/hopr.id | grep "^Identity addresses: \\[\\]" >/dev/null 2>&1; then

This ensures both streams are suppressed.


257-262: Identity is created before HOPRD_PASSWORD is initialised – empty password risk

generate_identity_file relies on $HOPRD_PASSWORD, but that variable is only set in generate_env_file, which is executed afterwards.
A fresh install will therefore create an identity protected by an empty password and subsequently write a different random password to hoprd.env, breaking any later attempt to read the identity.

-echo "Starting HOPR node installation..."
-generate_identity_file
-generate_env_file
+echo "Starting HOPR node installation..."
+# Ensure all required variables exist before they are consumed
+generate_env_file
+generate_identity_file

Alternatively, export the password earlier or abort when it is unset.

🧹 Nitpick comments (8)
deploy/Formula/README.md (5)

1-1: Fix Markdown heading – remove non-breaking space to satisfy linters

The heading currently begins with # Homebrew where the space after # is a non-breaking space (U+00A0). This trips markdownlint (MD018). Replace it with a regular space.

-# Homebrew Formula
+# Homebrew Formula

5-5: Grammar / clarity

Use “These instructions …” instead of “Those instructions …” to sound natural and clarify scope.

-Those instructions are only at development time of the Formula
+These instructions are only for development of the formula

11-12: Capitalize “URL” and adjust wording

Minor style nit: use the conventional all-caps acronym and clarify that both URLs need to be changed.

-Change the url of the artifacts at `./deploy/Formula/hoprd.rb` to use the temporary artifact
+Update the URLs of the artifacts in `deploy/Formula/hoprd.rb` to point to the temporary files

19-21: Bullet list formatting – keep commands inside the list

The mixed list / code style breaks Markdown renderers (the command lines appear as plain body text). Indent the inline commands by four spaces so they remain part of the bullet list:

-- Edit manually $(brew --prefix)/etc/hoprd/hoprd.env
-- brew services start hoprd
+* Edit `$(brew --prefix)/etc/hoprd/hoprd.env`
+    ```bash
+    brew services start hoprd
+    ```

This keeps the tutorial readable in GitHub preview and avoids confusion.


28-39: Consider grouping the cleanup commands in a fenced block

Multiple single-line code blocks reduce readability. A single fenced block underneath the “Clear cache” bullet improves copy-paste UX:

-```bash
-rm -rf $(brew --cache)/*hopr*
-…
-brew cleanup -s
-```
+    ```bash
+    # Clear Homebrew cache and residual files
+    rm -rf "$(brew --cache)"/*hopr*
+    rm -rf "$(brew --prefix)"/Cellar/hoprd
+    rm -f  "$(brew --prefix)"/bin/hopr{d,li}
+    rm -rf "$(brew --prefix)"/etc/hoprd
+    rm -rf "$(brew --prefix)"/var/lib/hoprd
+    rm -f  "$(brew --prefix)"/var/log/hoprd.log
+    rm -f  "$(brew --prefix)"/var/homebrew/linked/hoprd
+    brew cleanup -s
+    ```

Not mandatory but yields better formatting consistency.

scripts/generate-changelog.sh (1)

20-24: Loop loses items containing whitespace

for item_encoded in ${entries}; do uses the default IFS and will split on any whitespace.
If gh ever outputs newline-separated but space-containing base64 blobs they will be truncated.

-  for item_encoded in ${entries}; do
+  IFS=$'\n' read -r -d '' -a _items <<< "${entries//$'\n'/}"
+  for item_encoded in "${_items[@]}"; do

Alternatively, switch to jq -c and avoid base64 entirely.

deploy/nfpm/package-post-install.sh (2)

92-98: Empty SAFE/MODULE addresses are written to env file

add_safe_addresses_var unconditionally appends the variables even when they are unset, producing:

HOPRD_SAFE_ADDRESS=
HOPRD_MODULE_ADDRESS=

Down-stream tooling that parses the env file may mis-interpret empty values.
Guard the writes or provide sensible defaults.


137-145: Minor: duplicate blank line after log-level examples

Because append_env_data always adds \n, the literal newline already present at the end of the example string results in an extra blank line. Harmless but noisy.

-  append_env_data "# RUST_LOG=debug,libp2p_swarm=debug,libp2p_mplex=debug,multistream_select=debug,libp2p_tcp=debug,libp2p_dns=info,sea_orm=info,sqlx=info\n"
+  append_env_data "# RUST_LOG=debug,libp2p_swarm=debug,libp2p_mplex=debug,multistream_select=debug,libp2p_tcp=debug,libp2p_dns=info,sea_orm=info,sqlx=info"
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 2c7ffb0 and 944688f.

📒 Files selected for processing (9)
  • .github/workflows/package.yaml (4 hunks)
  • deploy/Formula/README.md (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/test-package-tool.sh (2 hunks)
  • flake.nix (1 hunks)
  • scripts/generate-changelog.sh (1 hunks)
✅ Files skipped from review due to trivial changes (1)
  • flake.nix
🚧 Files skipped from review as they are similar to previous changes (5)
  • deploy/nfpm/test-package-tool.sh
  • .github/workflows/package.yaml
  • deploy/nfpm/nfpm.yaml
  • deploy/nfpm/package-post-uninstall.sh
  • deploy/nfpm/package-pre-install.sh
🧰 Additional context used
🧠 Learnings (4)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6399
File: db/entity/Cargo.toml:4-4
Timestamp: 2024-10-21T14:58:45.665Z
Learning: In the HOPR project, crate versions are intentionally kept separate and do not need to be aligned across related packages.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
deploy/Formula/README.md (5)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6576
File: hoprd/rest-api/src/lib.rs:251-251
Timestamp: 2024-10-28T14:29:25.598Z
Learning: In the HOPRd project, the path `/api-docs2/openapi.json` is used instead of `/api-docs/openapi.json` to avoid conflicts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
deploy/nfpm/package-post-install.sh (17)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-07-28T07:26:06.634Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
scripts/generate-changelog.sh (3)
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
🧬 Code Graph Analysis (1)
deploy/nfpm/package-post-install.sh (1)
deploy/Formula/hoprd.rb (1)
  • generate_identity_file (305-343)
🪛 markdownlint-cli2 (0.17.2)
deploy/Formula/README.md

1-1: No space after hash on atx style heading

(MD018, no-missing-space-atx)

🪛 Shellcheck (0.10.0)
deploy/nfpm/package-post-install.sh

[warning] 193-193: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

scripts/generate-changelog.sh

[warning] 58-58: section_performance appears unused. Verify use (or export if used externally).

(SC2034)


[warning] 100-100: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 128-128: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 141-141: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 142-142: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 144-144: Declare and assign separately to avoid masking return values.

(SC2155)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (3)
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: Lint / Lint
  • GitHub Check: Audit / Audit

ausias-armesto and others added 5 commits July 10, 2025 13:22
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Co-authored-by: coderabbitai[bot] <136622811+coderabbitai[bot]@users.noreply.github.com>
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 8

🔭 Outside diff range comments (1)
scripts/download-workflow-binaries.sh (1)

27-33: Use absolute paths consistently (${mydir}) to avoid CWD-dependent bugs

mkdir -p uses "${mydir}/dist/…", but every subsequent reference drops the prefix (dist/…).
If the caller executes the script from a directory other than ${mydir}, downloads will go to the wrong place and later mv/unzip calls will fail.

-  if ! curl -L -s -f -o "dist/zip/${artifact_name}.zip" …
+  if ! curl -L -s -f -o "${mydir}/dist/zip/${artifact_name}.zip" …-  unzip -o "dist/zip/${artifact_name}.zip" -d "./dist/unzip"
+  unzip -o "${mydir}/dist/zip/${artifact_name}.zip" -d "${mydir}/dist/unzip"

Either prefix every path with ${mydir} or cd "${mydir}" right after computing it.
This prevents silent breakage in CI runners and local usage.

♻️ Duplicate comments (1)
deploy/nfpm/package-pre-uninstall.sh (1)

4-7: Repeated concern: systemctl failures will abort uninstall under set -e.

Previous reviews already highlighted that disable/stop can exit non-zero when the unit never existed, and that daemon-reexec/reload can fail in containerised environments. With set -Eeuo pipefail this still causes the whole uninstall to abort.

Re-evaluate whether lintian constraints outweigh the risk of a broken removal; otherwise guard the calls (e.g. --quiet || true) or drop set -e for this block.

🧹 Nitpick comments (6)
deploy/nfpm/package-post-install.sh (2)

92-99: Remove embedded \nappend_env_data already appends newlines.

Each argument passed here already contains a trailing \n, and append_env_data appends an extra newline itself, resulting in double-blank lines in the generated hoprd.env.

-  append_env_data "# HOPRD_SAFE_ADDRESS is ethereum address link to your safe and shown in https://hub.hoprnet.org"
-  append_env_data "HOPRD_SAFE_ADDRESS=${HOPRD_SAFE_ADDRESS}\n"
-  append_env_data "# HOPRD_MODULE_ADDRESS is ethereum address link to your safe module and shown in https://hub.hoprnet.org"
-  append_env_data "HOPRD_MODULE_ADDRESS=${HOPRD_MODULE_ADDRESS}\n"
+  append_env_data "# HOPRD_SAFE_ADDRESS is ethereum address linked to your Safe (see https://hub.hoprnet.org)"
+  append_env_data "HOPRD_SAFE_ADDRESS=${HOPRD_SAFE_ADDRESS}"
+  append_env_data "# HOPRD_MODULE_ADDRESS is ethereum address linked to your Safe module"
+  append_env_data "HOPRD_MODULE_ADDRESS=${HOPRD_MODULE_ADDRESS}"

Same pattern appears in other helpers (add_hoprd_password_var, add_api_token_var, etc.).
Cleaning this up improves readability of the generated file while retaining identical semantics.


137-145: Nit: streamline log-level section & avoid duplicated blank lines.

As with the previous comment, remove the embedded newline characters and keep the example block comment together for clarity:

-  append_env_data "# RUST_LOG is the log level for the HOPR node"
-  append_env_data "RUST_LOG=${RUST_LOG}"
-  append_env_data "# RUST_LOG=debug,libp2p_swarm=debug,libp2p_mplex=debug,multistream_select=debug,libp2p_tcp=debug,libp2p_dns=info,sea_orm=info,sqlx=info\n"
+  append_env_data "# RUST_LOG is the log level for the HOPR node"
+  append_env_data "RUST_LOG=${RUST_LOG}"
+  append_env_data "# Example for more verbosity:"
+  append_env_data "# RUST_LOG=debug,libp2p_swarm=debug,libp2p_mplex=debug,multistream_select=debug,libp2p_tcp=debug,libp2p_dns=info,sea_orm=info,sqlx=info"

Purely cosmetic but keeps hoprd.env tight and predictable.

scripts/generate-changelog.sh (3)

103-106: Quote the JSON payload when echoing
Unquoted expansion can be split by IFS or wildcard-expanded, corrupting the output.

-  echo -e ${change_log_content}
+  echo -e "${change_log_content}"

132-138: Avoid arithmetic errors when patch number is empty
If the version string lacks a patch component, ${patch_number} is empty and -eq triggers “integer expression expected”.

-local patch_number=$(echo ${version} | awk -F '.' '{print $3}' | awk -F '-' '{print $1}')
+local patch_number
+patch_number=$(echo "${version}" | awk -F '.' '{print $3}' | awk -F '-' '{print $1}')
+[ -z "${patch_number}" ] && patch_number=0

24-30: Quote item_encoded when passing to jq_decode
Although base64 strings rarely contain spaces, quoting is safer and silences ShellCheck SC2086/SC2046.

-    item_decoded=$(jq_decode ${item_encoded})
+    item_decoded=$(jq_decode "${item_encoded}")
scripts/download-workflow-binaries.sh (1)

38-45: Temporary extraction directory is never cleaned

dist/unzip accumulates content if the loop aborts early or new zips reuse identical filenames.
Using a fresh workspace per artifact avoids bleed-through:

tmpdir=$(mktemp -d)
unzip -o "${mydir}/dist/zip/${artifact_name}.zip" -d "$tmpdir"
for f in "$tmpdir"/*; do; done
rm -rf "$tmpdir"

This also sidesteps the collision concern above.

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 15df340 and 8494a53.

📒 Files selected for processing (10)
  • .github/workflows/package.yaml (4 hunks)
  • deploy/nfpm/README.md (3 hunks)
  • deploy/nfpm/copyright (1 hunks)
  • deploy/nfpm/nfpm.yaml (1 hunks)
  • deploy/nfpm/package-post-install.sh (7 hunks)
  • deploy/nfpm/package-post-uninstall.sh (1 hunks)
  • deploy/nfpm/package-pre-install.sh (1 hunks)
  • deploy/nfpm/package-pre-uninstall.sh (1 hunks)
  • scripts/download-workflow-binaries.sh (2 hunks)
  • scripts/generate-changelog.sh (1 hunks)
🚧 Files skipped from review as they are similar to previous changes (5)
  • deploy/nfpm/copyright
  • deploy/nfpm/nfpm.yaml
  • .github/workflows/package.yaml
  • deploy/nfpm/package-post-uninstall.sh
  • deploy/nfpm/README.md
🧰 Additional context used
🧠 Learnings (6)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.553Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-09-30T08:27:16.849Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
scripts/download-workflow-binaries.sh (13)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.177Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
deploy/nfpm/package-pre-uninstall.sh (19)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.177Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.553Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
scripts/generate-changelog.sh (19)
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.177Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6344
File: hoprd/rest-api/src/lib.rs:1543-1544
Timestamp: 2024-06-27T20:20:07.355Z
Learning: The user, Teebor-Choka, agrees with the suggestion to enforce path length constraints directly in the request validation for `hoprd/rest-api/src/lib.rs`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6344
File: hoprd/rest-api/src/lib.rs:1543-1544
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user, Teebor-Choka, agrees with the suggestion to enforce path length constraints directly in the request validation for `hoprd/rest-api/src/lib.rs`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.553Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The user acknowledged the inconsistency in the usage of `METRIC_TICKETS_COUNT` across different parts of the codebase, which could lead to runtime errors.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user acknowledged the inconsistency in the usage of `METRIC_TICKETS_COUNT` across different parts of the codebase, which could lead to runtime errors.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
deploy/nfpm/package-post-install.sh (27)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.177Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6511
File: tests/test_integration.py:204-225
Timestamp: 2024-09-30T22:09:43.172Z
Learning: In test code, it's acceptable to use sensitive environment variables like `PRIVATE_KEY` and `IDENTITY_PASSWORD` without additional security measures, as they are testing values.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.553Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-07-28T07:26:06.634Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6542
File: hoprd/hoprd/Cargo.toml:74-74
Timestamp: 2024-10-11T09:28:07.406Z
Learning: In `hoprd/hoprd/src/main.rs`, within the `init_logger` function, the Rust code checks the `HOPRD_LOG_FORMAT` environment variable and configures the `tracing_subscriber` to output logs in JSON format when it is set to `"json"`.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6580
File: hoprd/rest-api/src/lib.rs:2529-2530
Timestamp: 2024-10-30T11:46:41.005Z
Learning: In `hoprd/rest-api/src/lib.rs`, avoid logging connected peers to prevent potential data exposure. Remove unnecessary logging statements that might reveal sensitive information.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6307
File: deploy/compose/.env.example:13-17
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The HOPR admin service functions as a proxy nginx service and does not require a high memory limit.
deploy/nfpm/package-pre-install.sh (24)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.177Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6972
File: .github/workflows/audit-pr.yaml:25-32
Timestamp: 2025-04-02T11:36:56.281Z
Learning: For HOPR projects, auditing tools like cargo-audit should be managed through the Nix environment rather than installed separately to ensure consistency and reproducibility.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.553Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: README.md:166-171
Timestamp: 2025-06-30T10:14:33.666Z
Learning: The maintainer ausias-armesto prefers to keep environment variable configuration steps directly within installation instructions rather than separating them into different sections, as demonstrated with the Alpine package manager installation section in the README.md.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-10-09T06:16:18.170Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6142
File: logic/strategy/src/aggregating.rs:374-379
Timestamp: 2024-07-28T07:26:06.634Z
Learning: In unit tests within the `hoprnet` project, explicit error handling such as using `expect` is considered acceptable for immediate feedback on failures.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6345
File: hopr-socks/hopr-socks-server/Cargo.toml:20-20
Timestamp: 2024-06-21T20:51:35.871Z
Learning: All code and packages in the `hoprnet` project should use the workspace level dependency of `reqwest`.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6546
File: transport/p2p/src/lib.rs:224-228
Timestamp: 2024-10-11T13:09:01.392Z
Learning: In the HOPR project, basic libp2p transport configurations should be configurable via environment variables.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7142
File: README.md:154-157
Timestamp: 2025-05-22T21:00:05.773Z
Learning: The HOPR codebase follows a specific naming convention where CLI flags use camelCase (e.g., --noKeepLogs), Rust struct fields use snake_case (e.g., no_keep_logs), and environment variables use uppercase with underscores (e.g., HOPRD_INDEXER_DISABLE_KEEP_LOGS).
🪛 Shellcheck (0.10.0)
scripts/generate-changelog.sh

[warning] 104-104: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 132-132: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 145-145: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 146-146: Declare and assign separately to avoid masking return values.

(SC2155)


[warning] 148-148: Declare and assign separately to avoid masking return values.

(SC2155)

deploy/nfpm/package-post-install.sh

[warning] 202-202: To redirect stdout+stderr, 2>&1 must be last (or use '{ cmd > file; } 2>&1' to clarify).

(SC2069)

deploy/nfpm/package-pre-install.sh

[warning] 52-52: Quote this to prevent word splitting.

(SC2046)

⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (11)
  • GitHub Check: hoprd / docker
  • GitHub Check: hopli / docker
  • GitHub Check: Docs / Rust
  • GitHub Check: Pre-commit / Pre-commit
  • GitHub Check: Audit / Audit
  • GitHub Check: Lint / Lint
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: tests-unit
  • GitHub Check: tests-unit-nightly
  • GitHub Check: Build Candidate Binaries (hoprd)
  • GitHub Check: Build Candidate Binaries (hopli)

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (2)
.github/workflows/create-release.yaml (2)

68-73: Changelog step may fail if docs/changelog directory is missing

tee docs/changelog/changelog.md will error when the parent directory does not exist in a fresh checkout. Create the directory first (or rely on mkdir -p) to avoid a silent workflow break on a brand-new branch.

-  ./scripts/generate-changelog.sh ${{ steps.setup.outputs.current_version }} github | tee docs/changelog/changelog.md
+  mkdir -p docs/changelog
+  ./scripts/generate-changelog.sh ${{ steps.setup.outputs.current_version }} github | tee docs/changelog/changelog.md

124-129: Wildcard upload can break when either directory is empty

The unquoted globs ./dist/bin/* ./dist/packages/* expand literally when one of the directories is missing or empty, passing a non-existent path to gh release upload and failing the job. Consider enabling nullglob/failglob or guarding with find.

-for artifact in ./dist/bin/* ./dist/packages/*; do
+shopt -s nullglob
+for artifact in ./dist/bin/* ./dist/packages/*; do
📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d7c51d2 and 950763f.

📒 Files selected for processing (3)
  • .github/workflows/close-release.yaml (2 hunks)
  • .github/workflows/create-release.yaml (2 hunks)
  • justfile (2 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • .github/workflows/close-release.yaml
  • justfile
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.562Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.192Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-09-30T08:27:16.849Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
.github/workflows/create-release.yaml (9)
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6600
File: hoprd/rest-api/src/messages.rs:69-71
Timestamp: 2025-01-17T09:38:56.228Z
Learning: Breaking changes are allowed in PR #6600 as it's part of a major release (v3.0) that overhauls the API. Changes include making fields mandatory and removing deprecated fields.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (8)
  • GitHub Check: hopli / docker
  • GitHub Check: Pre-commit / Pre-commit
  • GitHub Check: Audit / Audit
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: Lint / Lint
  • GitHub Check: tests-unit-nightly
  • GitHub Check: Build Candidate Binaries (hoprd)
  • GitHub Check: tests-unit
🔇 Additional comments (1)
.github/workflows/create-release.yaml (1)

133-142: Confirm token scopes for repository-dispatch

GH_RUNNER_TOKEN must have repo + workflow scope on the target repo (homebrew-hoprd). If this secret is scoped only to hoprnet/hoprnet, the dispatch will silently fail. Double-check the PAT or switch to GITHUB_TOKEN + proper permissions if the Homebrew repo lives in the same org.

@tolbrino tolbrino added this to the 3.0.0 milestone Jul 15, 2025
Copy link
Contributor

@tolbrino tolbrino left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Where is the homebrew formula. Seems like PR title and description are outdated.

ausias-armesto and others added 3 commits July 15, 2025 12:50
Co-authored-by: Tino Breddin <tolbrino@users.noreply.github.com>
Co-authored-by: Tino Breddin <tolbrino@users.noreply.github.com>
Co-authored-by: Tino Breddin <tolbrino@users.noreply.github.com>
@ausias-armesto ausias-armesto changed the title feat: Add Homebrew formula to install on MacOS feat: Add binary signatures and multiple os package improvements Jul 15, 2025
@ausias-armesto
Copy link
Contributor Author

Where is the homebrew formula. Seems like PR title and description are outdated.

PR Title updated. The homebrew formula is at this repository:
https://github.com/hoprnet/homebrew-hoprd

It is triggered at the create-release.yaml pipeline
The formula at that repository is finished and working, but I need to finish there the pipeline so it accepts this trigger. But first I need a release cut with binaries available.

@ausias-armesto ausias-armesto requested a review from tolbrino July 15, 2025 11:01
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🧹 Nitpick comments (1)
.github/workflows/build-binaries.yaml (1)

150-166: Consolidate the four nearly-identical upload steps & set retention-days

Uploading the binary, its signature, the hash and the hash-signature in four separate steps:

  1. Repeats the same YAML.
  2. Incurs four extra runner invocations.
  3. Leaves artifact retention at the default (90 days) instead of an explicit policy.

Consider a single step with a multi-line path: plus an explicit retention:

-      - name: Publish Github Workflow artifact
-        uses: actions/upload-artifact@v4
-        with:
-          name: ${{ steps.vars.outputs.binary }}-${{ steps.vars.outputs.target }}
-          path: ${{ github.workspace }}/result/bin/${{ steps.vars.outputs.binary }}
+# Single upload for all four files, retained 30 days
+      - name: Publish ${{ steps.vars.outputs.binary }} artifacts
+        uses: actions/upload-artifact@v4
+        with:
+          name: ${{ steps.vars.outputs.binary }}-${{ steps.vars.outputs.target }}
+          path: |
+            ${{ github.workspace }}/result/bin/${{ steps.vars.outputs.binary }}
+            ${{ github.workspace }}/result/bin/${{ steps.vars.outputs.binary }}.sig
+            ${{ github.workspace }}/result/bin/${{ steps.vars.outputs.binary }}.sha256
+            ${{ github.workspace }}/result/bin/${{ steps.vars.outputs.binary }}.sha256.asc
+          retention-days: 30

Less YAML, same result, clearer retention policy.

📜 Review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between a770a9c and c9e035a.

📒 Files selected for processing (3)
  • .github/workflows/build-binaries.yaml (2 hunks)
  • .gitignore (1 hunks)
  • flake.nix (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • .gitignore
  • flake.nix
🧰 Additional context used
🧠 Learnings (2)
📓 Common learnings
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6630
File: crypto/packet/src/por.rs:84-84
Timestamp: 2024-11-13T17:56:37.536Z
Learning: In PR #6630, the changes include the removal of ticket validation from the last hop and fixes for Index Offset handling as specified in the PR objectives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.562Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-07-28T07:26:06.634Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6244
File: transport/protocol/src/ack/processor.rs:31-32
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The GitHub issue to standardize the usage of `METRIC_TICKETS_COUNT` across the codebase was successfully created and can be tracked at https://github.com/hoprnet/hoprnet/issues/6245.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.192Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-09-30T08:27:16.849Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
.github/workflows/build-binaries.yaml (29)
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:61-97
Timestamp: 2024-11-26T17:47:32.384Z
Learning: The code in the 'Set environment variables' step in `.github/workflows/build-binaries.yaml` is obsolete and should not be reviewed in future code reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6681
File: .github/workflows/build-binaries.yaml:0-0
Timestamp: 2024-11-26T17:47:21.777Z
Learning: In `.github/workflows/build-binaries.yaml`, when writing shell scripts in GitHub Actions workflows, the user prefers to set environment variables individually rather than grouping them together.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7277
File: .github/workflows/package.yaml:91-102
Timestamp: 2025-07-02T15:47:44.135Z
Learning: In the hoprnet repository packaging workflow (.github/workflows/package.yaml), the "Test Package centos" step correctly uses `just test-package rpm` because CentOS is Red Hat-based and uses RPM package format. Additionally, ArchLinux packages are built with a `.archlinux` file extension but uploaded as artifacts with `.pkg.tar.zst` naming convention - this is the intended design and not a mismatch.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6886
File: nix/rust-package.nix:84-84
Timestamp: 2025-02-25T00:35:33.437Z
Learning: When transitioning from vendored dependencies to a private proxy registry in Rust projects, GitHub Actions workflows need to be refactored to accommodate the new update strategy, particularly workflows handling dependency updates like renovate-cargo-update.yaml.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:66-68
Timestamp: 2025-06-19T10:10:00.368Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), the `just package` command creates a single distribution package that includes all binaries (hoprd and hopli) for the target architecture. The workflow downloads both hoprd and hopli artifacts, extracts them to ./dist/bin, and nfpm packages both binaries together into one .deb, .rpm, or .apk file per target.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:0-0
Timestamp: 2025-06-19T11:37:27.410Z
Learning: In the HOPR packaging workflow (.github/workflows/package.yaml), both hoprd and hopli binaries are downloaded and used together in a single package creation process. The `just package` command creates one distribution package (.deb, .rpm, or .apk) per target that contains both binaries, which is why the workflow only uploads one package per format rather than separate packages for each binary.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7280
File: .github/workflows/checks-pre-commit.yaml:30-36
Timestamp: 2025-07-01T13:09:08.718Z
Learning: In the hoprnet repository's GitHub Actions workflow architecture, ausias-armesto prefers to centralize input resolution and fallback logic in the main checks.yaml workflow, which then calls individual reusable workflows like checks-pre-commit.yaml. The individual workflows are designed to be called primarily through the main workflow rather than directly, so fallback values in the individual workflows may be considered redundant.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/build-dappnode.yaml:40-40
Timestamp: 2025-05-27T16:23:08.868Z
Learning: In the hoprnet repository's GitHub workflows, labels are passed from build.yaml to build-dappnode.yaml with a trailing comma using `format('{0},', join(github.event.pull_request.labels.*.name, ','))`. Therefore, the condition checks in build-dappnode.yaml correctly use `format('package:{0},', inputs.dappnode_repository)` with a trailing comma to match the exact label format and prevent false positives.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:34-43
Timestamp: 2025-06-30T08:33:20.991Z
Learning: In the hoprnet repository, the maintainer ausias-armesto prefers to add commit types to the semantic PR validation workflow incrementally as needed, rather than preemptively adding all possible types. This conservative approach keeps the workflow configuration lean.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6366
File: ethereum/contracts/contracts-addresses.json:0-0
Timestamp: 2024-07-11T10:39:11.293Z
Learning: The user has asked to add a Git pre-commit hook to the PR to prevent changes to the `contracts-addresses.json` file.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6545
File: transport/p2p/src/swarm.rs:491-494
Timestamp: 2024-10-11T10:43:34.869Z
Learning: When reviewing revert pull requests in the `hoprnet/hoprnet` repository, avoid making code recommendations or suggestions.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: .github/workflows/package.yaml:28-28
Timestamp: 2025-06-19T10:07:29.649Z
Learning: In GitHub Actions reusable workflows, the github.event_name context may inherit from the parent workflow rather than being set to 'workflow_call', allowing conditions like 'github.event_name == 'pull_request'' to work correctly when the parent workflow was triggered by a pull_request event.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-10-09T06:16:18.170Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6502
File: flake.nix:12-14
Timestamp: 2024-09-30T08:27:16.849Z
Learning: The project already has CI workflows that automatically check for compatibility issues when updating dependencies, including compiling smart contracts with new Solidity versions, running the test suite, checking for compiler warnings or deprecation notices, and reviewing changelogs for breaking changes.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/nfpm/package-pre-uninstall.sh:4-7
Timestamp: 2025-07-10T11:28:36.192Z
Learning: In the HOPR project, when working with nfpm package scripts (like package-pre-uninstall.sh), certain error handling patterns like `|| true` and stderr redirection may interfere with lintian (Debian package checker) compliance requirements. The maintainer ausias-armesto prioritizes lintian compliance over defensive error handling in these scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7251
File: deploy/nfpm/install.sh:68-68
Timestamp: 2025-06-19T10:11:36.259Z
Learning: In the HOPR project, the user ausias-armesto prefers interactive installation prompts that give users full control over configuration rather than automated defaults, especially for initial versions of installation scripts.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7297
File: deploy/Formula/hoprd.rb:427-427
Timestamp: 2025-07-10T11:37:58.562Z
Learning: In the HOPR Homebrew formula (deploy/Formula/hoprd.rb), the API endpoint display intentionally uses HOPRD_HOST (which includes the P2P address and port) rather than HOPRD_API_HOST in the installation summary, as confirmed by maintainer ausias-armesto.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6932
File: common/internal-types/src/account.rs:54-69
Timestamp: 2025-04-22T12:08:59.066Z
Learning: An issue was created to track the future replacement of the temporary `key_id()` implementation with a smart contract assigned ID.
Learnt from: NumberFour8
PR: hoprnet/hoprnet#6932
File: common/internal-types/src/account.rs:54-69
Timestamp: 2025-04-22T12:08:59.066Z
Learning: An issue was created to track the future replacement of the temporary `key_id()` implementation with a smart contract assigned ID.
Learnt from: mjadach-iv
PR: hoprnet/hoprnet#6663
File: deploy/compose/.env.sample:57-57
Timestamp: 2024-11-21T13:58:22.345Z
Learning: In code reviews for this project, focus comments on the changes made in the PR, and avoid discussing unrelated code.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#7231
File: flake.nix:599-608
Timestamp: 2025-06-11T13:34:45.385Z
Learning: The repository intentionally relies on Commitizen’s default configuration; absence of a `.cz.*` file or `[tool.commitizen]` section is expected and should not be flagged in future reviews.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#6635
File: .github/workflows/build-dappnode.yaml:51-52
Timestamp: 2024-11-14T17:33:28.735Z
Learning: In the `.github/workflows/build-dappnode.yaml` file, explicit error handling for GitHub API calls is not required.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/add-labels.yaml:49-57
Timestamp: 2025-05-27T16:21:03.705Z
Learning: GitHub CLI (gh) accepts GITHUB_TOKEN as an environment variable for authentication in GitHub Actions workflows, not just GH_TOKEN. The environment variable GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} works correctly with gh commands like "gh pr edit".
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7191
File: .github/workflows/open-pr.yaml:83-95
Timestamp: 2025-06-30T08:36:01.731Z
Learning: The self-hosted-hoprnet-small runners in the hoprnet repository have GitHub CLI (gh) pre-installed and available for use in workflows.
Learnt from: Teebor-Choka
PR: hoprnet/hoprnet#6772
File: scripts/generate-python-sdk.sh:1-10
Timestamp: 2025-01-15T16:14:10.492Z
Learning: In shell scripts, make paths configurable by using environment variables with default values using parameter expansion (e.g., `${VAR:-default}`). This allows users to override the default behavior without modifying the script.
Learnt from: ausias-armesto
PR: hoprnet/hoprnet#7111
File: .github/scripts/workflow-stats.sh:89-96
Timestamp: 2025-05-20T12:06:45.616Z
Learning: The calculate_stats function in workflow-stats.sh uses eval for dynamic array expansion, and this implementation should be preserved as the nameref alternative doesn't work in this environment.
Learnt from: tolbrino
PR: hoprnet/hoprnet#7070
File: nix/testShell.nix:22-23
Timestamp: 2025-04-15T19:24:23.570Z
Learning: In the HOPR project, the `autoPatchelf` command from Nix can handle the case where the target directory (like ./.venv) doesn't exist, so no additional directory existence check is needed before running it.
Learnt from: tolbrino
PR: hoprnet/hoprnet#6651
File: nix/rust-package.nix:35-39
Timestamp: 2024-11-20T08:43:53.099Z
Learning: In the `nix/rust-package.nix` file, replacing hardcoded interpreter paths with `${stdenv.hostPlatform.platform.dynamicLinker}` doesn't work as intended, so hardcoded interpreter paths are necessary.
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (11)
  • GitHub Check: hoprd / docker
  • GitHub Check: hopli / docker
  • GitHub Check: Docs / Rust
  • GitHub Check: Pre-commit / Pre-commit
  • GitHub Check: Zizmor / Zizmor
  • GitHub Check: Audit / Audit
  • GitHub Check: Lint / Lint
  • GitHub Check: Build Candidate Binaries (hopli)
  • GitHub Check: tests-unit
  • GitHub Check: Build Candidate Binaries (hoprd)
  • GitHub Check: tests-unit-nightly
🔇 Additional comments (1)
.github/workflows/build-binaries.yaml (1)

90-90: Skipping review of this line – the whole “Set environment variables” block has been declared obsolete in earlier PR discussions.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
toolchain Developer and product happiness
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Create OS packages for publishing and distributing hoprnet
2 participants