d36718542c
Use the Rust tracing crate for C++ logging This PR swaps in the `tracing` crate (via FFI) for logging to either standard output or `debug.log`. It transparently maps all existing `LogPrintf` and `LogPrint` invocations to info-level `tracing` events, and passes through correct file and line information. `error` invocations are mapped to error-level `tracing` events, currently without line information (due to the way that `error` is used in the codebase; swapping individual callsites to the new `LogError` macro will provide that information). The end-goal for this change is that we don't need to make any disruptive changes to the codebase, but we can start to leverage `tracing`-specific functionality where we want to, such as providing extra fields on certain log lines (that can be filtered for), adding spans to record the flow of execution through `zcashd`, and logging within C++ and Rust simultaneously. Support for extra fields on spans and events will be added in a subsequent PR. The `-debug` config options are converted at launch into their corresponding directives for tracing's `EnvFilter`. The new `setlogfilter` RPC method allows this filter to be reloaded dynamically. The syntax is documented in the `setlogfilter` help text, as well as here: https://docs.rs/tracing-subscriber/0.2.7/tracing_subscriber/filter/struct.EnvFilter.html#directives When `-printtoconsole` is specified, the output now includes timestamps and ANSI encoding :) |
||
---|---|---|
.cargo | ||
.github | ||
build-aux/m4 | ||
contrib | ||
depends | ||
doc | ||
qa | ||
share | ||
src | ||
zcutil | ||
.gitattributes | ||
.gitignore | ||
CONTRIBUTING.md | ||
COPYING | ||
Cargo.lock | ||
Cargo.toml | ||
INSTALL | ||
Makefile.am | ||
README.md | ||
autogen.sh | ||
code_of_conduct.md | ||
configure.ac | ||
libzcashconsensus.pc.in | ||
responsible_disclosure.md | ||
rust-toolchain |
README.md
Zcash 3.1.0
What is Zcash?
Zcash is an implementation of the "Zerocash" protocol. Based on Bitcoin's code, Zcash intends to offer a far higher standard of privacy through a sophisticated zero-knowledge proving scheme that preserves confidentiality of transaction metadata. More technical details are available in our Protocol Specification.
This software is the Zcash client. It downloads and stores the entire history of Zcash transactions; depending on the speed of your computer and network connection, the synchronization process could take a day or more once the blockchain has reached a significant size.
🔒 Security Warnings
See important security warnings on the Security Information page.
Zcash is experimental and a work in progress. Use it at your own risk.
📒 Deprecation Policy
This release is considered deprecated 16 weeks after the release day. There is an automatic deprecation shutdown feature which will halt the node some time after this 16-week period. The automatic feature is based on block height.
Getting Started
Please see our user guide for joining the main Zcash network.
Need Help?
- 📘 See the documentation at the ReadTheDocs for help and more information.
- 📨 Ask for help on the Zcash forum.
- 💬 Chat with our support community on Discord
Participation in the Zcash project is subject to a Code of Conduct.
Building
Build Zcash along with most dependencies from source by running the following command:
./zcutil/build.sh -j$(nproc)
Currently, Zcash is only officially supported on Debian and Ubuntu.
License
For license information see the file COPYING.