http://hg.code.sf.net:8000/p/roundup/code/atom-log/tip/roundup/cgi/ZTUtils/Iterator.py Mercurial Repository: p/roundup/code: roundup/cgi/ZTUtils/Iterator.py history 2026-02-26T09:46:02-05:00 fix: replace except: with except Exception: (by haosenwang1018@github) http://hg.code.sf.net:8000/p/roundup/code/#changeset-fed0f839c26062bca99304a0198a17cf21554915 John Rouillard rouilj@ieee.org 2026-02-26T09:46:02-05:00 2026-02-26T09:46:02-05:00
changeset fed0f839c260
branch
bookmark
tag
user John Rouillard <rouilj@ieee.org>
description 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.
files
issue2551331 - Fix repeat first/last methods. http://hg.code.sf.net:8000/p/roundup/code/#changeset-9bbc1d951677d29244bd0936142854a34cc93f4c John Rouillard rouilj@ieee.org 2024-04-07T20:52:17-04:00 2024-04-07T20:52:17-04:00
changeset 9bbc1d951677
branch
bookmark
tag
user John Rouillard <rouilj@ieee.org>
description issue2551331 - Fix repeat first/last methods.

The first() and last() methods for a variable defined by tal:repeat
now work as documented.

There is an undocumented same_part() method for repeat. It is called
by first/last and can cause them to return true when not at an end of
the Iterator sequence. I wrote a treatise on that function and what it
does. I have no idea why it does what it does.

Added tests for roundup/cgi/ZTUtils/Iterator.py

Also fixes issue with roman() found while writing tests. lower wasn't
being called and it was printing the lower() method signature.

Doc updates in references.txt to come in a future checkin. Clarifying
the repeat methods led to finding/fixing this.
files
Python 3 preparation: avoid string.lower. http://hg.code.sf.net:8000/p/roundup/code/#changeset-ef6631409171e9aebea034cbd3e0ed71eb40e54b Joseph Myers jsm@polyomino.org.uk 2018-07-25T09:09:28+00:00 2018-07-25T09:09:28+00:00
changeset ef6631409171
branch
bookmark
tag
user Joseph Myers <jsm@polyomino.org.uk>
description Python 3 preparation: avoid string.lower.
files
Python 3 preparation: update next() usage for iterators. http://hg.code.sf.net:8000/p/roundup/code/#changeset-831787cf669468fdff1d0d4ff9b5a90cf6285515 Joseph Myers jsm@polyomino.org.uk 2018-07-24T23:12:32+00:00 2018-07-24T23:12:32+00:00
changeset 831787cf6694
branch
bookmark
tag
user Joseph Myers <jsm@polyomino.org.uk>
description Python 3 preparation: update next() usage for iterators.

Tool-assisted patch. Note that various classes in TAL code with
next() methods are not actually Python iterators and so are not
changed in this patch, but roundup/cgi/ZTUtils/Iterator.py includes
the IterIter class which converts between the two styles of iterator.
files
Python 3 preparation: "raise" syntax. http://hg.code.sf.net:8000/p/roundup/code/#changeset-35ea9b1efc1494f29fb07690e7087686de58e0f3 Joseph Myers jsm@polyomino.org.uk 2018-07-24T21:39:58+00:00 2018-07-24T21:39:58+00:00
changeset 35ea9b1efc14
branch
bookmark
tag
user Joseph Myers <jsm@polyomino.org.uk>
description Python 3 preparation: "raise" syntax.

Changing "raise Exception, value" to "raise Exception(value)".
Tool-assisted patch. Particular cases to check carefully are the one
place in frontends/ZRoundup/ZRoundup.py where a string exception
needed to be fixed, and the one in roundup/cgi/client.py involving
raising an exception with a traceback (requires three-argument form of
raise in Python 2, which as I understand it requires exec() to avoid a
Python 3 syntax error).
files
Remove keyword expansions from CVS. All regression tests passed afterwards. http://hg.code.sf.net:8000/p/roundup/code/#changeset-6e3e4f24c75376f61ae0bf0e9ee334567585c38e Eric S. Raymond esr@thyrsus.com 2011-11-16T09:51:38-05:00 2011-11-16T09:51:38-05:00
changeset 6e3e4f24c753
branch
bookmark
tag
user Eric S. Raymond <esr@thyrsus.com>
description Remove keyword expansions from CVS. All regression tests passed afterwards.
files
[maint-0.8] merge from HEAD http://hg.code.sf.net:8000/p/roundup/code/#changeset-291652465de4efa5834054ae06e232da1a67fba4 Richard Jones richard@users.sourceforge.net 2005-02-16T22:10:24+00:00 2005-02-16T22:10:24+00:00
changeset 291652465de4
branch maint-0.8
bookmark
tag
user Richard Jones <richard@users.sourceforge.net>
description merge from HEAD
files
change ZTUtils Iterator to always iter() its sequence argument http://hg.code.sf.net:8000/p/roundup/code/#changeset-d2b1a946fdf45bab969d9d58eef39545f3fa2296 Richard Jones richard@users.sourceforge.net 2005-02-16T22:07:33+00:00 2005-02-16T22:07:33+00:00
changeset d2b1a946fdf4
branch
bookmark
tag
user Richard Jones <richard@users.sourceforge.net>
description change ZTUtils Iterator to always iter() its sequence argument

also s/multilinkGenerator/viewableGenerator
files
documentation cleanup http://hg.code.sf.net:8000/p/roundup/code/#changeset-fc52d57c6c3e1527f340677f484744a40f645ad4 Richard Jones richard@users.sourceforge.net 2004-02-11T23:55:10+00:00 2004-02-11T23:55:10+00:00
changeset fc52d57c6c3e
branch
bookmark
tag
user Richard Jones <richard@users.sourceforge.net>
description documentation cleanup
files
Zope Collector fixes. http://hg.code.sf.net:8000/p/roundup/code/#changeset-69bf0d381fd7fa88f674c59876f15d84e2f6720e Richard Jones richard@users.sourceforge.net 2002-09-26T21:54:18+00:00 2002-09-26T21:54:18+00:00
changeset 69bf0d381fd7
branch
bookmark
tag
user Richard Jones <richard@users.sourceforge.net>
description Zope Collector fixes.

- merge Zope Collector #538 fix from ZPT CVS trunk (path expressions with a
non-path final alternate no longer try to call a value returned by that
alternate)
- merge Zope Collector #573 fix from ZPT CVS trunk
- added 1000-user/issue benchmark test
files
moved http://hg.code.sf.net:8000/p/roundup/code/#changeset-b9988e118055f23a0685ebfe4ca61b4b96a95d0c Richard Jones richard@users.sourceforge.net 2002-09-05T00:37:09+00:00 2002-09-05T00:37:09+00:00
changeset b9988e118055
branch
bookmark
tag
user Richard Jones <richard@users.sourceforge.net>
description moved
files