Opened 8 weeks ago
Last modified 5 weeks ago
#65314 new task (blessed)
Make `wp-includes/pomo` the canonical pomo source; retire `svn.glotpress.org/trunk/pomo`
| Reported by: | dd32 | Owned by: | |
|---|---|---|---|
| Priority: | normal | Milestone: | Awaiting Review |
| Component: | I18N | Version: | |
| Severity: | normal | Keywords: | has-patch |
| Cc: | Focuses: | docs |
Description
Background
The pomo library (PO/MO file reading and writing, plus the Translations and plural-form helpers) currently exists in two places:
- wp-includes/pomo/ — shipped with WordPress core.
- https://glotpress.svn.wordpress.org/trunk/pomo/ — the original home, dating from when GlotPress was an SVN project that bundled pomo as its own subdirectory.
When that split was set up, GlotPress was the source of truth: changes landed in the GlotPress SVN copy and were synced into core.
That arrangement no longer reflects reality:
- GlotPress is now a WordPress plugin developed on GitHub (https://github.com/GlotPress/GlotPress).
- GlotPress requires WordPress, so at runtime it uses the pomo library shipped in wp-includes/pomo/.
- GlotPress no longer pulls from, depends on, or syncs with the SVN copy of pomo. The SVN copy is effectively orphaned and only continues to matter to the extent that core still mirrors it.
Proposal
Officially recognize wp-includes/pomo/ as the canonical, upstream copy of the library. All future changes (bug fixes, deprecations, PHP compatibility work, etc.) land in core directly via Trac/SVN and are reviewed under the I18N component.
Notes on divergence
The GlotPress SVN copy of pomo contains a samples/ directory with example .po/.mo fixtures used during the library's original development. WordPress core has never shipped that folder and shouldn't start — but those fixtures may still be useful as test data. Options:
- Move the fixtures into core's PHPUnit i18n test fixtures (if not already covered).
- Or, move them into the GlotPress GitHub repo under tests/.
- Or, leave them where they are and treat the SVN location as a frozen fixture archive.
Change History (3)
This ticket was mentioned in PR #11947 on WordPress/wordpress-develop by @khokansardar.
8 weeks ago
#2
- Keywords has-patch added
## Summary
- Documents
wp-includes/pomo/as the canonical upstream copy of the pomo library intranslations.php. - Removes legacy SVN
@version $Id:headers from pomo library files, remnants of the former GlotPress SVN sync workflow. - Adds consistent
@package pomoand@sincetags across all pomo library files.
This implements the proposal in #65314 to retire the dual-source arrangement where glotpress.svn.wordpress.org/trunk/pomo/ was treated as upstream. Core is now the sole maintained copy; GlotPress consumes it at runtime.
The GlotPress SVN sample/ fixtures are left as a frozen archive per the ticket — core already has comprehensive pomo test fixtures in tests/phpunit/data/pomo/.
## Test plan
- [x]
composer lint -- src/wp-includes/pomo/— 0 errors - [x]
npm run test:php -- --group pomo— 48 tests passed - [ ] Confirm with @ocean90 and @amieiro (cc'd on the ticket by @dd32)
![(please configure the [header_logo] section in trac.ini)](/chrome/site/your_project_logo.png)
cc @ocean90 @amieiro