This is an archive of the discontinued Mercurial Phabricator instance.

i18n: get datapath directly from resourceutil
ClosedPublic

Authored by martinvonz on Nov 15 2019, 2:12 PM.

Details

Summary

The new resourceutil module is lower in the dependency graph, so we
can depend directly on it and won't have to depend on the util module
to inject the datapath.

Diff Detail

Repository
rHG Mercurial
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.

Event Timeline

martinvonz created this revision.Nov 15 2019, 2:12 PM
indygreg accepted this revision.Nov 16 2019, 2:08 PM
indygreg added a subscriber: indygreg.
indygreg added inline comments.
mercurial/i18n.py
57

I'm not thrilled about the use of global variables here: I feel like the locale directory and related functionality should be associated with a ui instance or something. But this was an existing can of worms and you didn't make anything worse. So this is fine for now.

This revision is now accepted and ready to land.Nov 16 2019, 2:08 PM
This revision was automatically updated to reflect the committed changes.