mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-04-19 11:18:09 +02:00
Merge bitcoin/bitcoin#23522: Improve fs::PathToString documentation
9b575f1c73Improve fs::PathToString documentation (Russell Yanofsky) Pull request description: Add a developer note about avoiding `fs::PathToString` in RPCs, and improve some other `fs::PathToString` comments. Developer note might have been useful in two recent review comments: - https://github.com/bitcoin/bitcoin/pull/23398#discussion_r741585271 - https://github.com/bitcoin/bitcoin/pull/23155#discussion_r749824259 ACKs for top commit: laanwj: Documentation review ACK9b575f1c73jamesob: ACK9b575f1c73prayank23: ACK9b575f1c73hebasto: ACK9b575f1c73shaavan: ACK9b575f1c73Tree-SHA512: b8b3ecb6208c3897241e4f24dcec64fe7cf091bc79388862cf5f4b315cb8e804939981c4bed4c81dbff99ec9f750bad99015d0f04890704ac9df63c2a6719b6d
This commit is contained in:
@@ -1254,6 +1254,12 @@ A few guidelines for introducing and reviewing new RPC interfaces:
|
||||
|
||||
- *Rationale*: User-facing consistency.
|
||||
|
||||
- Use `fs::path::u8string()` and `fs::u8path()` functions when converting path
|
||||
to JSON strings, not `fs::PathToString` and `fs::PathFromString`
|
||||
|
||||
- *Rationale*: JSON strings are Unicode strings, not byte strings, and
|
||||
RFC8259 requires JSON to be encoded as UTF-8.
|
||||
|
||||
Internal interface guidelines
|
||||
-----------------------------
|
||||
|
||||
|
||||
Reference in New Issue
Block a user