hasgeek / baseframe

Baseframe for Hasgeek projects
BSD 3-Clause "New" or "Revised" License
12 stars 17 forks source link

Fix gettext return type, re-extract Babel strings #456

Closed jace closed 6 months ago

jace commented 6 months ago

lazy_gettext (aliased as __) returns LazyString, which is not compatible with str and causes downstream type errors. Since it's meant to ducktype a string and works in almost all situations (notable exception: json.dumps), we re-cast __ to claim it returns str.

Baseframe was also incorrectly exporting _ and __ bound to the Baseframe translation domain.