Commit graph

7 commits

Author SHA1 Message Date
Charlie Marsh
a53f697f62
Use tracing for user-facing output (#63)
The setup is now as follows:

- All user-facing logging goes through `tracing` at an `info` leve.
(This excludes messages that go to `stdout`, like the compiled
`requirements.txt` file.)
- We have `--quiet` and `--verbose` command-line flags to set the
tracing filter and format defaults. So if you use `--verbose`, we
include timestamps and targets, and filter at `puffin=debug` level.
- However, we always respect `RUST_LOG`. So you can override the
_filter_ via `RUST_LOG`.

For example: the standard setup filters to `puffin=info`, and doesn't
show timestamps or targets:

<img width="1235" alt="Screen Shot 2023-10-08 at 3 41 22 PM"
src="54ca4db6-c66a-439e-bfa3-b86dee136e45">

If you run with `--verbose`, you get debug logging, but confined to our
crates:

<img width="1235" alt="Screen Shot 2023-10-08 at 3 41 57 PM"
src="c5c1af11-7f7a-4038-a173-d9eca4c3630b">

If you want verbose logging with _all_ crates, you can add
`RUST_LOG=debug`:

<img width="1235" alt="Screen Shot 2023-10-08 at 3 42 39 PM"
src="0b5191f4-4db0-4db9-86ba-6f9fa521bcb6">

I think this is a reasonable setup, though we can see how it feels and
refine over time.

Closes https://github.com/astral-sh/puffin/issues/57.
2023-10-08 15:46:06 -04:00
Charlie Marsh
9be02d1590
Skip already-installed dependencies during sync command (#43)
Closes https://github.com/astral-sh/puffin/issues/35.
2023-10-07 19:26:45 +00:00
Charlie Marsh
bc1736feff
Add a freeze command to list installed dependencies (#42)
A pre-requisite for https://github.com/astral-sh/puffin/issues/35.
2023-10-07 18:46:09 +00:00
Charlie Marsh
f3015ffc1f
Add a clean command to clear the cache (#41) 2023-10-07 15:19:03 +00:00
Charlie Marsh
dab70a661a
Change install to sync (with sync semantics) (#24)
For better separate at this stage (and following `pip-tools`), it's now
`puffin sync`, and it assumes `--no-deps`.
2023-10-06 19:42:58 +00:00
Charlie Marsh
9ea6eaeb10
Add separate compile and install commands (#17)
Closes #9.
2023-10-05 21:44:31 -04:00
Charlie Marsh
53607df7c6 Add a requirements.txt parser 2023-10-05 12:45:38 -04:00