aboutsummaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2019-07-09States with names containing special characters are not correctly escapedHEADproductionmasterAndrew Donnellan
when generating the select list. Use escape() to fix this. Signed-off-by: Andrew Donnellan <ajd@linux.ibm.com> (cherry picked from commit b3fa0c402e060622a5ed539a465d2fa98b1d2e13) Signed-off-by: Daniel Axtens <dja@axtens.net> [Fixup for 1.16 context, CVE-2019-13122 ] Signed-off-by: Armin Kuster <akuster@mvista.com>
2017-11-06tools/post-receive.hook: add old releases to STATE_MAPJose Lamego
patches that are targeted to previous releases (other than master) are not tracked in patchwork. This change allows tracking older releases by adding morty, pyro and rocko branches to patchwork's STATE_MAP, so appropriate patch status can be assigned. [YOCTO #10716] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-09-07patchwork/templates/patchwork/series.html: Add link columnJose Lamego
Clicking on a patch name in Series view displays the patch at the botton section in same page, but there is no easy way to get a direct link to the patch, for example: to share the link. This change includes the column "Link" where a direct link to the patch is displayed and labeled with the patch id, that can be copied or clicked to display the patch detail on a new tab. [YOCTO #11888] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-09-06htdocs/js/series.js: Style active tab in series data barJose Lamego
There is no visual indication on which is the active tab at the Series data bar, providing a poor UX. This change adds the "active" styling to the Series data bar. [YOCTO #11886] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-09-06htdocs/js/series.js: Default to cover letter view only if one is availableJose Lamego
Cover letter content section is displayed by default at the Series view even if no cover letter is available, providing a poor UX. This change makes the Cover letter content section to be displayed by default if a cover letter is available, otherwise the Patches list is to be displayed by default at the Series view and the Cover letter tab will include a "N/A" legend and an informative tooltip when hover over the mouse cursor. [YOCTO #11887] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-09-06htdocs/css/style.css: fix select style in FF and IEJose Lamego
Series view displays the "Revision" select element not in line with the general patchwork style/design when viewed using Firefox or Internet Explorer browsers due to a known incompatibility of this browsers with Boostrap library (for example, an arrow head inside a button is displayed next to the "Revision" select element when using FF). This change hides the out-of-style items by using browser-specific css properties "moz-appearance" and "ms-expand". [YOCTO #11886] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-09-06parsemail: keep branch name in subject for seriesJose Lamego
patches with different branch names included in their name are wrongly appended as succesive revisions of the same patch in a series. This is due to the patches being assigned to the same series after their prefixes got removed during series naming/search. This change looks for an updated release name list from the Yocto wiki and keeps the release name in the series naming/search, effectively creating individual series for patches targeted to diferent releases. [YOCTO #10716] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-07-03pwclient: encode patch info output to utf-8Jose Lamego
Unicode encode errors are displayed when the post-receive git hook updates the patch state at patchwork. This is caused by piping the action_info function print output to other function, where the default python encoding is used instead of the system's. This change explicitly encodes the get-patch_id function print output to UTF-8. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-06-28post-receive.hook: skip patches in Accepted stateJose Lamego
Periodic master-next branch updates can modify state in patchwork for patches that are already in Accepted state, missleading users about the actual patch integration status. This change validates the current state of the patch to skip the change if it is Accepted. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-06-20pwclient: upgrade to latest versionJose Lamego
Several fixes got incorporated at upstream up to May 23, 2017, including: -Force xmlrpc client to return unicode strings -Fix silent crash on Python 2 -Support 3-way merge -accept alternate http_proxy forms -Support proxy configuration Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-06-16tools/post-receive.hook: use git work directoryJose Lamego
post-receive hook may not found merged commits when called from git repositories located in directories outside from current location. This change includes the git working directory as input parameter and executing git commands at the directory where the git push was originated. Also, output is logged to a file instead of display. [YOCTO #10715] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-06-14pwclient: catch patch_get_by_hash exceptionJose Lamego
An unhandled exception is raised when attempting function patch_get_by-hash if this is not available or if no corresponding patch id is found. This change catches the exception and provides a descriptive error message. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-05-04models.py: Improve Series naming when no cover letter is providedJose Lamego
The number/order prefix from a patch Subject line is inapropriately included when naming a Series where a cover letter is not provided and an additional prefix is present at the Subject. This change improves the substitution regex to omit the number/order prefix but include any other prefix that may be present. [YOCTO #11305] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-04-06parsemail.py: Improve clean_subject functionJose Lamego
PATCH prefix is not appropriately identified as such if it is not sepparated from following word in an email Subject line. This leads to wrong patch naming. This change allows for appropriate patch naming by checking during clean_subject function if "PATCH" prefix in Subject line is not sepparated from following word and adding a space between them. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-04-06parsemail.py: Improve find_series_for_mailJose Lamego
Patch Series that are sent as replies to other Series with different patch quantity are not appropriately detected as such, breaking the thread and causing missing revisions. This change improves the find_series_for_mail function to appropriately detect when a message is part of a thread by performing an additional patch-query and detecting cover letters that are replies to cover letters. [YOCTO #10959] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-28parsemail.py: Improve status-change-through-emailJose Lamego
Patch status can be edited through email by project maintainers only without any feedback if this is attempted by any other user, providing a poor user experience. This change extends the patch-status-through-email functionality to be performed by the series submitter also, and provides a system-generated message if an attempt was made through a message using an email address not recognized neither as project maintainer or series submitter in patchwork. [YOCTO #11027] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-27pagination.html: Add archive parameter to linksJose Lamego
paginator links do not include current "archive" status parameter, which may lead to inaccurate data displayed in next views. This change includes "archive" parameter from the paginator class to all of the pagination links. [YOCTO #11200] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-27patchwork/paginator.py: Add archive parameterJose Lamego
paginator links do not keep "archive" filtering parameter from current view, which may lead to inaccurate data displayed in the next views. This change adds the "archive" parameter read from the current request to the paginator class. [YOCTO #11200] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-09series.py: return bundle objects only when authenticatedJose Lamego
If a non-authenticated user tries to get a series view from patchwork web UI, a 500 error message is displayed caused by the database access attempted when filtering the bundle objects. This change allows not-logged users to acces series view by returning an empty bundle variable, instead of trying to access the database. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-08series.js: show/hide tests results section from contextJose Lamego
This change adds automatic show/hide functionality for tests results section based on view context. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-03-08series.html: add series tests results section in viewJose Lamego
This change adds series tests results section in series view. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-28patch-list: call tablecheckbox plugin from patch-listJose Lamego
This change calls the tablecheckbox.js plugin to add functionality in a patch-list to allow user to select single / multiple / all table row(s) by clicking. [YOCTO #10819] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-28jquery.tablecheckbox: add plugin for multiselect functionalityJose Lamego
Selecting multiple items in a patch list must be done manually, one item at a time, resulting in a poor user experience. This change adds the jquery.tablecheckbox.js plugin that allows to select single / multiple / all table row(s) by clicking. [YOCTO #10819] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-28series.js: support shift-select rangeJose Lamego
Selecting multiple patches in a range at the series view must be performed on one-by-one basis, providing apoor user-experience. This change allows to select patches in a range by clicking the first patch, then shift-clicking the last patch in the desired range. [YOCTO #10819] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-27series.js: add patch-selection-checkbox control functionsJose Lamego
This change adds control functions for individual and multiple selection checkboxes. [YOCTO #10822] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-27series.html: add patch and bundle edition forms and checkboxesJose Lamego
This change adds patch and bundle edition forms, and patch selection checkboxes. [YOCTO #10822] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-27series.py: add patch and bundle edition actions to viewJose Lamego
This change adds patch and bundle edition actions to the series view. [YOCTO # 10822] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-23post-receive_async: Asynchronously update merged patchesJose Lamego
This Git post-receive hook asynchronously updates Patchwork patches to "Accepted " state after Git pushes to master branch Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-22parsemail: Fix typo at prefix-compile statementJose Lamego
This change fixes a typo at the regex statement used to compile prefixes. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-21views/series: fix syntax at import statementLeonardo Sandoval
Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
2017-02-20git-pw: include bundle sub-commandLeonardo Sandoval
This new command allows to fetch bundles (set of selected patches by the user) and print them into the stdout. For the moment, bundles must be public (otherwise these wont be found) Command line example: openembedded-core$ git pw bundle newbundle --username lsandov1 Signed-off-by: Leonardo Sandoval <leonardo.sandoval.gonzalez@linux.intel.com>
2017-02-10parsemail: Split PATCH prefix if not singleJose Lamego
PATCH prefix is not appropriately identified as such if it is not sepparated from following word in an email Subject line. This leads to wrong email parsing and revisions not appended to initial series. This change allows appropriate email parsing by checking if PATCH prefix in Subject line is not sepparated from following word and adding a space between them. [YOCTO #10823] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-10parsemail: Process email with duplicated message-idJose Lamego
Current email parsing filters-out messages with a message-id that already exists in db, producing that some valid patch revisions are not processed in patchwork. This change allows for valid patches with duplicated message-id to be processed by modifying the message-id in patchwork only when email content in new message is different from that in the existing patch. [YOCTO #10756] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-10series.py: Add POST callJose Lamego
Current series view is missing a POST call, avoiding users to update or edit patch status or bundles. This change adds POST call to series view, including the target patch id, which is taken from request context. [YOCTO #10973] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-02-10series.js: Get patch id and pass it to POST requestJose Lamego
Patch forms in series view do not pass selected patch id as context element during a POST call, so no status/bundle updates can be performed from such view. This change includes the selected patch id as a context element and pass it to POST call through a hidden input field. [YOCTO #10973] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-01-25parsemail.py: Check if author.user profile existsJose Lamego
An error message is yield when attempting to check for maintainer permissions when author.user attribute returns a None value. This change verifies that author user attribute exists before proceeding with further checks. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-01-24parsemail: Set patch state from email metadataJose Lamego
Patch state can only be set/changed at patchwork web interface, resulting in a poor user experience for project maintainers. This change allows project maintainers to change a patch status directly from an email message sent as a reply to the related mailing list thread by including a the string "[Patchwork-Status: <new status>]" [YOCTO #10624] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-01-16series.html: Include toggle_headers scriptJose Lamego
Email headers show/view link is not functional when displaying patch email content at series view due to the missing required script. This change includes the toggle_headers script in the series page. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-01-16parsemail.py: Improve new patch filteringJose Lamego
Patchwork may incorrectly identify emails containing patch-like content or that are replies/forwards from a previous message as patches, thus wrongly creating a new series revision. This change makes "[PATCH" prefix in subject mandatory for emails to be considered as possible new patches, and makes any email with a subject starting with any character other than a square bracket ("[") to be handled as a possible comment to an existing patch. [YOCTO #10764] [YOCTO #10877] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2017-01-06patchwork/templates/patchwork/series: Improve series viewJose Lamego
Reviewing patches from a series requires heavy usage of the browser navigation buttons, providing a poor UX. This changes allows viewing content from each patch in a series, without leaving the series view. [YOCTO #10627] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-12-07patchwork.models: Include first patch's name in series nameJose Lamego
Patch Series created without a cover letter are named using a non-descriptive generic string. This change names the series using either the first 30 characters in patch #1 plus the remaining patches number, or the patch name for one-patch (1/1) series. [YOCTO #10625] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-11-25README: Describe repository and linksJose Lamego
This change creates the README file with repository description and links. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-11-24patchwork.bin.parsemail: Improve pull-request regexJose Lamego
Some patch messages containinig pull-request information are being skipped due to formatting variations. This change improves the pull-request search to include those small variants. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-11-24patchwork.bin.parsemail: Use oldest header referencesJose Lamego
References list for previous emails only include first found header, causing that some root messages for series are skipped and corresponding series revision numbering gets corrupted. This change forces references list to use last header found, allowing for Patch emails created with send-pull-request script to be appropriately appended to last revision. [Yocto #9941] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-11-07Patchwork: adds revision number to PW email2016-11Jose Lamego
Revision number should be displayed on every email sent by Patchwork so patch/patches can be easily detected and, if aplicable, corrected by the owner. This patch adds the revision number to the body of such email. [YOCTO #10064] Signed-off-by: Daniela Plascencia <daniela.plascencia@intel.com>
2016-09-23parsemail: Allow new series with pull-request messagesJose Lamego
Series are not properly created in projects that do not allow patches submitted with git pull request utility for this purpose. This change allows such method for projects that are not set as git_send_email_only. Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-09-23test_series.py: Check series-new-revision events for new revisionsJose Lamego
When a new revision is created, patch-state-change events will also be generated for superseded patches, so comparing total events created in log with total revisions will give false results. This change makes the test to check that the appropriate quantity of series-new-revision events were created per revision. [Yocto 7654] [Issue #61] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-09-23models.py: Mark patches as superseded when receiving a new revisionJose Lamego
When a new revision for a patch is received in Patchwork, the earlier patch remains in New state, without any mention that there is a newer revision unless a manual update is performed, resulting in wrong metrics and poor UX. With this change, after any new revision is completed, a search in previous revision for patches with same name as the latest is performed, to mark them as Superseded and add a comment with the update reason. [Yocto 7654] [Patchwork #61] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-09-23docs/requirements-dev.txt: require django-debug-toolbar ver. 1.4Jose Lamego
django-debug-toolbar version 1.5 requires django 1.8+, thus producting an error with current dev-environment configuration. This fix requires version 1.4 to be used instead. [ISSUE #198] Signed-off-by: Jose Lamego <jose.a.lamego@linux.intel.com>
2016-07-19patch: Make the /patch/msgid/ view resilient to duplicate msgidsDamien Lespiau
In case of cross posting on mailing-lists handled by patchwork we have duplicated msgids in the DB. So we need to make a choice when asked for the patch with a give msgid. Otherwise: Internal Server Error: /patch/msgid/1461691808-12414-20-git-send-email-daniel.vetter@ffwll.ch/ Traceback (most recent call last): File "django/core/handlers/base.py", line 132, in get_response response = wrapped_callback(request, *callback_args, **callback_kwargs) File "patchwork/views/patch.py", line 128, in msgid patch = get_object_or_404(Patch, msgid='<' + msgid + '>') File "shortcuts.py", line 155, in get_object_or_404 return queryset.get(*args, **kwargs) File "django/db/models/query.py", line 338, in get (self.model._meta.object_name, num) MultipleObjectsReturned: get() returned more than one Patch -- it returned 2! Signed-off-by: Damien Lespiau <damien.lespiau@intel.com>