Skip to content

refactor(netwatch)!: improve platform feature-gating and don't reexport netdev types#163

Draft
Frando wants to merge 1 commit into
mainfrom
Frando/refactor-platform-impls
Draft

refactor(netwatch)!: improve platform feature-gating and don't reexport netdev types#163
Frando wants to merge 1 commit into
mainfrom
Frando/refactor-platform-impls

Conversation

@Frando

@Frando Frando commented Jun 15, 2026

Copy link
Copy Markdown
Member

Description

We currently reexport items from netdev on platforms supported by netdev, and recreate identical types on other platforms. This is brittle and easy to break.

We also relied on module-path-rewriting, which is hard to follow and easy to miss.

This PR fixes both by restructuring the platform impl. It now defines shared types in one place, and then delegates to platform impls in a very normal way. The platforms using netdev still share code, but we no longer re-export any types from netdev.

Also adds a check-external-types CI check to validate this.

Breaking Changes

Notes & open questions

Change checklist

  • Self-review.
  • Documentation updates following the style guide, if relevant.
  • Tests if relevant.
  • All breaking changes documented.

@github-actions

github-actions Bot commented Jun 15, 2026

Copy link
Copy Markdown

Documentation for this PR has been generated and is available at: https://n0-computer.github.io/net-tools/pr/163/docs/net_tools/

Last updated: 2026-06-15T10:16:56Z

@Frando Frando mentioned this pull request Jun 15, 2026
4 tasks
Base automatically changed from has_netdev to main June 15, 2026 10:12
@Frando Frando force-pushed the Frando/refactor-platform-impls branch from ac13c84 to 86ded18 Compare June 15, 2026 10:16
@n0bot n0bot Bot added this to iroh Jun 15, 2026
@github-project-automation github-project-automation Bot moved this to 🚑 Needs Triage in iroh Jun 15, 2026
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.

1 participant