Mercurial > p > roundup > code
comparison roundup/cgi/templating.py @ 8528:fed0f839c260
fix: replace except: with except Exception: (by haosenwang1018@github)
Remove bare 'except:' statements replace with 'except Exception'.
In roundup_xmlrpc_server.py I changed Exception to BaseException so
the database gets closed on signals as well. The rest of the changes
do not look like they affect data integrity and are commited as
supplied.
| author | John Rouillard <rouilj@ieee.org> |
|---|---|
| date | Thu, 26 Feb 2026 09:46:02 -0500 |
| parents | 0663a7bcef6c |
| children | bedf11bc0dd5 |
comparison
equal
deleted
inserted
replaced
| 8527:d4a43d9da8ef | 8528:fed0f839c260 |
|---|---|
| 2715 # sorting fails if the value contains | 2715 # sorting fails if the value contains |
| 2716 # items not yet stored in the database | 2716 # items not yet stored in the database |
| 2717 # ignore these errors to preserve user input | 2717 # ignore these errors to preserve user input |
| 2718 try: | 2718 try: |
| 2719 display_value.sort(key=keyfun) | 2719 display_value.sort(key=keyfun) |
| 2720 except: | 2720 except Exception: |
| 2721 pass | 2721 pass |
| 2722 self._value = display_value | 2722 self._value = display_value |
| 2723 | 2723 |
| 2724 def __len__(self): | 2724 def __len__(self): |
| 2725 """ length of the multilink """ | 2725 """ length of the multilink """ |
