Skip to content

refactor(iroh): toggle unstable item visibility with the visibility crate#4339

Open
Frando wants to merge 1 commit into
Frando/gate-net-reportfrom
Frando/visibility-crate
Open

refactor(iroh): toggle unstable item visibility with the visibility crate#4339
Frando wants to merge 1 commit into
Frando/gate-net-reportfrom
Frando/visibility-crate

Conversation

@Frando

@Frando Frando commented Jun 12, 2026

Copy link
Copy Markdown
Member

Description

Based on #4338

Replace the cfg_attr(not(feature = ...), allow(unreachable_pub)) suppressions on the unstable-net-report and unstable-custom-transports items with cfg_attr(feature = ..., visibility::make(pub)) on a pub(crate) base. The items (and the public methods of those types) are now genuinely pub(crate) when the feature is off and pub when it is on, so no lint suppression is needed.

Change checklist

  • Self-review.

…rate

Replace the `cfg_attr(not(feature = ...), allow(unreachable_pub))` suppressions on
the `unstable-net-report` and `unstable-custom-transports` items with
`cfg_attr(feature = ..., visibility::make(pub))` on a `pub(crate)` base. The items
(and the public methods of those types) are now genuinely `pub(crate)` when the
feature is off and `pub` when it is on, so no lint suppression is needed.

`Endpoint::last_net_report` and the internal net report getter are gated behind
`unstable-net-report` to match, since they expose `Report`.
@github-actions

Copy link
Copy Markdown

Documentation for this PR has been generated and is available at: https://n0-computer.github.io/iroh/pr/4339/docs/iroh/

Last updated: 2026-06-12T11:22:53Z

@github-actions

Copy link
Copy Markdown

Netsim report & logs for this PR have been generated and is available at: LOGS
This report will remain available for 3 days.

Last updated for commit: 6d63e9d

@n0bot n0bot Bot added this to iroh Jun 12, 2026
@github-project-automation github-project-automation Bot moved this to 🚑 Needs Triage in iroh Jun 12, 2026
@Frando

Frando commented Jun 15, 2026

Copy link
Copy Markdown
Member Author

I'm not 100% sold that this is an improvement. It somehow makes it harder to see for me which APIs are public, even if behind a feature flag.

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

Labels

None yet

Projects

Status: 🚑 Needs Triage

Development

Successfully merging this pull request may close these issues.

2 participants