-
Notifications
You must be signed in to change notification settings - Fork 150
Description
Problem Description
This issue was discovered while I was preparing to publish the flatpak-docs-l10n project. Related to: localizethedocs/flatpak-docs-l10n#3
Currently, there are 3 places in the Flatpak documentation that use the .. raw:: html directive to read and insert content from pre-prepared .html files:
flatpak-command-reference.rst:flatpak-docs/docs/flatpak-command-reference.rst
Lines 6 to 7 in 004cb8d
.. raw:: html :file: flatpak-docs.html flatpak-builder-command-reference.rst:flatpak-docs/docs/flatpak-builder-command-reference.rst
Lines 6 to 7 in 004cb8d
.. raw:: html :file: flatpak-builder-docs.html libflatpak-api-reference.rst:flatpak-docs/docs/libflatpak-api-reference.rst
Lines 6 to 7 in 004cb8d
.. raw:: html :file: libflatpak-docs.html
Therefore, my current solution is to remove the raw target from the gettext_additional_targets configuration value to prevent this error during .pot file upload. The trade-off, however, is that the content currently authored using the .. raw:: html directive will not be translatable.
❌ File 'master/locale/pot/LC_MESSAGES/libflatpak-api-reference.pot'
❌ Wrong parameters:
<key: storageId, code: fileInvalid, message: File not imported: libflatpak-api-reference.pot contains one or more strings that exceed the 65535-byte limit.>
This error is because the Crowdin platform currently imposes a 65535-byte length limit per string for stability and performance considerations, but Crowdin does not plan to lift this restriction in the short term.
Therefore, my current solution is to remove the raw target from the gettext_additional_targets configuration value to prevent this error during .pot file upload. The trade-off, however, is that the content currently authored using the .. raw:: html directive will not be translatable.
Suggestion
If possible, I would suggest that Flatpak Docs refactor the 3 places that use the .. raw:: html directive and try to restructure the content of those .html files to follow the normal ReST format.
If the decision is truly to continue using the .. raw:: html directive to include content, please try to avoid stuffing a massive amount of content all into the same single .. raw:: html block.