Closed avylove closed 2 years ago
This looks good. I'm not sure the f-strings are more readable, but :shrug:. I'll take them. :-)
Needs a rebase.
Rebased. Main reason to use f-strings is they are more efficient. str.format() and concatenation are the slowest ways to do interpolation. Also switching to lazy %-strings for logging avoids interpolation unless the message is actually logged. Not that I think these make a huge difference the way this code is used, but I figured it doesn't hurt to catch them while I was already poking around.
Just a little code cleanup, mostly around using f-strings over concatenation and using lazy evaluation for logging. Outside of string interpolation, there was an unused import, a couple unneeded return statements, and redefinition of a built-in (filter).