Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#13615 closed defect (fixed)

IniAdminPlugins shows a blank page

Reported by: matobaa Owned by: Jun Omae
Priority: normal Component: IniAdminPlugin
Severity: normal Keywords:
Cc: Trac Release: 1.4

Description (last modified by matobaa)

trac.log shows it uses a genshi template as a jinja2 template. refer a patch attached.

2019-09-24 14:22:17,210 Trac[env] INFO: -------------------------------- environment startup [Trac 1.4] --------------------------------
2019-09-24 14:22:18,596 Trac[chrome] ERROR: Jinja2 UndefinedError error while rendering XML/HTML template 
Traceback (most recent call last):
  File "h:\trac14\.venv\lib\site-packages\trac\web\", line 1704, in _iterable_jinja_content
    for chunk in stream:
  File "h:\trac14\.venv\lib\site-packages\jinja2\", line 1271, in __next__
    return self._next()
  File "h:\trac14\.venv\lib\site-packages\jinja2\", line 1248, in _buffered_generator
    c = next(self._gen)
  File "h:\trac14\.venv\lib\site-packages\jinja2\", line 1045, in generate
    yield self.environment.handle_exception(exc_info, True)
  File "h:\trac14\.venv\lib\site-packages\jinja2\", line 780, in handle_exception
    reraise(exc_type, exc_value, tb)
  File "h:\trac14\iniadminplugin\0.11\iniadmin\templates\iniadmin.html", line 32, in top-level template code
    <li py:for="idx, option in enumerate(iniadmin.options)" class="align${idx % 3}">
UndefinedError: 'idx' is undefined

Attachments (1)

iniadmin_14.patch (888 bytes) - added by matobaa 4 years ago.

Download all attachments as: .zip

Change History (5)

Changed 4 years ago by matobaa

Attachment: iniadmin_14.patch added

comment:1 Changed 4 years ago by matobaa

Description: modified (diff)

comment:2 Changed 4 years ago by Jun Omae

Resolution: fixed
Status: newclosed

In 17515:

IniAdminPlugin: support Trac 1.4+ by Jinja2 template file and bump up the version to 0.5 (closes #13615)

comment:3 Changed 4 years ago by Jun Omae

Thanks for reporting and the patch. However, I considered it would be nice to natively support Jinja2 template rather than requiring Genshi on Trac 1.4.

comment:4 Changed 4 years ago by Jun Omae

In 17524:

IniAdminPlugin: fix wrong rendering in Jinja2 template for BoolOption, ListOption and ExtensionOption (refs #13615)

Modify Ticket

Change Properties
Set your email in Preferences
as closed The owner will remain Jun Omae.
The resolution will be deleted. Next status will be 'reopened'.

Add Comment

E-mail address and name can be saved in the Preferences.

Note: See TracTickets for help on using tickets.