Skip to content

date_to_rfc822 uses localized day and month names #973

Closed

Description

@josefguenther
new Liquid({ locale: 'de-DE', timezoneOffset: 0 })
  .parseAndRenderSync('{{ "2023-11-14T22:13:20Z" | date_to_rfc822 }}')

This renders Di, 14 Nov 2023 22:13:20 +0000. It should render Tue, 14 Nov 2023 22:13:20 +0000: RFC 822 (and RFC 2822 §3.3) day and month names are fixed English tokens, and an RSS <pubDate> built from this filter doesn't parse in feed readers. Jekyll 4.4.1 renders the English names whatever the host locale.

locale actual expected
en-US Tue, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
de-DE Di, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
fr-FR mar., 14 nov. 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
ar-EG الثلاثاء, 14 نوفمبر 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
none, on a de-DE host Di, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000

date_to_rfc822 formats with %a, %d %b %Y %H:%M:%S %z, and since #723 (#567) %a and %b follow the locale option, which defaults to the host's locale. The date docs already say Jekyll specific date filters are English-only. For the same reason, the existing date_to_rfc822 tests in test/integration/filters/date.spec.ts fail when run on a machine with a German locale.

date_to_string and date_to_long_string localize their month names too. Those are human-readable, so that may be wanted; this is only about date_to_rfc822.

Tested on master 920166e (10.30.0), Node 24.11.1, node and browser builds.

Activity

  1. javi0guerrero4-cloud commented on Oct 26, 2026

    @javi0guerrero4-cloud

    new Liquid({ locale: 'de-DE', timezoneOffset: 0 })
    .parseAndRenderSync('{{ "2023-11-14T22:13:20Z" | date_to_rfc822 }}')
    This renders Di, 14 Nov 2023 22:13:20 +0000. It should render Tue, 14 Nov 2023 22:13:20 +0000: RFC 822 (and RFC 2822 §3.3) day and month names are fixed English tokens, and an RSS <pubDate> built from this filter doesn't parse in feed readers. Jekyll 4.4.1 renders the English names whatever the host locale.

    locale actual expected
    en-US Tue, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
    de-DE Di, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
    fr-FR mar., 14 nov. 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
    ar-EG الثلاثاء, 14 نوفمبر 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
    none, on a de-DE host Di, 14 Nov 2023 22:13:20 +0000 Tue, 14 Nov 2023 22:13:20 +0000
    date_to_rfc822 formats with %a, %d %b %Y %H:%M:%S %z, and since #723 (#567) %a and %b follow the locale option, which defaults to the host's locale. The date docs already say Jekyll specific date filters are English-only. For the same reason, the existing date_to_rfc822 tests in test/integration/filters/date.spec.ts fail when run on a machine with a German locale.

    date_to_string and date_to_long_string localize their month names too. Those are human-readable, so that may be wanted; this is only about date_to_rfc822.

    Tested on master 920166e (10.30.0), Node 24.11.1, node and browser builds.

  2. added a commit that references this issue on Oct 28, 2026
    e94a1c4
  3. github-actions commented on Oct 28, 2026

    @github-actions

    🎉 This issue has been resolved in version 10.30.1 🎉

    The release is available on:

    Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions