Comments (5)
Thank you for the feature request. This raises the question of what tool cargo public-api
is or want to be. Do we want it to become sort of a linter? I'm not sure we want that actually. But I am open to be convinced otherwise, and am happy to discuss this.
But, wouldn't it be better to fix this in rustdoc/rustc directly? Sounds like a bug in rustdoc/rustc.
from cargo-public-api.
I would say it's already a linter with "deny" set of options for diffs. I'm going to fill an issue with rustdoc, but I believe it more likely a by design behaviour: those lints suppose to operate on a crate level and rustdoc doesn't really have a concept of public API for workspaces.
I would say this tool fills this gap - it allows complex rust codebases to introduce an "API surface concept" including stuff re-exported from internal or external crates and provide a toolset to work with that.
from cargo-public-api.
Did you have time to file an upstream issue yet?
To me, a "linter" is a tool that finds problems with a specific version of some code. So the --deny
functionality we have is not linting functionality, since it applies to a two different versions of the same code. I will try to not get into a purely semantic discussion, but I still wanted to clarify what I mean by "linter".
In order to help us evaluate the use case you have in mind, would you mind providing some minimal example code please, along with how you would invoke cargo public-api
and what output you expect?
from cargo-public-api.
something I just realised, isn't this already possible?
cargo clippy --workspace -- -D missing_docs
from cargo-public-api.
Closing for now. Of course feel free to re-open in case you want to keep discussing this.
from cargo-public-api.
Related Issues (20)
- Auto-bless output and create PR if nightly CI build fails
- Plain `--help` should also show `diff --help` HOT 2
- rustdoc-json: add support for binaries HOT 5
- Group items even if multiple inherent `impl`s are used HOT 11
- Support for ignoring `#[automatically_derived]` (`Clone`, `Eq`, etc) HOT 2
- cannot enable features for crate with diff
- Change `PublicApi::from_rustdoc_json(path, Options::default())` to `public_api::Builder::from_rustdoc_json(path).build()`
- Resolve `Self` to concrete type to avoid unnecessary diffs HOT 6
- Probable bug in `Builder::clear_toolchain` HOT 1
- Add check for presence of dependencies in the public API HOT 3
- Support sparse creates.io registry HOT 5
- `serenity:all` re-exports triggers endless RAM-eating loop HOT 8
- Failure with `nightly-2023-05-24`
- Generic type information missing for items in paths HOT 5
- Simplify diff when moving an item to a different inherent impl while changing it HOT 11
- Error if the library target name is different than the package name HOT 2
- Installation instructions on README can be clarified HOT 2
- Make error message more helpful when `rustup` is not in `PATH` HOT 15
- New `rustdoc-json` minor release? HOT 2
- Add binaries to the releases to support taiki-e/install-action HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cargo-public-api.