Goal
Today I will tidy up various small things.
Plan
Add
clippylints to prevent many causes of panic.Change chunk labels to be URL friendly in the same way identifiers are.
Notes
Enabled
clippylints:clippy::panicclippy::panicking_unwrapclippy::unwrap_in_resultclippy::unwrap_used
This required fixing many places, but all straightforward. Most annoying part of this is that the lints are meant to apply to production code, but they also apply to test code. No matter.
Merged these changes.
For URL-safe labels, I'll change things so that labels are always UTF-8 strings, but also so that they may only contain URL-safe characters. Actually, a subset will do: upper and lower case letters (a through z), digits, dot, and dash. This means they do not need to be encoded in URLs, which makes things simpler.
I kept the label creation code very simple, but still, on my laptop:
09:03:47 > cargo run -q --example encode-labels --release -- 1000000 encode label 1000000 times duration 0.727571128 seconds labels/s: 1374436.0675070658That's over a million labels per second. Good enough for now.
Changed all the code to use new label type and dropped the old one.
Merged this change, too.
Summary
Made some simple tidying up. That was all I was able to do today, having slept badly.
Support?
If you'd like to fund Obnam development, see my funding page. My high level goal is described on the architecture page. What is most important about backup software to you?