Modify

Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#13195 closed defect (fixed)

TypeError: startswith first arg must be str, unicode, or tuple, not bool

Reported by: Ryan J Ollos Owned by: Ryan J Ollos
Priority: normal Component: WikiExtrasPlugin
Severity: normal Keywords:
Cc: Trac Release:

Description (last modified by Ryan J Ollos)

Found in the logs:

2017-05-26 21:49:07,053 Trac[formatter] ERROR: Processor box failed:
Traceback (most recent call last):
  File "/srv/trac-hacks.org/pve/local/lib/python2.7/site-packages/trac/wiki/formatter.py", line 1197, in _exec_processor
    return processor.process(text)
  File "/srv/trac-hacks.org/pve/local/lib/python2.7/site-packages/trac/wiki/formatter.py", line 379, in process
    text = self.processor(text)
  File "/srv/trac-hacks.org/pve/local/lib/python2.7/site-packages/trac/wiki/formatter.py", line 348, in _macro_processor
    text, self.args)
  File "/srv/trac-hacks.org/pve/local/lib/python2.7/site-packages/tracwikiextras/boxes.py", line 385, in expand_macro
    type = self._get_type(type)
  File "/srv/trac-hacks.org/pve/local/lib/python2.7/site-packages/tracwikiextras/boxes.py", line 340, in _get_type
    if w.startswith(word):
TypeError: startswith first arg must be str, unicode, or tuple, not bool

Attachments (0)

Change History (4)

comment:1 Changed 8 years ago by Ryan J Ollos

Description: modified (diff)

comment:2 Changed 8 years ago by Ryan J Ollos

Owner: changed from Mikael Relbe to Ryan J Ollos
Status: newaccepted

I cannot figure out how a boolean could occur as an argument: wikiextrasplugin/trunk/tracwikiextras/boxes.py@15942:340,379,385#L332.

I'll add some logging so that future investigation will be easier.

Last edited 8 years ago by Ryan J Ollos (previous) (diff)

comment:3 Changed 8 years ago by Ryan J Ollos

Resolution: fixed
Status: acceptedclosed

In 16628:

TracWikiExtras 1.3.1dev: Improve logging when argument is incorrect type

Fixes #13195.

comment:4 Changed 8 years ago by Ryan J Ollos

In 16629:

TracWikiExtras 1.3.1dev: Remove debug statement

Refs #13195.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as closed The owner will remain Ryan J Ollos.
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.