From 45f8ac92d1b4c3c511c67ffd77affbf4f43fa7ed Mon Sep 17 00:00:00 2001 From: hda Date: Wed, 12 Feb 2025 12:03:36 +0100 Subject: [PATCH 1/6] [MIG] statechart from 16.0 --- statechart/README.rst | 6 +-- statechart/__manifest__.py | 2 +- statechart/models/__init__.py | 1 + statechart/models/base.py | 22 ++++++++++ statechart/models/interpreter.py | 4 +- statechart/static/description/index.html | 13 +++--- statechart_demo/README.rst | 8 ++-- statechart_demo/__manifest__.py | 2 +- statechart_demo/static/description/index.html | 15 +++---- statechart_demo/views/res_partner_views.xml | 13 ++---- test_statechart/README.rst | 6 +-- test_statechart/__manifest__.py | 3 +- test_statechart/security/ir.model.access.csv | 2 + .../security/purchase_order_delegated.xml | 2 - .../security/thing_with_mailthread.xml | 2 - test_statechart/static/description/index.html | 13 +++--- test_statechart/tests/test_basic.py | 4 +- test_statechart/tests/test_inherit.py | 5 +-- test_statechart/tests/test_po_statechart.py | 9 ++--- test_statechart/views/purchase_order.xml | 40 ++++++------------- 20 files changed, 86 insertions(+), 86 deletions(-) create mode 100644 statechart/models/base.py create mode 100644 test_statechart/security/ir.model.access.csv diff --git a/statechart/README.rst b/statechart/README.rst index f92e320..df965d2 100644 --- a/statechart/README.rst +++ b/statechart/README.rst @@ -17,7 +17,7 @@ Statechart :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html :alt: License: LGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-acsone%2Fscobidoo-lightgray.png?logo=github - :target: https://github.com/acsone/scobidoo/tree/16.0/statechart + :target: https://github.com/acsone/scobidoo/tree/18.0/statechart :alt: acsone/scobidoo |badge1| |badge2| |badge3| @@ -47,7 +47,7 @@ Bug Tracker Bugs are tracked on `GitHub Issues `_. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed -`feedback `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -62,6 +62,6 @@ Authors Maintainers ----------- -This module is part of the `acsone/scobidoo `_ project on GitHub. +This module is part of the `acsone/scobidoo `_ project on GitHub. You are welcome to contribute. diff --git a/statechart/__manifest__.py b/statechart/__manifest__.py index fb923c7..164f867 100644 --- a/statechart/__manifest__.py +++ b/statechart/__manifest__.py @@ -5,7 +5,7 @@ "name": "Statechart", "summary": """ Add Statecharts to Odoo models""", - "version": "16.0.1.0.0", + "version": "18.0.1.0.0", "license": "LGPL-3", "author": "ACSONE SA/NV,Odoo Community Association (OCA)", "website": "https://github.com/acsone/scobidoo", diff --git a/statechart/models/__init__.py b/statechart/models/__init__.py index f9ea52a..40251cf 100644 --- a/statechart/models/__init__.py +++ b/statechart/models/__init__.py @@ -1,2 +1,3 @@ from . import statechart from . import statechart_mixin +from . import base diff --git a/statechart/models/base.py b/statechart/models/base.py new file mode 100644 index 0000000..bbe546b --- /dev/null +++ b/statechart/models/base.py @@ -0,0 +1,22 @@ +# Copyright 2025 ACSONE SA/NV +# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). + +from odoo import api, models + + +class Base(models.AbstractModel): + """The base model, which is implicitly inherited by all models. + + Restore the _patch_method removed in Odoo 18 + """ + + _inherit = "base" + + @classmethod + def _patch_method(cls, name, method): + origin = getattr(cls, name) + method.origin = origin + # propagate decorators from origin to method, and apply api decorator + wrapped = api.propagate(origin, method) + wrapped.origin = origin + setattr(cls, name, wrapped) diff --git a/statechart/models/interpreter.py b/statechart/models/interpreter.py index e76e10c..d4cc9ae 100644 --- a/statechart/models/interpreter.py +++ b/statechart/models/interpreter.py @@ -7,11 +7,11 @@ from sismic.interpreter import Interpreter as SismicInterpreter from sismic.model import Event -from odoo.exceptions import except_orm +from odoo.exceptions import UserError def _root_cause(e): - if isinstance(e, except_orm): + if isinstance(e, UserError): return e if not hasattr(e, "__cause__") or not e.__cause__: return e diff --git a/statechart/static/description/index.html b/statechart/static/description/index.html index d8c952f..aed6ead 100644 --- a/statechart/static/description/index.html +++ b/statechart/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { @@ -368,7 +369,7 @@

Statechart

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! source digest: sha256:63949f6cfdabc7f7e60a2b3d75f934f75c6024666a807e4e916a56bd23a09ec9 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: LGPL-3 acsone/scobidoo

+

Beta License: LGPL-3 acsone/scobidoo

Add statecharts to Odoo models.

Table of contents

@@ -397,7 +398,7 @@

Bug Tracker

Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed -feedback.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -410,7 +411,7 @@

Authors

Maintainers

-

This module is part of the acsone/scobidoo project on GitHub.

+

This module is part of the acsone/scobidoo project on GitHub.

You are welcome to contribute.

diff --git a/statechart_demo/README.rst b/statechart_demo/README.rst index 44ee5a6..dc96caa 100644 --- a/statechart_demo/README.rst +++ b/statechart_demo/README.rst @@ -17,7 +17,7 @@ Statechart Demo :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html :alt: License: LGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-acsone%2Fscobidoo-lightgray.png?logo=github - :target: https://github.com/acsone/scobidoo/tree/16.0/statechart_demo + :target: https://github.com/acsone/scobidoo/tree/18.0/statechart_demo :alt: acsone/scobidoo |badge1| |badge2| |badge3| @@ -28,7 +28,7 @@ Demonstration of parallel states on the ``res.partner`` model. |Parallel states| -.. |Parallel states| image:: https://raw.githubusercontent.com/acsone/scobidoo/16.0/statechart_demo/models/res_partner_statechart.png +.. |Parallel states| image:: https://raw.githubusercontent.com/acsone/scobidoo/18.0/statechart_demo/models/res_partner_statechart.png **Table of contents** @@ -41,7 +41,7 @@ Bug Tracker Bugs are tracked on `GitHub Issues `_. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed -`feedback `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -56,6 +56,6 @@ Authors Maintainers ----------- -This module is part of the `acsone/scobidoo `_ project on GitHub. +This module is part of the `acsone/scobidoo `_ project on GitHub. You are welcome to contribute. diff --git a/statechart_demo/__manifest__.py b/statechart_demo/__manifest__.py index 3a7e57d..7c11288 100644 --- a/statechart_demo/__manifest__.py +++ b/statechart_demo/__manifest__.py @@ -4,7 +4,7 @@ { "name": "Statechart Demo", "summary": """Demo workflows for the statechart module""", - "version": "16.0.1.0.0", + "version": "18.0.1.0.0", "license": "LGPL-3", "author": "ACSONE SA/NV,Odoo Community Association (OCA)", "website": "https://github.com/acsone/scobidoo", diff --git a/statechart_demo/static/description/index.html b/statechart_demo/static/description/index.html index f680494..cbf6782 100644 --- a/statechart_demo/static/description/index.html +++ b/statechart_demo/static/description/index.html @@ -8,10 +8,11 @@ /* :Author: David Goodger (goodger@python.org) -:Id: $Id: html4css1.css 8954 2022-01-20 10:10:25Z milde $ +:Id: $Id: html4css1.css 9511 2024-01-13 09:50:07Z milde $ :Copyright: This stylesheet has been placed in the public domain. Default cascading style sheet for the HTML output of Docutils. +Despite the name, some widely supported CSS2 features are used. See https://docutils.sourceforge.io/docs/howto/html-stylesheets.html for how to customize this style sheet. @@ -274,7 +275,7 @@ margin-left: 2em ; margin-right: 2em } -pre.code .ln { color: grey; } /* line numbers */ +pre.code .ln { color: gray; } /* line numbers */ pre.code, code { background-color: #eeeeee } pre.code .comment, code .comment { color: #5C6576 } pre.code .keyword, code .keyword { color: #3B0D06; font-weight: bold } @@ -300,7 +301,7 @@ span.pre { white-space: pre } -span.problematic { +span.problematic, pre.problematic { color: red } span.section-subtitle { @@ -368,10 +369,10 @@

Statechart Demo

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! source digest: sha256:2c5bc3858802d5813ebc802651968e3257c8bfc4c9c6cf47d757020eccef1d28 !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: LGPL-3 acsone/scobidoo

+

Beta License: LGPL-3 acsone/scobidoo

Demo workflows for the statechart module.

Demonstration of parallel states on the res.partner model.

-

Parallel states

+

Parallel states

Table of contents

    @@ -388,7 +389,7 @@

    Bug Tracker

    Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed -feedback.

    +feedback.

    Do not contact contributors directly about support or help with technical issues.

@@ -401,7 +402,7 @@

Authors

Maintainers

-

This module is part of the acsone/scobidoo project on GitHub.

+

This module is part of the acsone/scobidoo project on GitHub.

You are welcome to contribute.

diff --git a/statechart_demo/views/res_partner_views.xml b/statechart_demo/views/res_partner_views.xml index 4963cc4..23b8f4d 100644 --- a/statechart_demo/views/res_partner_views.xml +++ b/statechart_demo/views/res_partner_views.xml @@ -11,33 +11,26 @@ name="track_1_validate" type="object" string="Validate (track 1)" - attrs="{'invisible': [('sc_track_1_validate_allowed', '=', False)]}" + invisible="not sc_track_1_validate_allowed" class="btn-primary" /> - - - + + + - From e19a4799bb05e6d7fffe65879385e36300b764b5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Wed, 13 Aug 2025 10:15:20 +0200 Subject: [PATCH 2/6] Don't add _patch_method in base model We don't need it to be available locally. --- statechart/models/__init__.py | 1 - statechart/models/base.py | 22 ---------------------- statechart/models/statechart_mixin.py | 12 +++++++++++- 3 files changed, 11 insertions(+), 24 deletions(-) delete mode 100644 statechart/models/base.py diff --git a/statechart/models/__init__.py b/statechart/models/__init__.py index 40251cf..f9ea52a 100644 --- a/statechart/models/__init__.py +++ b/statechart/models/__init__.py @@ -1,3 +1,2 @@ from . import statechart from . import statechart_mixin -from . import base diff --git a/statechart/models/base.py b/statechart/models/base.py deleted file mode 100644 index bbe546b..0000000 --- a/statechart/models/base.py +++ /dev/null @@ -1,22 +0,0 @@ -# Copyright 2025 ACSONE SA/NV -# License LGPL-3.0 or later (http://www.gnu.org/licenses/lgpl). - -from odoo import api, models - - -class Base(models.AbstractModel): - """The base model, which is implicitly inherited by all models. - - Restore the _patch_method removed in Odoo 18 - """ - - _inherit = "base" - - @classmethod - def _patch_method(cls, name, method): - origin = getattr(cls, name) - method.origin = origin - # propagate decorators from origin to method, and apply api decorator - wrapped = api.propagate(origin, method) - wrapped.origin = origin - setattr(cls, name, wrapped) diff --git a/statechart/models/statechart_mixin.py b/statechart/models/statechart_mixin.py index 610166c..0a3487e 100644 --- a/statechart/models/statechart_mixin.py +++ b/statechart/models/statechart_mixin.py @@ -15,6 +15,16 @@ _logger = logging.getLogger(__name__) +def _patch_method(cls, name, method): + """This method was part of the Model class in Odoo 16 and earlier.""" + origin = getattr(cls, name) + method.origin = origin + # propagate decorators from origin to method, and apply api decorator + wrapped = api.propagate(origin, method) + wrapped.origin = origin + setattr(cls, name, wrapped) + + def _sc_make_event_allowed_field_name(event_name): # TODO event names must be valid python identifiers # (that must be tested somewhere long before reaching this point) @@ -217,7 +227,7 @@ def partial(self, *args, **kwargs): event_name, cls, ) - cls._patch_method(event_name, partial) + _patch_method(cls, event_name, partial) else: raise UserError( _( From dcb6334ec15737d5e958de8a13fa503cbba952f2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Wed, 13 Aug 2025 10:20:03 +0200 Subject: [PATCH 3/6] Remove setup.py files in favor of pyproject.toml Co-Authored-By: thomas.binsfeld@acsone.eu --- setup/.setuptools-odoo-make-default-ignore | 2 -- setup/README | 2 -- setup/_metapackage/VERSION.txt | 1 - setup/_metapackage/setup.py | 20 ------------------- setup/statechart/odoo/addons/statechart | 1 - setup/statechart/setup.py | 6 ------ .../odoo/addons/statechart_demo | 1 - setup/statechart_demo/setup.py | 6 ------ .../odoo/addons/test_statechart | 1 - setup/test_statechart/setup.py | 6 ------ 10 files changed, 46 deletions(-) delete mode 100644 setup/.setuptools-odoo-make-default-ignore delete mode 100644 setup/README delete mode 100644 setup/_metapackage/VERSION.txt delete mode 100644 setup/_metapackage/setup.py delete mode 120000 setup/statechart/odoo/addons/statechart delete mode 100644 setup/statechart/setup.py delete mode 120000 setup/statechart_demo/odoo/addons/statechart_demo delete mode 100644 setup/statechart_demo/setup.py delete mode 120000 setup/test_statechart/odoo/addons/test_statechart delete mode 100644 setup/test_statechart/setup.py diff --git a/setup/.setuptools-odoo-make-default-ignore b/setup/.setuptools-odoo-make-default-ignore deleted file mode 100644 index 207e615..0000000 --- a/setup/.setuptools-odoo-make-default-ignore +++ /dev/null @@ -1,2 +0,0 @@ -# addons listed in this file are ignored by -# setuptools-odoo-make-default (one addon per line) diff --git a/setup/README b/setup/README deleted file mode 100644 index a63d633..0000000 --- a/setup/README +++ /dev/null @@ -1,2 +0,0 @@ -To learn more about this directory, please visit -https://pypi.python.org/pypi/setuptools-odoo diff --git a/setup/_metapackage/VERSION.txt b/setup/_metapackage/VERSION.txt deleted file mode 100644 index fac43ba..0000000 --- a/setup/_metapackage/VERSION.txt +++ /dev/null @@ -1 +0,0 @@ -16.0.20231216.0 \ No newline at end of file diff --git a/setup/_metapackage/setup.py b/setup/_metapackage/setup.py deleted file mode 100644 index 3560f9f..0000000 --- a/setup/_metapackage/setup.py +++ /dev/null @@ -1,20 +0,0 @@ -import setuptools - -with open('VERSION.txt', 'r') as f: - version = f.read().strip() - -setuptools.setup( - name="odoo-addons-acsone-scobidoo", - description="Meta package for acsone-scobidoo Odoo addons", - version=version, - install_requires=[ - 'odoo-addon-statechart>=16.0dev,<16.1dev', - 'odoo-addon-statechart_demo>=16.0dev,<16.1dev', - 'odoo-addon-test_statechart>=16.0dev,<16.1dev', - ], - classifiers=[ - 'Programming Language :: Python', - 'Framework :: Odoo', - 'Framework :: Odoo :: 16.0', - ] -) diff --git a/setup/statechart/odoo/addons/statechart b/setup/statechart/odoo/addons/statechart deleted file mode 120000 index bbc8b2d..0000000 --- a/setup/statechart/odoo/addons/statechart +++ /dev/null @@ -1 +0,0 @@ -../../../../statechart \ No newline at end of file diff --git a/setup/statechart/setup.py b/setup/statechart/setup.py deleted file mode 100644 index 28c57bb..0000000 --- a/setup/statechart/setup.py +++ /dev/null @@ -1,6 +0,0 @@ -import setuptools - -setuptools.setup( - setup_requires=['setuptools-odoo'], - odoo_addon=True, -) diff --git a/setup/statechart_demo/odoo/addons/statechart_demo b/setup/statechart_demo/odoo/addons/statechart_demo deleted file mode 120000 index f9853e8..0000000 --- a/setup/statechart_demo/odoo/addons/statechart_demo +++ /dev/null @@ -1 +0,0 @@ -../../../../statechart_demo \ No newline at end of file diff --git a/setup/statechart_demo/setup.py b/setup/statechart_demo/setup.py deleted file mode 100644 index 28c57bb..0000000 --- a/setup/statechart_demo/setup.py +++ /dev/null @@ -1,6 +0,0 @@ -import setuptools - -setuptools.setup( - setup_requires=['setuptools-odoo'], - odoo_addon=True, -) diff --git a/setup/test_statechart/odoo/addons/test_statechart b/setup/test_statechart/odoo/addons/test_statechart deleted file mode 120000 index d100b74..0000000 --- a/setup/test_statechart/odoo/addons/test_statechart +++ /dev/null @@ -1 +0,0 @@ -../../../../test_statechart \ No newline at end of file diff --git a/setup/test_statechart/setup.py b/setup/test_statechart/setup.py deleted file mode 100644 index 28c57bb..0000000 --- a/setup/test_statechart/setup.py +++ /dev/null @@ -1,6 +0,0 @@ -import setuptools - -setuptools.setup( - setup_requires=['setuptools-odoo'], - odoo_addon=True, -) From a1aada17253043972ca89b2c48f8fc3573b11332 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?St=C3=A9phane=20Bidoul?= Date: Wed, 13 Aug 2025 10:36:28 +0200 Subject: [PATCH 4/6] Simplify CodeEvaluationError handling As proposed in PR 48 --- statechart/models/interpreter.py | 14 ++------------ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/statechart/models/interpreter.py b/statechart/models/interpreter.py index d4cc9ae..2084033 100644 --- a/statechart/models/interpreter.py +++ b/statechart/models/interpreter.py @@ -7,16 +7,6 @@ from sismic.interpreter import Interpreter as SismicInterpreter from sismic.model import Event -from odoo.exceptions import UserError - - -def _root_cause(e): - if isinstance(e, UserError): - return e - if not hasattr(e, "__cause__") or not e.__cause__: - return e - return _root_cause(e.__cause__) - class Interpreter(SismicInterpreter): def __init__(self, *args, **kwargs): @@ -31,7 +21,7 @@ def execute(self, max_steps=-1): try: return super().execute(max_steps) except CodeEvaluationError as e: - raise _root_cause(e).with_traceback(sys.exc_info()[2]) from e + raise (e.__cause__ or e).with_traceback(sys.exc_info()[2]) from e def execute_once(self): if self._in_execute_once: @@ -41,7 +31,7 @@ def execute_once(self): try: return super().execute_once() except CodeEvaluationError as e: - raise _root_cause(e).with_traceback(sys.exc_info()[2]) from e + raise (e.__cause__ or e).with_traceback(sys.exc_info()[2]) from e finally: self._in_execute_once = False From 47d277c318aca803004f13581b5d950795660110 Mon Sep 17 00:00:00 2001 From: Benjamin Willig Date: Wed, 21 Feb 2024 13:28:53 +0100 Subject: [PATCH 5/6] [CHG] display error pop up instead of stacktrace when raising a TransitionError --- statechart/__manifest__.py | 5 +++++ .../static/src/core/errors/error_dialogs.esm.js | 13 +++++++++++++ 2 files changed, 18 insertions(+) create mode 100644 statechart/static/src/core/errors/error_dialogs.esm.js diff --git a/statechart/__manifest__.py b/statechart/__manifest__.py index 164f867..282b775 100644 --- a/statechart/__manifest__.py +++ b/statechart/__manifest__.py @@ -19,5 +19,10 @@ }, "data": [], "demo": [], + "assets": { + "web.assets_backend": [ + "statechart/static/src/core/errors/error_dialogs.esm.js", + ], + }, "installable": True, } diff --git a/statechart/static/src/core/errors/error_dialogs.esm.js b/statechart/static/src/core/errors/error_dialogs.esm.js new file mode 100644 index 0000000..2460737 --- /dev/null +++ b/statechart/static/src/core/errors/error_dialogs.esm.js @@ -0,0 +1,13 @@ +/** @odoo-module **/ + +import {_lt} from "@web/core/l10n/translation"; +import {registry} from "@web/core/registry"; + +import {WarningDialog, odooExceptionTitleMap} from "@web/core/errors/error_dialogs"; + +registry + .category("error_dialogs") + .add("odoo.addons.statechart.exceptions.NoTransitionError", WarningDialog); + +odooExceptionTitleMap["odoo.addons.statechart.exceptions.NoTransitionError"] = + _lt("Transition Error"); From 3946696da75f183bc8449414afc275ee950e88f5 Mon Sep 17 00:00:00 2001 From: Thomas Binsfeld Date: Wed, 13 Aug 2025 10:58:23 +0200 Subject: [PATCH 6/6] [MIG] statechart 18.0: display error pop up instead of stacktrace when raising a TransitionError From https://github.com/acsone/scobidoo/pull/46 --- statechart/static/src/core/errors/error_dialogs.esm.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/statechart/static/src/core/errors/error_dialogs.esm.js b/statechart/static/src/core/errors/error_dialogs.esm.js index 2460737..b2304a7 100644 --- a/statechart/static/src/core/errors/error_dialogs.esm.js +++ b/statechart/static/src/core/errors/error_dialogs.esm.js @@ -1,13 +1,10 @@ -/** @odoo-module **/ - -import {_lt} from "@web/core/l10n/translation"; -import {registry} from "@web/core/registry"; - import {WarningDialog, odooExceptionTitleMap} from "@web/core/errors/error_dialogs"; +import {_t} from "@web/core/l10n/translation"; +import {registry} from "@web/core/registry"; registry .category("error_dialogs") .add("odoo.addons.statechart.exceptions.NoTransitionError", WarningDialog); odooExceptionTitleMap["odoo.addons.statechart.exceptions.NoTransitionError"] = - _lt("Transition Error"); + _t("Transition Error");