| changeset | 9c3ec0a5c7fc |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | chore: remove __future print_funcion from code. Not needed as of Python 3. |
| files |
| changeset | 9369e0958312 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551323: Remove XHTML support Deprecated in Roundup 2.3.0, invalid in 2.4.0, and removing supporting code in 2.5.0. |
| files |
| changeset | 4455cd036c25 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | fix: tests for changeset: 8314:7ff47307b4b1 use text for number input |
| files |
| changeset | a81a3cd067fa |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Ralf Schlatterbeck <rsc@runtux.com> |
| description | Generate savepoint only if necessary Now some methods got an additional 'allow_abort' parameter. By default this is True. When False the postgres backend generates a savepoint. The methods are called with allow_abort=False from some of the cgi methods which can produce a traceback when called with data from the web-interface. |
| files |
| changeset | b99e76e76496 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Ralf Schlatterbeck <rsc@runtux.com> |
| description | Make native date and number elements configurable Now for Number() and Integer() properties the browser-native number format can be configured with the use_browser_number_input config item in seciont [web]. The default is 'yes'. For Date() properties the config item is use_browser_date_input (also in section [web]) but the default is 'no'. In addition when defining Date() properties, these now have a parameter 'display_time' which defaults to 'yes' and a 'format' parameter which defaults to None. These set defaults for the field() method of the DateHTMLProperty which have the same parameters (but the display_time parameter of field() takes a boolean, not 'yes'/'no'). |
| files |
| changeset | 46886073c665 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | refactor: change method used to assign radiobuttons for boolean use setdefault('type', 'radiobutton') rather than hardcoding the value into the underlying self.input (input_html4) call. Also add test for undefined radiobutton. |
| files |
| changeset | e70dc7c43c9c |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | test: basic testing for BooleanHTMLProperty plain and field. |
| files |
| changeset | 60e682add9ea |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | test - fix broken test Had a test case for number inputs that I didn't know about. testmon didn't detect it had to be run. |
| files |
| changeset | 6445e63bb423 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | feat(web) - Use native number type input for Number() and Integer(). When editing hyperdb.Number() or hyperdb.Integer() properties, use a native number input. For Number you can enter digits, +/-, . and e/E for exponent (1E2 = 100). For integer we have the same keys as number, but also add step=1 to the input. This stops submitting 23.5 suggesting 23 or 24. It does allow 2E4 to be submitted that is rejected with an error from the backend. However if the spinner is used with 2E4 it is turned into 20000, a pure integer and incremented/decremented by the spinner. The upgrade happens automatically. Directions on going back to text input provided. User guide updated to describe addition of spinner. Tests added. |
| files |
| changeset | 2bf0c4e7795e |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | fix: issue2551390 - Replace text input/calendar popup with native date input Docs, code and test changes for the changeover to a native date element. See issue for details. |
| files |
| changeset | 669dfccca898 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551391 - checkboxes and radiobutton inputs get wrong id's. Actually it breaks automatic id assignment for all inputs. Inputs now get an automatic id assignment that matches the name. It can be overridden by supplting an id parameter in the call to the field() method. This is also a partial fix for issue1513369. I think it obsoletes the changes to templating.py. |
| files |
| changeset | a9b136565838 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | feat: issue1525113 - notation to filter by logged-in user At long last (almost 18 years) this patch lands. It allows sharing of queries that want to use the currently logged in user (i.e. I or me). By replacing an id number for the user by '@current_user' in the query you can share the query for "my issues" where 'my' is the logged in user not the person who created the query. Updated the templates to use this. Updated upgrading.py for directions on using it. RDBMS and anydbm both work. Also expressions using it (e.g. not @current_user) work and are tested. Test code done. I am not sure what the change to templating.py does. I am following the original patch and have built a test case to hit the if clause. But the rest of the test doesn't actualy provide the props I need. If I knew what that code was supposed to do there I would create a real test. |
| files |
| changeset | 29a666d8a70d |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551285 - Remove StructuredText support Asked on the users mailing list if anybody was using it. Got no responses. I have never seen CI installing structuredtext packages so it's untested as well. |
| files |
| 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 |
| changeset | b080cdb8b199 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | fix: document/fix wrapped HtmlProperty method. The wrapped method was not documented in reference.txt. It is now documented in reference.txt. The docstring documented that it would not break up long words. Fixed by adding break_long_words=False to prevent breaking string longer than the wrap length. Wrapping was breaking the hyperlinking of long urls. Added columns argument to set the wrap length (default 80 columns). |
| files |
| changeset | 978285986b2c |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | fix: issue2551193 - Fix roundup for removal of cgi and cgitb ... standard python modules (and FieldStorage/MiniFieldStorage). Vendor cgi.py and modify imports. Details: roundup/anypy/cgi_.py import that accesses a working cgi.py. All imports dealing with cgi now use cgi_. roundup/anypy/vendored/cgi.py vendored version 2.6 of cgi.py from: https://pypi.org/project/legacy-cgi/ CHANGES.txt change note added COPYING.txt added license for cgi.py doc/rest.txt change example to use cgi_ doc/upgrading.txt doc removal and how to rework local code using cgi.py. frontends/roundup.cgi remove unneeded cgi import roundup/cgi/actions.py roundup/cgi/apache.py roundup/cgi/client.py roundup/cgi/templating.py roundup/cgi/TAL/TALGenerator.py test/db_test_base.py test/rest_common.py test/test_cgi.py remove import cgi and replace with from roundup.anypy.cgi_ import cgi test/test_actions.py test/test_templating.py modify import to get *FieldStorage test/test_admin.py test/test_hyperdbvals.py test/test_xmlrpc.py remove unneeded cgi import |
| files |
| changeset | 7bdf9c0f74b9 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Handle error id markdown2 not defined. |
| files |
| changeset | 91725f12b239 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Support markdown2 2.4.10, 2.4.8- and exclude 2.4.9 Handle these changes to markdown2 version 2.4.9 broke links like (issue1)[issue1]: raise error if used Version 2.4.10 changed how filtering of schemes is done: adapt to new method Mail url's in markdown are formatted [label](mailto:user@something.com). The markdown format wrapper uses the plain text formatter to turn issue1 and user@something.com into markdown formatted strings to be htmlized by the markdown formatters. However when the plain text formatter saw (mailto:user@something.com) it made it (mailto:<user@something.com>). This is broken as the enamil address shouldn't have the angle brackets. By modifying the email pattern to include an optional mailto:, all three markdown formatters do the right thing and I don't end up with href="<user@something.com>" in the link. |
| files |
| changeset | f529cca242dc |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | flake8: fix imports, flake8 reported the following: templating.py:25:1: F401 'base64' imported but unused templating.py:25:1: F401 'mimetypes' imported but unused templating.py:25:1: F401 'string' imported but unused templating.py:28:1: F401 'time' imported but unused templating.py:28:1: F401 'hashlib' imported but unused templating.py:34:1: F401 'roundup.i18n' imported but unused templating.py:35:1: F401 'roundup.i18n._' imported but unused templating.py:36:1: F401 'roundup.anypy.strings.b2s' imported but unused templating.py:36:1: F401 'roundup.anypy.strings.s2b' imported but unused templating.py:43:1: F401 'roundup.anypy.random_' imported but unused templating.py:47:5: F401 'pickle' imported but unused Turns out time import was used by test_templating via from roundup.cgi.templating import * so added import time to test_templating Also split out multiple imports on one line into sepearate lines. Changed todo = to __todo__ to make flake8 shut up about module level imports not at top of file. Moved definiton of _disable_url_schemes for same reason. |
| files |
| changeset | dc83ebff4c90 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | change test to use html normalizer when comparing html output. Update to Markdown2 parser changed text output keeping same html semantics. Broke test_string_markdown_code_block_attribute test. I hand patched it to get tests working but it needed a better solution. Write a simple html normalizer using HTMLParser so I don't need third party (lxml, beautifulsoup) library to clean up the test. Use the normalizer to parser the expected result and the result returned by the various markdown libraries. Hopefully this will make the test less fragile. This can have multiple uses in template testing where html is compared. I expect to have to change html_norm.py to make test writing easier in the future. |
| files |
| changeset | a5f30372ef7f |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | New markdown2 release changed output with code highlighting (take 2) code highight div generated/used by pygments is on a separate line in 2.4.4 release of markdown2. python 2.7 still needs expected form without additonal newlines as 2.4.4 is python3 only. |
| files |
| changeset | 3085aac22f3a |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | New markdown2 release changed output with code highlighting code highight div generated/used by pygments is on a separate line in 2.4.4 release of markdown2. |
| files |
| changeset | 234fefd7568a |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2550559 - Pretty printing / formatting for Number types. add pretty(format='%0.3f') method to NumberHTMLProperty. |
| files |
| changeset | 28b906a237d8 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Fix anti_csrf_nonce test Make the MockDatabase inherit from roundup.backends.sessions_common SessionCommon. This provides the getUniqueKey method. Also the encoding as base64 changed the length, so had to adjust the assert. |
| files |
| changeset | 38b73f7495f8 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | fix mock datbase add lifetime() method. caused tests to break. Use time.mie() - week + lifetime. set() method sets __timestamp if not set. add getall useful for debugging. |
| files |
| changeset | 994893cf3e1a |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Ralf Schlatterbeck <rsc@runtux.com> |
| description | Fix traceback if an order attribute is None Fixes issue2551207. |
| files |
| changeset | b598b46eb427 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | remove error introduced to test the test. |
| files |
| changeset | 81d16e9f0f54 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | remove printing to stderr. That was an attempt to get the full stdout/stderr output to be produced by pytest for a test marked xfail. |
| files |
| changeset | 5b71a50e833b |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | try to get more info on failing test looks like m is not being formatted for markdown2 test case. No idea why. Trying to make output more verbose to figure out what's happening. pip in ci reports version 2.4.2 of markdown2 according to: https://app.travis-ci.com/github/roundup-tracker/roundup/jobs/568309619 same version I run locally with python 3.6.9. Fails in CI on 3.6, 3.8, 3.10.4. python 2.7 works on with version 2.3.10 of markdown2 |
| files |
| changeset | 21c7c2041a4b |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551181 - allow issueXXX#fragment to generate a link with fragment There is another ticket to add id's to elements displaying messages in issue.item.html. This change allows a fast way to link to such an element in a long issue with many messages once that other issue is committed and merged into a tracker template. |
| files |
| changeset | f1f8d75edd97 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Add variations on test for _hyper_url functons |
| files |
| changeset | e29d5f4e0af4 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551132 - Setting form value in query string --- issues Code now uses value in query string even if there is a default_value set. Also handle the exception caused by an invalid value specified in the query string. |
| files |
| changeset | a7e7314fb7d9 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551126 - AttributeError: 'str' object has no attribute 'local'. Fix traceback caused by DateHTMLProperty.pretty() called on a string value due to error in some other field. |
| files |
| changeset | ab18fe956d45 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Test StringHTMLProperty.wrapped(); test url, plain text for rst |
| files |
| changeset | a70a0c138dd9 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Test hyperlinked method on designators Smarter definition of hasnode in mock database. Designators with id's > 10 will return False from hasnode. |
| files |
| changeset | 316c2c32dace |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Make testing mock smarter. Make getclass fail for invalid classes. |
| files |
| changeset | 6f89cdc7c938 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551108 - fix markdown formatted designator links Designators like 'issue1' are automatically hyperlinked. However if typed as [issue1](issue1) or [issue1](https://example.com/issue1) they get mangled. Stop that mangling. |
| files |
| changeset | fd0bdcbc68e4 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551104 - fix issue with markdown autolink next to punctuation Given: [label](http://example.com/). generated href including the ').' This fixes that. |
| files |
| changeset | 3f7538316724 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551099 - disable processing of data url's in markdown. Display as plain text. Added 'data' to templating.py _disable_url_schemes array. User should be able to re-enable it by changing the array from the tracker's interfaces.py. Markdown tests failed before the change to _disable_url_schemes. Also add second separate data test for ReST and plain text processing. data url's look like they are already ignored in these proess streams. |
| files |
| changeset | d30501bafdfb |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551098: markdown links missing rel="noreferer nofollow" Links generated by all markdown backends are missing the noopener and nofollow relation that roundup's normal text -> html core adds to prevent security issues and link spam. Now rel="nofollow" is added to links generated by markdown2 backends and rel="nofollow noopener" for mistune and markdown backends. Markdown2 isn't as programable as the other two backends so I used the built-in nofollow support. This means that a user that generates a link that opens in a new window can manpulate the parent window. |
| files |
| changeset | 6ed5152a92d0 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551096 - enable markdown autolink for email and bare url's. Modify raw markdown adding appropriate link markers '<' and '>' on the fly so bare urls and email addreses are recognized as explicit links by markdown backends. Patch by Cedric Krier. |
| files |
| changeset | 9ec3a9bc4ea5 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551097 - fix call to markdown2 - fix fenced code blocks. The invocation of fenced codeblock support in markdown2 was wrong. With this fixed the code that was used to test markdown processor exception handling no longer works. Fixed test case to make it pass. Added new test with invalid markdown that tests markdown exception handling. Also renamed test to include markdown. Makes using -k option in run_tests easier. |
| files |
| changeset | 957a0fc20021 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | issue2551094 - markdown mismatch - new config for embedded newine Make earlier patch to fix mismatch between simplemde formatting of embedded newlines choosable. New option MARKDOWN_BREAK_ON_NEWLINE added to config.ini. If set to true all 4 renders: markdown, markdown2, mistune and simplemde will make a newline into a hard linebreak using <br> when displayed. |
| files |
| changeset | bda491248fd8 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Handle exception raised from markdown processing If an exception is raised from the markdown processor, return plain text to the user. |
| files |
| changeset | 474de62f4ce0 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Add test for hard linebreak fomatting in markdown issue2551094 proposes making any newline into a hard linebreak in the html. This is not markdown standard. Standard is two trailing spaces on a line followed by newline. Test that all formatters support it. |
| files |
| changeset | b108c9fc7aea |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Christof Meerwald <cmeerw@cmeerw.org> |
| description | fix test for Python 2 |
| files |
| changeset | a1fd9551d416 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Christof Meerwald <cmeerw@cmeerw.org> |
| description | don't allow javascript URLs in markdown content limit auto-linkification in markdown content to issue links to avoid interference with markdown link syntax |
| files |
| changeset | af16c135fb98 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | url's with javascript scheme should not be links in reST A javascript url in a reStructuredText document should not be displayed as a link. So: javascript:nastyJavascriptCode should be displayed as text and not a link. We do this by stripping the scheme from the schemes array in docutils.utils.urischemes. We set a property on the StringHTMLProperty to hold the list of schemes we want to disable so the user can choose to change it if they want. |
| files |
| changeset | 55c56ceacb8e |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Christof Meerwald <cmeerw@cmeerw.org> |
| description | escape HTML tags in markdown content enabled fenced code blocks for markdown allow mistune to be used as a markdown parser test all installed markdown parsers and fallback code |
| files |
| changeset | 72a281a55a17 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Disable rst raw and include directives. reStructuredText has some directives that can include files or pass raw html to the output. Create new property so user can enable raw or include directives if desired. See: https://docutils.sourceforge.io/docs/howto/security.html for details. |
| files |
| changeset | 90a1470edbea |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Christof Meerwald <cmeerw@cmeerw.org> |
| description | added markdown rendering support using either markdown2 or markdown |
| files |
| changeset | c914b3d8362f |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | If rst missing skip; initial attempt to test structuredtext. Try to set up structured text testing. I can't get StructuredText to run under python3, but this test passes under python2. Once I get StructuredText to pass under p3, I'll install StructuredText to ci and these tests won't be skipped. Also if import for reStructuredText fails, skip the test rather than silently passing. |
| files |
| changeset | 3ada6a3f48e1 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | Christof Meerwald <cmeerw@cmeerw.org> |
| description | fixed ReStructuredText encoding with Python 3 |
| files |
| changeset | f0da02e0ca81 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Different fix for displaying booleans properly in xhtml vs html Needed to fix the tests too. |
| files |
| changeset | c475159af6b8 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Add test and changelog for html boolean fix. |
| files |
| changeset | c3728772c594 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Add reverse option to hyperdb property wrapper by David Sowder issue2551013: Reversed sorting in hyperdb property wrapper object's sorted() method. Patch by David Sowder, application and doc change by John Rouillard. |
| files |
| changeset | fe35a232c6dc |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | Make comment block raw to avoid travis ci warning on \d in comment block. |
| files |
| changeset | 7d276bb8b46d |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | More invalid escape sequence fixes. |
| files |
| changeset | 10747e4e4ec4 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | replace assertNotEquals with assertNotEqual |
| files |
| changeset | 6aad7b194e63 |
|---|---|
| branch | |
| bookmark | |
| tag | |
| user | John Rouillard <rouilj@ieee.org> |
| description | replace assertEquals wth assertEqual. |
| files |