Repository navigation
Conversation
--anonymous only removed the cryptocurrency addresses and QR codes. Each card still
printed the name passed to the tool ("SLIP39 First(1/1) for: Alice", on the front and
on the back), the requirements of all of the groups ("Recover w/ 2 of 4: First(1),
Second(1), Fam(2/4), Frens(3/6)", which tells whoever holds a single card the names,
thresholds and sizes of the other groups), and a diagonal group label.
With --anonymous, the title of a card is now just its group name, and none of the above
is printed; the mnemonic words remain the large ones. Cards without --anonymous are
unchanged.
The `anonymous` argument defaults to ANONYMOUS (False) instead of None, which removes
the repeated `ANONYMOUS if anonymous is None else anonymous`.
Add tests of the texts rendered on the cards, with and without --anonymous.
See pjkundert#11.
Print the title of a card as "SLIP39 Fam 2 for Alice", instead of "SLIP39 Fam(2/4) for: Alice": the number of the card within its group, only if the group has several cards, and the name only if there is one. This avoids printing the size of the group (and a trailing "for: " with no name), and repeats less of what the "Recover w/ ..." line and the mnemonics already show. Only changes the title of cards that are not anonymous.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Follow-up to #11 (see my comment there).
--anonymousonly removes the cryptocurrency addresses and QR codes. Each card still prints the name passed to the tool (SLIP39 First(1/1) for: Alice, on the front and the back), the requirements of all the groups (Recover w/ 2 of 4: First(1), Second(1), Fam(2/4), Frens(3/6), which tells whoever holds a single card the names, thresholds and sizes of the other groups), and a diagonal group name and card number across the card.The first commit makes an anonymous card show only its group name (centered at the top, as before) and the mnemonic words, which stay the large ones. Cards without
--anonymousare unchanged. Anonymous cards deliberately show no card number: the words identify each card. It also makesanonymousdefault toANONYMOUSinstead ofNone, which removes the repeatedANONYMOUS if anonymous is None else anonymous.The second commit is independent and easy to drop: it simplifies the title of the cards that are not anonymous, from
SLIP39 Fam(2/4) for: AlicetoSLIP39 Fam 2 for Alice(the card number only if the group has several cards, and the name only if there is one), so that the size of the group isn't printed twice and there's no danglingfor:.slip39/output_test.py):test_cardsandtest_anonymous_cardsrecord the texts rendered on every card, front and back, with and without--anonymous. The anonymous test fails on currentmasterand passes with this change.pytest(without the invoice/communications tests, which need optional packages): 44 passed, 4 skipped.