Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 5.3, 5.4
    • Fix Version/s: 5.4, 5.3.8
    • Component/s: tapestry-core
    • Labels:
      None

      Description

      Pls check detail here:
      http://tapestry.1045711.n5.nabble.com/A-strange-error-with-MaxLength-Validator-td5546700.html

      The message in version 5.2 is correct.

        Issue Links

          Activity

          Hide
          uklance Lance added a comment -

          Just to save sifting through nabble, the fix is to change a line in ValidationMessages_zh_CN.properties from:
          maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %s \u63d0\u4f9b\u81f3\u5c11 %d \u5b57\u7b26\u3002
          to
          maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002

          Show
          uklance Lance added a comment - Just to save sifting through nabble, the fix is to change a line in ValidationMessages_zh_CN.properties from: maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %s \u63d0\u4f9b\u81f3\u5c11 %d \u5b57\u7b26\u3002 to maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002
          Hide
          ruralhunter Rural Hunter added a comment -

          The minimum-string-length is also incorrect according to another post. So we should have these:

          minimum-string-length=\u60a8\u5fc5\u987b\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002
          maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002

          Show
          ruralhunter Rural Hunter added a comment - The minimum-string-length is also incorrect according to another post. So we should have these: minimum-string-length=\u60a8\u5fc5\u987b\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002 maximum-string-length=\u60a8\u6700\u591a\u80fd\u4e3a %2$s \u63d0\u4f9b\u81f3\u5c11 %1$d \u5b57\u7b26\u3002
          Hide
          uklance Lance added a comment -

          To catch this case in the future, a test case could be developed to parse all language file entries into a MessageFormat. Then, the result of MessageFormat.getFormatsByArgumentIndex() could be compared to ensure that the format type (date/string/number) and the number of arguments is consistent across languages.

          Show
          uklance Lance added a comment - To catch this case in the future, a test case could be developed to parse all language file entries into a MessageFormat. Then, the result of MessageFormat.getFormatsByArgumentIndex() could be compared to ensure that the format type (date/string/number) and the number of arguments is consistent across languages.
          Hide
          jira-bot ASF subversion and git services added a comment -

          Commit 5a8ac6883fd0d34186c8d849509bdb105e84ea73 in tapestry-5's branch refs/heads/master from Jochen Kemnade
          [ https://git-wip-us.apache.org/repos/asf?p=tapestry-5.git;h=5a8ac68 ]

          TAP5-2355, TAP5-1865: fix format argument order in zh_CN validation messages

          Show
          jira-bot ASF subversion and git services added a comment - Commit 5a8ac6883fd0d34186c8d849509bdb105e84ea73 in tapestry-5's branch refs/heads/master from Jochen Kemnade [ https://git-wip-us.apache.org/repos/asf?p=tapestry-5.git;h=5a8ac68 ] TAP5-2355 , TAP5-1865 : fix format argument order in zh_CN validation messages
          Hide
          hudson Hudson added a comment -

          FAILURE: Integrated in tapestry-trunk-freestyle #1252 (See https://builds.apache.org/job/tapestry-trunk-freestyle/1252/)
          TAP5-2355, TAP5-1865: fix format argument order in zh_CN validation messages (jochen.kemnade: rev 5a8ac6883fd0d34186c8d849509bdb105e84ea73)

          • tapestry-core/src/main/resources/org/apache/tapestry5/core_zh_CN.properties
          Show
          hudson Hudson added a comment - FAILURE: Integrated in tapestry-trunk-freestyle #1252 (See https://builds.apache.org/job/tapestry-trunk-freestyle/1252/ ) TAP5-2355 , TAP5-1865 : fix format argument order in zh_CN validation messages (jochen.kemnade: rev 5a8ac6883fd0d34186c8d849509bdb105e84ea73) tapestry-core/src/main/resources/org/apache/tapestry5/core_zh_CN.properties

            People

            • Assignee:
              jkemnade Jochen Kemnade
              Reporter:
              ruralhunter Rural Hunter
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development