This is using the format language for f-strings. The first bit inside the braces is the thing you want to evaluate (and print the str() representation of), and the second bit (after the colon) is the Format specification mini-language.
In your particular case the less-than sign indicates left alignment within the field and HEADERSIZE is evaluated and interpreted as the size of the field.
In your particular case the less-than sign indicates left alignment within the field and HEADERSIZE is evaluated and interpreted as the size of the field.
>>> headersize = 10 >>> n = 45 >>> f"{n}" '45' >>> f"{n:{headersize}}" ' 45' >>> f"{n:<{headersize}}" '45 '