Skip to content

fix(tonic-prost-build): restore missing emit_rerun_if_changed functionality#2512

Draft
pierrekin wants to merge 1 commit intohyperium:v0.14.xfrom
pierrekin:pk/fix/emit-rerun-if-changed
Draft

fix(tonic-prost-build): restore missing emit_rerun_if_changed functionality#2512
pierrekin wants to merge 1 commit intohyperium:v0.14.xfrom
pierrekin:pk/fix/emit-rerun-if-changed

Conversation

@pierrekin
Copy link
Copy Markdown

Motivation

Solves issue where emit_rerun_if_changed is ignored.

Based on a cursory analysis it seems emit_rerun_if_changed was broken since the tonic-prost-build extraction:

  • June 21, 2022 (commit 1d2083a): emit_rerun_if_changed feature added to tonic-build with working implementation
  • July 25, 2025 (commit 969408e): tonic-prost-build extracted from tonic-build - implementation accidentally omitted

Original implementation: 1d2083a#diff-b0934b805d6c8c11cd87db5e7e77d3e5d2d72d5c72d36e16ce7e99516a8e6b84R435-R449

Extraction commit that lost the implementation: 969408e

Solution

Restores the missing implementation that emits cargo:rerun-if-changed directives for proto files.

@pierrekin pierrekin changed the title fix(tonic-prost-build): restore missing emit_rerun_if_changed functio… fix(tonic-prost-build): restore missing emit_rerun_if_changed functionality Feb 18, 2026
@pierrekin
Copy link
Copy Markdown
Author

pierrekin commented Feb 18, 2026

After reviewing the code more carefully, I believe it was the intention of the original author to move the implementation to the prost-build. I will make a subsequent commit that implements this, but it will need to wait for an upstream change to prost-build.

@pierrekin pierrekin marked this pull request as draft February 18, 2026 13:20
@pierrekin
Copy link
Copy Markdown
Author

A note to reviewers:

After reviewing the code more carefully, I believe it was the intention of the original author to move the implementation to prost-build.

feat(prost-build): add emit-rerun-if-changed functionality #1402

If my PR is accepted by Tokio, then I think we can continue along that route, if not, we should consider emitting the directives here as per my previous commit:

dea524c

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant