InterNetNews / inn

INN (InterNetNews) Usenet server
https://www.isc.org/othersoftware/#INN
Other
68 stars 12 forks source link

Switch default code in samples from Python 2 to Python 3 syntax #260

Closed Julien-Elie closed 10 months ago

Julien-Elie commented 1 year ago

Samples of filtering and authentication Python hooks currently have Python 3.x syntax commented, and Python 2.x syntax active by default. Now is time to do the opposite, and activate Python 3.x syntax by default.

Julien-Elie commented 10 months ago

It was already done in commit f99cc6a. Default sample code works with both Python 2 and Python 3. Differences between the two versions were in comments.

Let's just improve the commented code to properly write a string to log instead of a byte string prefixed with b'.