rust-payjoin icon indicating copy to clipboard operation
rust-payjoin copied to clipboard

Allow building payjoin crate with no default features

Open Johnosezele opened this issue 4 months ago • 2 comments

Previously, the payjoin crate would fail to build if none of the features 'v1', 'v2', or 'directory' were enabled, due to an explicit compile_error! macro. This prevented the use of tools like cargo-all-features for comprehensive CI and dead code detection.

This change removes the compile_error! and replaces it with a doc-only module that is included when no features are enabled, making the crate a no-op in that configuration. The documentation and Cargo.toml are updated to clarify that at least one of the main features must be enabled for any functionality.

This enables better CI, linting, and future modularity, while preserving clear guidance for users and contributors.

Closes #921

Johnosezele avatar Aug 17 '25 14:08 Johnosezele

Pull Request Test Coverage Report for Build 17022142774

Details

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 86.314%

Totals Coverage Status
Change from base Build 17019408534: 0.0%
Covered Lines: 7726
Relevant Lines: 8951

💛 - Coveralls

coveralls avatar Aug 17 '25 14:08 coveralls

In the dev call we discussed this, but i forgot to follow up here, I think we should hold off until after 1.0 because using cargo all features is not currently practical (too many features means it takes a long time)

nothingmuch avatar Aug 29 '25 16:08 nothingmuch