2 Replies Latest reply on Apr 19, 2016 2:26 PM by Christian Bauer

    [4.0.0-SNAPSHOT] I18N conflict with logging?

    Christian Bauer Master

      Trying this demo code: https://github.com/errai/errai/tree/e1f27acd0fc18772ea486e9f8bcfeff2d8267f1b/errai-demos/errai-ui-demo-i18n

       

      I've copied the code and used my own gwt.xml:

       

      <module rename-to="MyApp">

       

        <inherits name="org.jboss.errai.ui.UI" />

        <inherits name="org.jboss.errai.enterprise.CDI" />

        <inherits name="org.jboss.errai.ui.nav.Navigation" />

       

        <set-property name="gwt.logging.logLevel" value="FINEST"/>

       

        <!-- TODO This breaks Errai i18n?!
        <set-property name="gwt.logging.enabled" value="TRUE"/>
        -->
       
      </module>

       

      With GWT logging enabled, Errai did not generate any bundles/translations and there was no error messages. I find it hard to believe that this is the cause, but I was only able to narrow the problem down to this element in gwt.xml.

       

      This is another test that fails the same way:

       

      <!DOCTYPE html>

      <html lang="en">

      <head>

        <meta charset="UTF-8">

        <title>Baz</title>

      </head>

      <body>

       

      <div id="baz">

        <span data-i18n-key="foo">foo</span>

      </div>

       

      </body>

      </html>


      @Bundle("bundle.json")

      @Templated("#baz")

      @Page(path = "baz", role = DefaultPage.class)

      public class Baz {

      }

       

      {

        "Baz.foo": "FOOOOOOOOO"
      }

       

      If gwt.logging.enabled is FALSE, this works.