Skip to content
This repository has been archived by the owner on Nov 5, 2022. It is now read-only.

Cargo team: planning areas #5

Open
5 tasks
nrc opened this issue Oct 10, 2018 · 11 comments
Open
5 tasks

Cargo team: planning areas #5

nrc opened this issue Oct 10, 2018 · 11 comments

Comments

@nrc
Copy link
Member

nrc commented Oct 10, 2018

These are the 'big things' that might be happening in the near-ish future for Cargo, which might be on the 2019 roadmap, and which we should discuss in small 'focus groups' over the next few months. Please add more things and any meta-thoughts, but lets leave discussion of the specifics for later.

  • rustup integration
  • sysroot/extern crate stuff
  • build system integration (and high level refactoring)
  • templates/generate
  • caching/distributing binaries
  • pub/priv deps
  • custom registries (is this just stabilisation?)
  • std-aware/Xargo
  • cargo add, etc.
  • specifying tools versions, toolchain versions
  • profiles (does this overlap enough with build system integration that they should be merged?)
  • metabuild (native deps for sys crates; I'm not really sure what this is)
@dwijnand
Copy link
Member

cargo repl would be nice (possibly based on https://github.com/google/evcxr/tree/master/evcxr_repl?)

@dwijnand
Copy link
Member

Other 'big things' which might be worth undertaking:

(2nd top 👍'd is the sysroot/xargo ticket, already mentioned)

@ehuss
Copy link

ehuss commented Oct 10, 2018

You can look through https://doc.rust-lang.org/nightly/cargo/reference/unstable.html and review the status of all unstable features.

I would say "rename-dependencies" is the closest to stabilization (I don't know of any outstanding issues). We may want to prioritize it, since in might help with 2018 usage.

custom registries (is this just stabilisation?)

There seems to be a lot of unresolved issues in the tracking issue.

metabuild (native deps for sys crates; I'm not really sure what this is)

This is just an easier way to write a build script (using metadata in Cargo.toml instead of writing a Rust program), and can be used for a wide range of things (not just sys crate building). It's low priority until we can find people to play with it.

I have been researching "decoupled features" where Cargo features can be more granular. It sounds like @alexcrichton wants to go with a conservative route to only decouple cross-compiled artifacts. I think there is significant interest in a more pervasive split where normal/build/dev/target-cfg can all receive different features (for example, a feature needed for build is not forced upon your main crate). It's one of the most requested enhancements. I think it would be good to have progress on this...somehow.

@ehuss
Copy link

ehuss commented Oct 17, 2018

Another major area that I think needs attention is reducing disk space usage. There are multiple points to this: automatically cleaning target, improvements to manual cargo clean, and dealing with stale cache files in the registry directory. There are a fair number of issues filed for this, and I see it come up periodically on forums and other places (like llogiq's recent blog post). I have some ideas for some short-term solutions for updating toolchains which I'll post soon. However, I'm not sure if making incremental improvements is a good idea vs. making major changes.

@nrc
Copy link
Member Author

nrc commented Oct 24, 2018

Categorization

I'm not really happy with the names, but the main point is the groupings

  • architecture
    • rustup integration
    • build system integration (and high level refactoring and API)
    • custom profiles
    • build deps only (use case: Docker, CI)
  • download-ish stuff
    • caching/distributing binaries
    • custom registries (is this just stabilisation?)
    • offline mode (remaining work - possible global cache)
  • manifest changes
    • pub/priv deps
    • specifying tools versions, toolchain versions
    • per-target deps
    • more fine-grained feature flags
  • workflow
  • project knowledge stuff
    • std-aware/Xargo
    • sysroot/extern crate stuff
  • maintenance

@nrc
Copy link
Member Author

nrc commented Oct 24, 2018

The kind of things we need to work out for each feature are:

  • use cases
  • why should this be p-high?
    • urgency
    • importance
  • current status
  • how much work to complete
  • surface area
    • CLI
    • manifest changes
  • what could this subsume?
  • how might this interact with other 'big' proposals?
  • a very rough plan for implementation
  • is anyone signed up/keen to do the work?
  • alternatives?

@withoutboats
Copy link

custom registries (is this just stabilisation?)

There's one change I wanted to put in but I've never gotten around to getting green in CI. rust-lang/cargo#5915. Otherwise I think it needs a review to see if everything else is spic & span, then a stabilization PR.

@jtgeibel

This comment has been minimized.

@alexcrichton

This comment has been minimized.

@nrc
Copy link
Member Author

nrc commented Nov 28, 2018

We should also consider what community commands we want to bring in, e.g., cargo tree, cargo add (cc #14), cargo watch, etc.

@nrc
Copy link
Member Author

nrc commented Dec 13, 2018

Notes to self:

  • pipelining builds
  • security issues (work with secure code WG, crates.io team)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants