The SIO2 project
  1. The SIO2 project
  2. SIO-2278

Navbar translations doesn't work in problemset

    Details

      Description

      It is in Polish even when the selected language is English.

        Activity

        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 1
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        In my local sio copy it appeared English even if language was set to Polish.
        Hopefully my change fixes both problems.
        Modifying navbar registry happens once during the initialization,
        so these texts are saved once in the init, therefor only one translation happens.
        When changing the language, no modification is possible to these strings.
        Added translation in reading these texts from registry,
        making sure they get translated every time they are loaded.
        TODO: remove translation from initializing registry!

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 1 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset In my local sio copy it appeared English even if language was set to Polish. Hopefully my change fixes both problems. Modifying navbar registry happens once during the initialization, so these texts are saved once in the init, therefor only one translation happens. When changing the language, no modification is possible to these strings. Added translation in reading these texts from registry, making sure they get translated every time they are loaded. TODO: remove translation from initializing registry! Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 2
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        In my local sio copy it appeared English even if language was set to Polish.
        Hopefully my change fixes both problems.

        Modifying navbar registry happens once during the initialization,
        so these texts are saved once in the init, therefor only one translation happens.
        When changing the language, no modification is possible to these strings.

        Added translation in reading these texts from registry,
        making sure they get translated every time they are loaded.

        Removed translation from regiter functions,
        so that registered textx is the text to be translated.
        By doing so, I am sure that the text won't get translated before adding,
        because the it would not be ever translated back.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 2 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset In my local sio copy it appeared English even if language was set to Polish. Hopefully my change fixes both problems. Modifying navbar registry happens once during the initialization, so these texts are saved once in the init, therefor only one translation happens. When changing the language, no modification is possible to these strings. Added translation in reading these texts from registry, making sure they get translated every time they are loaded. Removed translation from regiter functions, so that registered textx is the text to be translated. By doing so, I am sure that the text won't get translated before adding, because the it would not be ever translated back. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 3
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        Translation was imported as ugettext, which was a not lazy version of translation.
        Therefor, the translation was made on init, so the text once translated never changed.
        Edited import to ugettext_lazy, so that the translation is lazy.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 3 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset Translation was imported as ugettext, which was a not lazy version of translation. Therefor, the translation was made on init, so the text once translated never changed. Edited import to ugettext_lazy, so that the translation is lazy. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 4
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        Translation was imported as ugettext, which was a not lazy version of translation.
        Therefor, the translation was made on init, so the text once translated never changed.
        Edited import to ugettext_lazy, so that the translation is lazy.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 4 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset Translation was imported as ugettext, which was a not lazy version of translation. Therefor, the translation was made on init, so the text once translated never changed. Edited import to ugettext_lazy, so that the translation is lazy. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 5
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        Translation was imported as ugettext, which was a not lazy version of translation.
        Therefor, the translation was made on init, so the text once translated never changed.
        Edited import to ugettext_lazy, so that the translation is lazy.

        Changed jsonify functions, because they don't accept lazy translation objects.
        Before jsonifying results, translated texts to current language.

        Added a regression test.

        What's interesting, that a bug in problems' view caused an error in szkopul view...
        Not sure why that happened, but it's fixed now.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 5 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset Translation was imported as ugettext, which was a not lazy version of translation. Therefor, the translation was made on init, so the text once translated never changed. Edited import to ugettext_lazy, so that the translation is lazy. Changed jsonify functions, because they don't accept lazy translation objects. Before jsonifying results, translated texts to current language. Added a regression test. What's interesting, that a bug in problems' view caused an error in szkopul view... Not sure why that happened, but it's fixed now. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 6
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        Translation was imported as ugettext, which was a not lazy version of translation.
        Therefor, the translation was made on init, so the text once translated never changed.
        Edited import to ugettext_lazy, so that the translation is lazy.

        Changed jsonify functions, because they don't accept lazy translation objects.
        Before jsonifying results, translated texts to current language.

        Added a regression test.

        What's interesting, that a bug in problems' view caused an error in szkopul view...
        Not sure why that happened, but it's fixed now.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 6 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset Translation was imported as ugettext, which was a not lazy version of translation. Therefor, the translation was made on init, so the text once translated never changed. Edited import to ugettext_lazy, so that the translation is lazy. Changed jsonify functions, because they don't accept lazy translation objects. Before jsonifying results, translated texts to current language. Added a regression test. What's interesting, that a bug in problems' view caused an error in szkopul view... Not sure why that happened, but it's fixed now. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Hide
        Gerrit Gerrit added a comment -
        Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 7
        https://gerrit.sio2project.mimuw.edu.pl/3346

        SIO-2278 Navbar translations doesn't work in problemset

        Translation was imported as ugettext, which was a not lazy version of translation.
        Therefor, the translation was made on init, so the text once translated never changed.
        Edited import to ugettext_lazy, so that the translation is lazy.

        Changed jsonify functions, because they don't accept lazy translation objects.
        Before jsonifying results, translated texts to current language.

        Added a regression test.

        What's interesting, that a bug in problems' view caused an error in szkopul view...
        Probably szkopul loaded navbar view in problemset from normal sio2 view.

        Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64
        Show
        Gerrit Gerrit added a comment - Change oioioi~master~I0661b460c2cdf8fd48c8932dc25e0010e78a1e64, patchset 7 https://gerrit.sio2project.mimuw.edu.pl/3346 SIO-2278 Navbar translations doesn't work in problemset Translation was imported as ugettext, which was a not lazy version of translation. Therefor, the translation was made on init, so the text once translated never changed. Edited import to ugettext_lazy, so that the translation is lazy. Changed jsonify functions, because they don't accept lazy translation objects. Before jsonifying results, translated texts to current language. Added a regression test. What's interesting, that a bug in problems' view caused an error in szkopul view... Probably szkopul loaded navbar view in problemset from normal sio2 view. Change-Id: I0661b460c2cdf8fd48c8932dc25e0010e78a1e64

          People

          • Assignee:
            Szymon Acedański
            Reporter:
            Zuzanna Opała
            TAG Developer:
            Stanisław Strzelecki
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Due:
              Created:
              Updated:
              Resolved: