My developer setup does not use .po files in OJS 3.4 (as it did in 3.3)

I had a working development setup (for the half-complete Review Quality Collector generic plugin) off the stable-3_3_0 branch last year.

Now I picked up on that development and transferred it to the tip of the stable-3_4_0 branch (basically 3.4.0-1), using the same config.inc.php (which states locale = en_US) and DB contents.

I followed https://docs.pkp.sfu.ca/dev/documentation/en/getting-started and did the submodules, composer and npm updates.
I ran php tools/upgrade.php upgrade.

I had to insert the required column into the genres table manually, but then my setup basically worked – except that it does not show any of the OJS or PKP text strings and rather displays only L10N keys instead: ##navigation.settings##, ##context.context##, ##manager.website##, and so on.

The locale/en and pkp/lib/locale/en folders exist as expected.

Any hint why such a thing might happen?

There is an interesting exception to the above: The L10N strings for the name and description of my plugin show up correctly in the plugins list (management/settings/website#plugins), which is not the case for any of the other many plugins listed. My plugin has a plugins/generic/reviewqualitycollector/locale/en_US directory (note the _US suffix).

I know I could use the debugger, but I am not a PHP developer and the last time I had to use the debugger it took two days until I had it working (I have a local setup with PhpStorm and use php -S, but still…), so I’d rather not.

Hi @prechelt,

We changed from en_US in 3.3.0-x to en in 3.4.0-x, and similarly renamed most of the other locales. You’ll probably need to take a few steps…

  • Set locale to en in config.inc.php
  • Run the upgrade process to take care of your database. (Alternately, if it’s not too much work, start with a fresh install or use the PKP development dataset.)

Regards,
Alec Smecher
Public Knowledge Project Team

For the record (@asmecher):

  • Alec, you are doing a terrific job!
  • Changing the locale to en was definitely needed.
  • It did, however, not help: My setup kept showing L10N keys only all day, no matter how often I deleted all imaginable caches or tried other things such as locale = de. I’ve run out of ideas.
  • I recognized that attempting to make my half-complete plugin run on OJS 3.4 (instead of getting it back up on 3.3 after a year of non-development that started in the middle of involved changes) is the wrong idea. I will set up a brand-new 3.3-based development today.
1 Like

This topic was automatically closed after 13 days. New replies are no longer allowed.