open-telemetry / open-telemetry/weaver

Generate a checksum alongside the generated code to detect any manual modifications.

Open
#362 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

ci/cd enhancement template engine
Dominant language
Rust
Stars
486
Forks
108
Avg merge
3d 4h
Merged PRs (30d)
40

Description

The Rust community expressed the need to create a CI check to ensure that no manual modifications have been made to the vendored generated code produced by Weaver. See this comment.

One option would be to update Weaver to generate a checksum (e.g., SHA256) for the generated code and store it in a file alongside the generated code. This would provide everything needed to create a CI check to verify that no manual changes have been made to the code in the repository, assuming we’ve also prevented rust fmt (or any other code formatter) from altering the generated code.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by tracing how Weaver produces the vendored generated code and how the repository’s CI checks that code. Define the checksum file and verification behavior from the issue’s SHA256 proposal, then account for the stated requirement that rustfmt or another formatter must not alter the generated code; done means CI can detect manual modifications.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
build-system, ci-cd, tooling
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.