A working subset of #1788 #1875
No reviewers
Labels
No Label
bug
build
dependencies
developers
documentation
duplicate
enhancement
formatting
invalid
legal
mobile
obsolete
packaging
performance
protocol
question
refactoring
regression
security
test
translation
usability
wontfix
No Milestone
No project
No Assignees
1 Participants
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: Bitmessage/PyBitmessage-2024-12-10#1875
Loading…
Reference in New Issue
Block a user
No description provided.
Delete Branch "compat-short"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Hello!
This is a subset of #1788, the tests that are ready (+4 tests, including those for base58 and varint) and corresponding changes in the
protocol
module.There is also a test for base58 in #1796: 7f213f6
samples.py
0
, and decode needs to test an invalid characterlength
, notlenght
Mostly ok, just minor cleanup pls.
@PeterSurda what do you think
addresses.encodeBase58()
should do in such case? Raise an exception, return None, or drop the sign?This is the invalid character.
Good catch, I'd go with
return None
.Still
encodeBase58(0)
is missing. Fixing negative can be fixed either in this PR or a separate one.still missing test for
0
:self.assertEqual(addresses.encodeBase58(0), '1')
It failed when I wrote it first time, maybe I misspelled something
It's a simple mechanical fix. I prefer to merge complete tests, not stubs.