googlefonts / ufo2ft

A bridge from UFOs to FontTools objects (and therefore, OTFs and TTFs).
MIT License
152 stars 43 forks source link

Rename dottedCircleFilter module #716

Closed madig closed 1 year ago

madig commented 1 year ago

https://github.com/googlefonts/ufo2ft/pull/715 was wrong actually and broke main. I decided to rename the filter module instead and put in a redirection stub.

Closes https://github.com/googlefonts/ufo2ft/issues/707.

khaledhosny commented 1 year ago

I suggest renaming then adding the old name in two different commits so that git can still track file history.

anthrotype commented 1 year ago

please do what khaled said, otherwise LGTM (merge when done thanks)

madig commented 1 year ago

Ok, will do.

Hm, user warnings aren't displayed to users by default. I'll subclass and log a regular warning.

anthrotype commented 1 year ago

you mean, DeprecationWarnings aren't displayed to users by default.. the default UserWarnings should be

madig commented 1 year ago

Uh, well, do you want me to use UserWarnings instead?

anthrotype commented 1 year ago

you want me to use UserWarnings instead?

instead of DeprecationWarning, yes. What else do you suggest instead?

madig commented 1 year ago

Eh, either way is fine, a logging.warning just looks neater. Updated to use a UserWarning.

anthrotype commented 1 year ago

either way is fine, a logging.warning just looks neater.

it depends who the message is directed to. If it's the non-developer user of a tool that uses ufo2ft, then logging should be used; if it's a developer that imports ufo2ft from their own code, you should use warnings module

madig commented 1 year ago

Ok. Warn on import is harder to test because we import once but test twice with FontClass, so once it succeeds but then no more 🫤

anthrotype commented 1 year ago

Do whatever is easiest and don't stress too much if testing it is tricky