Skip to content

Commit 12ae738

Browse files
committed
issue2551196 - Unset labelprop of a Multilink can lead to Python error when using context/history
Fix history by adding default string value to calls to link_class.get(). Mark as translatable string. Include originally identified multilink path and apply same fix to link path. Also fix a possible issue in the plain() display paths for link/multilink the same way if the label is missing. Update translation files.
1 parent 9ee0fa6 commit 12ae738

File tree

15 files changed

+506
-420
lines changed

15 files changed

+506
-420
lines changed

CHANGES.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,9 @@ Fixed:
7575
(John Rouillard)
7676
- issue2551142 - postgresql reworked to use savepoint/"rollback to"
7777
rather than commit()/rollback(). Using savepoint should be faster.
78+
- issue2551196 - Unset labelprop of a Multilink can lead to Python
79+
error when using context/history. (reported and initial patch: Nagy
80+
Gabor, John Rouillard)
7881

7982
Features:
8083

locale/de.po

Lines changed: 38 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ msgid ""
77
msgstr ""
88
"Project-Id-Version: Roundup 1.5.0\n"
99
"Report-Msgid-Bugs-To: [email protected]\n"
10-
"POT-Creation-Date: 2022-01-28 00:18-0500\n"
10+
"POT-Creation-Date: 2022-03-05 18:51-0500\n"
1111
"PO-Revision-Date: 2016-04-11 09:13+0200\n"
1212
"Last-Translator: Tobias Herp <[email protected]>\n"
1313
"Language-Team: German Translators <[email protected]>\n"
@@ -2000,18 +2000,18 @@ msgid "Submit New Entry"
20002000
msgstr "Eintrag speichern"
20012001

20022002
#: ../roundup/cgi/templating.py:963 ../roundup/cgi/templating.py:1134
2003-
#: ../roundup/cgi/templating.py:1750 ../roundup/cgi/templating.py:1779
2004-
#: ../roundup/cgi/templating.py:1799 ../roundup/cgi/templating.py:1812
2005-
#: ../roundup/cgi/templating.py:1849 ../roundup/cgi/templating.py:1902
2006-
#: ../roundup/cgi/templating.py:1925 ../roundup/cgi/templating.py:1932
2007-
#: ../roundup/cgi/templating.py:1968 ../roundup/cgi/templating.py:2005
2008-
#: ../roundup/cgi/templating.py:2038 ../roundup/cgi/templating.py:2127
2009-
#: ../roundup/cgi/templating.py:2148 ../roundup/cgi/templating.py:2238
2010-
#: ../roundup/cgi/templating.py:2258 ../roundup/cgi/templating.py:2280
2011-
#: ../roundup/cgi/templating.py:2319 ../roundup/cgi/templating.py:2329
2012-
#: ../roundup/cgi/templating.py:2393 ../roundup/cgi/templating.py:2691
2013-
#: ../roundup/cgi/templating.py:963:1134 :1750:1779 :1799:1812 :1849:1902
2014-
#: :1925:1932 :1968:2005 :2038:2127 :2148:2238 :2258:2280 :2319:2329 :2393:2691
2003+
#: ../roundup/cgi/templating.py:1753 ../roundup/cgi/templating.py:1782
2004+
#: ../roundup/cgi/templating.py:1802 ../roundup/cgi/templating.py:1815
2005+
#: ../roundup/cgi/templating.py:1852 ../roundup/cgi/templating.py:1905
2006+
#: ../roundup/cgi/templating.py:1928 ../roundup/cgi/templating.py:1935
2007+
#: ../roundup/cgi/templating.py:1971 ../roundup/cgi/templating.py:2008
2008+
#: ../roundup/cgi/templating.py:2041 ../roundup/cgi/templating.py:2130
2009+
#: ../roundup/cgi/templating.py:2151 ../roundup/cgi/templating.py:2241
2010+
#: ../roundup/cgi/templating.py:2261 ../roundup/cgi/templating.py:2283
2011+
#: ../roundup/cgi/templating.py:2322 ../roundup/cgi/templating.py:2332
2012+
#: ../roundup/cgi/templating.py:2396 ../roundup/cgi/templating.py:2695
2013+
#: ../roundup/cgi/templating.py:963:1134 :1753:1782 :1802:1815 :1852:1905
2014+
#: :1928:1935 :1971:2008 :2041:2130 :2151:2241 :2261:2283 :2322:2332 :2396:2695
20152015
msgid "[hidden]"
20162016
msgstr "[verborgen]"
20172017

@@ -2037,18 +2037,24 @@ msgstr "<em>%s: %s</em>\n"
20372037
msgid "The linked class %(classname)s no longer exists"
20382038
msgstr "Die verlinkte Klasse \"%(classname)s\" existiert nicht mehr"
20392039

2040+
#: ../roundup/cgi/templating.py:1249 ../roundup/cgi/templating.py:1277
2041+
#: ../roundup/cgi/templating.py:2405 ../roundup/cgi/templating.py:2704
2042+
#: ../roundup/cgi/templating.py:1249:1277 :2405:2704
2043+
msgid "[label is missing]"
2044+
msgstr ""
2045+
20402046
# ../roundup/cgi/templating.py:905 :926
2041-
#: ../roundup/cgi/templating.py:1251 ../roundup/cgi/templating.py:1277
2042-
#: ../roundup/cgi/templating.py:1251:1277
2047+
#: ../roundup/cgi/templating.py:1253 ../roundup/cgi/templating.py:1280
2048+
#: ../roundup/cgi/templating.py:1253:1280
20432049
msgid "<strike>The linked node no longer exists</strike>"
20442050
msgstr "<strike>Der verknüpfte Eintrag existiert nicht mehr</strike>"
20452051

2046-
#: ../roundup/cgi/templating.py:1338
2052+
#: ../roundup/cgi/templating.py:1341
20472053
#, python-format
20482054
msgid "%s: (no value)"
20492055
msgstr "%s: (kein Wert)"
20502056

2051-
#: ../roundup/cgi/templating.py:1354
2057+
#: ../roundup/cgi/templating.py:1357
20522058
#, fuzzy, python-format
20532059
msgid ""
20542060
"<strong><em>This event %s is not handled by the history display!</em></"
@@ -2057,66 +2063,66 @@ msgstr ""
20572063
"<strong><em>Dieses Ereignis kann nicht im Verlauf angezeigt werden!</em></"
20582064
"strong>"
20592065

2060-
#: ../roundup/cgi/templating.py:1367
2066+
#: ../roundup/cgi/templating.py:1370
20612067
msgid "<tr><td colspan=4><strong>Note:</strong></td></tr>"
20622068
msgstr "<tr><td colspan=\"4\"><strong>Bitte beachten:</strong></td></tr>"
20632069

2064-
#: ../roundup/cgi/templating.py:1376
2070+
#: ../roundup/cgi/templating.py:1379
20652071
msgid "History"
20662072
msgstr "Verlauf"
20672073

2068-
#: ../roundup/cgi/templating.py:1378
2074+
#: ../roundup/cgi/templating.py:1381
20692075
msgid "<th>Date</th>"
20702076
msgstr "<th>Datum</th>"
20712077

2072-
#: ../roundup/cgi/templating.py:1379
2078+
#: ../roundup/cgi/templating.py:1382
20732079
msgid "<th>User</th>"
20742080
msgstr "<th>Benutzer</th>"
20752081

2076-
#: ../roundup/cgi/templating.py:1380
2082+
#: ../roundup/cgi/templating.py:1383
20772083
msgid "<th>Action</th>"
20782084
msgstr "<th>Aktion</th>"
20792085

2080-
#: ../roundup/cgi/templating.py:1381
2086+
#: ../roundup/cgi/templating.py:1384
20812087
msgid "<th>Args</th>"
20822088
msgstr "<th>Argumente</th>"
20832089

2084-
#: ../roundup/cgi/templating.py:1432
2090+
#: ../roundup/cgi/templating.py:1435
20852091
#, python-format
20862092
msgid "Copy of %(class)s %(id)s"
20872093
msgstr "Kopie von %(class)s %(id)s"
20882094

2089-
#: ../roundup/cgi/templating.py:2042 ../roundup/cgi/templating.py:2075
2090-
#: ../roundup/cgi/templating.py:1320:2042:2075
2095+
#: ../roundup/cgi/templating.py:2045 ../roundup/cgi/templating.py:2078
2096+
#: ../roundup/cgi/templating.py:1323:2045:2078
20912097
msgid "No"
20922098
msgstr "Nein"
20932099

2094-
#: ../roundup/cgi/templating.py:2042 ../roundup/cgi/templating.py:2070
2095-
#: ../roundup/cgi/templating.py:1320:2042:2070
2100+
#: ../roundup/cgi/templating.py:2045 ../roundup/cgi/templating.py:2073
2101+
#: ../roundup/cgi/templating.py:1323:2045:2073
20962102
msgid "Yes"
20972103
msgstr "Ja"
20982104

2099-
#: ../roundup/cgi/templating.py:2196
2105+
#: ../roundup/cgi/templating.py:2199
21002106
msgid ""
21012107
"default value for DateHTMLProperty must be either DateHTMLProperty or string "
21022108
"date representation."
21032109
msgstr ""
21042110
"Der voreingestellte Wert einer DateHTML-Eigenschaft muss entweder ein\n"
21052111
"DateHTML-Objekt sein oder ein Datum repräsentieren."
21062112

2107-
#: ../roundup/cgi/templating.py:2373
2113+
#: ../roundup/cgi/templating.py:2376
21082114
#, python-format
21092115
msgid "Attempt to look up %(attr)s on a missing value"
21102116
msgstr ""
21112117
"Versuch, das Attribut %(attr)s eines nicht vorhandenen Werts abzufragen"
21122118

2113-
#: ../roundup/cgi/templating.py:2384
2119+
#: ../roundup/cgi/templating.py:2387
21142120
#, fuzzy, python-format
21152121
msgid "Attempt to look up %(item)s on a missing value"
21162122
msgstr ""
21172123
"Versuch, das Attribut %(attr)s eines nicht vorhandenen Werts abzufragen"
21182124

2119-
#: ../roundup/cgi/templating.py:2487
2125+
#: ../roundup/cgi/templating.py:2491
21202126
#, python-format
21212127
msgid "<option %svalue=\"-1\">- no selection -</option>"
21222128
msgstr "<option %svalue=\"-1\">- nichts ausgewählt -</option>"

locale/en.po

Lines changed: 38 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ msgid ""
1111
msgstr ""
1212
"Project-Id-Version: Roundup 0.7.0\n"
1313
"Report-Msgid-Bugs-To: [email protected]\n"
14-
"POT-Creation-Date: 2022-01-28 00:18-0500\n"
14+
"POT-Creation-Date: 2022-03-05 18:51-0500\n"
1515
"PO-Revision-Date: 2004-11-20 13:47+0200\n"
1616
"Language-Team: English\n"
1717
"Language: \n"
@@ -1534,18 +1534,18 @@ msgid "Submit New Entry"
15341534
msgstr ""
15351535

15361536
#: ../roundup/cgi/templating.py:963 ../roundup/cgi/templating.py:1134
1537-
#: ../roundup/cgi/templating.py:1750 ../roundup/cgi/templating.py:1779
1538-
#: ../roundup/cgi/templating.py:1799 ../roundup/cgi/templating.py:1812
1539-
#: ../roundup/cgi/templating.py:1849 ../roundup/cgi/templating.py:1902
1540-
#: ../roundup/cgi/templating.py:1925 ../roundup/cgi/templating.py:1932
1541-
#: ../roundup/cgi/templating.py:1968 ../roundup/cgi/templating.py:2005
1542-
#: ../roundup/cgi/templating.py:2038 ../roundup/cgi/templating.py:2127
1543-
#: ../roundup/cgi/templating.py:2148 ../roundup/cgi/templating.py:2238
1544-
#: ../roundup/cgi/templating.py:2258 ../roundup/cgi/templating.py:2280
1545-
#: ../roundup/cgi/templating.py:2319 ../roundup/cgi/templating.py:2329
1546-
#: ../roundup/cgi/templating.py:2393 ../roundup/cgi/templating.py:2691
1547-
#: ../roundup/cgi/templating.py:963:1134 :1750:1779 :1799:1812 :1849:1902
1548-
#: :1925:1932 :1968:2005 :2038:2127 :2148:2238 :2258:2280 :2319:2329 :2393:2691
1537+
#: ../roundup/cgi/templating.py:1753 ../roundup/cgi/templating.py:1782
1538+
#: ../roundup/cgi/templating.py:1802 ../roundup/cgi/templating.py:1815
1539+
#: ../roundup/cgi/templating.py:1852 ../roundup/cgi/templating.py:1905
1540+
#: ../roundup/cgi/templating.py:1928 ../roundup/cgi/templating.py:1935
1541+
#: ../roundup/cgi/templating.py:1971 ../roundup/cgi/templating.py:2008
1542+
#: ../roundup/cgi/templating.py:2041 ../roundup/cgi/templating.py:2130
1543+
#: ../roundup/cgi/templating.py:2151 ../roundup/cgi/templating.py:2241
1544+
#: ../roundup/cgi/templating.py:2261 ../roundup/cgi/templating.py:2283
1545+
#: ../roundup/cgi/templating.py:2322 ../roundup/cgi/templating.py:2332
1546+
#: ../roundup/cgi/templating.py:2396 ../roundup/cgi/templating.py:2695
1547+
#: ../roundup/cgi/templating.py:963:1134 :1753:1782 :1802:1815 :1852:1905
1548+
#: :1928:1935 :1971:2008 :2041:2130 :2151:2241 :2261:2283 :2322:2332 :2396:2695
15491549
msgid "[hidden]"
15501550
msgstr ""
15511551

@@ -1571,79 +1571,85 @@ msgstr ""
15711571
msgid "The linked class %(classname)s no longer exists"
15721572
msgstr ""
15731573

1574-
#: ../roundup/cgi/templating.py:1251 ../roundup/cgi/templating.py:1277
1575-
#: ../roundup/cgi/templating.py:1251:1277
1574+
#: ../roundup/cgi/templating.py:1249 ../roundup/cgi/templating.py:1277
1575+
#: ../roundup/cgi/templating.py:2405 ../roundup/cgi/templating.py:2704
1576+
#: ../roundup/cgi/templating.py:1249:1277 :2405:2704
1577+
msgid "[label is missing]"
1578+
msgstr ""
1579+
1580+
#: ../roundup/cgi/templating.py:1253 ../roundup/cgi/templating.py:1280
1581+
#: ../roundup/cgi/templating.py:1253:1280
15761582
msgid "<strike>The linked node no longer exists</strike>"
15771583
msgstr ""
15781584

1579-
#: ../roundup/cgi/templating.py:1338
1585+
#: ../roundup/cgi/templating.py:1341
15801586
#, python-format
15811587
msgid "%s: (no value)"
15821588
msgstr ""
15831589

1584-
#: ../roundup/cgi/templating.py:1354
1590+
#: ../roundup/cgi/templating.py:1357
15851591
#, python-format
15861592
msgid ""
15871593
"<strong><em>This event %s is not handled by the history display!</em></"
15881594
"strong>"
15891595
msgstr ""
15901596

1591-
#: ../roundup/cgi/templating.py:1367
1597+
#: ../roundup/cgi/templating.py:1370
15921598
msgid "<tr><td colspan=4><strong>Note:</strong></td></tr>"
15931599
msgstr ""
15941600

1595-
#: ../roundup/cgi/templating.py:1376
1601+
#: ../roundup/cgi/templating.py:1379
15961602
msgid "History"
15971603
msgstr ""
15981604

1599-
#: ../roundup/cgi/templating.py:1378
1605+
#: ../roundup/cgi/templating.py:1381
16001606
msgid "<th>Date</th>"
16011607
msgstr ""
16021608

1603-
#: ../roundup/cgi/templating.py:1379
1609+
#: ../roundup/cgi/templating.py:1382
16041610
msgid "<th>User</th>"
16051611
msgstr ""
16061612

1607-
#: ../roundup/cgi/templating.py:1380
1613+
#: ../roundup/cgi/templating.py:1383
16081614
msgid "<th>Action</th>"
16091615
msgstr ""
16101616

1611-
#: ../roundup/cgi/templating.py:1381
1617+
#: ../roundup/cgi/templating.py:1384
16121618
msgid "<th>Args</th>"
16131619
msgstr ""
16141620

1615-
#: ../roundup/cgi/templating.py:1432
1621+
#: ../roundup/cgi/templating.py:1435
16161622
#, python-format
16171623
msgid "Copy of %(class)s %(id)s"
16181624
msgstr ""
16191625

1620-
#: ../roundup/cgi/templating.py:2042 ../roundup/cgi/templating.py:2075
1621-
#: ../roundup/cgi/templating.py:1320:2042:2075
1626+
#: ../roundup/cgi/templating.py:2045 ../roundup/cgi/templating.py:2078
1627+
#: ../roundup/cgi/templating.py:1323:2045:2078
16221628
msgid "No"
16231629
msgstr ""
16241630

1625-
#: ../roundup/cgi/templating.py:2042 ../roundup/cgi/templating.py:2070
1626-
#: ../roundup/cgi/templating.py:1320:2042:2070
1631+
#: ../roundup/cgi/templating.py:2045 ../roundup/cgi/templating.py:2073
1632+
#: ../roundup/cgi/templating.py:1323:2045:2073
16271633
msgid "Yes"
16281634
msgstr ""
16291635

1630-
#: ../roundup/cgi/templating.py:2196
1636+
#: ../roundup/cgi/templating.py:2199
16311637
msgid ""
16321638
"default value for DateHTMLProperty must be either DateHTMLProperty or string "
16331639
"date representation."
16341640
msgstr ""
16351641

1636-
#: ../roundup/cgi/templating.py:2373
1642+
#: ../roundup/cgi/templating.py:2376
16371643
#, python-format
16381644
msgid "Attempt to look up %(attr)s on a missing value"
16391645
msgstr ""
16401646

1641-
#: ../roundup/cgi/templating.py:2384
1647+
#: ../roundup/cgi/templating.py:2387
16421648
#, python-format
16431649
msgid "Attempt to look up %(item)s on a missing value"
16441650
msgstr ""
16451651

1646-
#: ../roundup/cgi/templating.py:2487
1652+
#: ../roundup/cgi/templating.py:2491
16471653
#, python-format
16481654
msgid "<option %svalue=\"-1\">- no selection -</option>"
16491655
msgstr ""

0 commit comments

Comments
 (0)