- Nov 22, 2022
-
-
Antoine Lambert authored
-
- Nov 21, 2022
-
-
Antoine Lambert authored
Private repositories cannot be cloned without authentication so we cannot create save requests for those. So return an HTTP 400 error code when receiving push webhooks for such repositories and inform users about the fact they cannot be publicly cloned. Related to T4548
-
Antoine Lambert authored
Previously, github webhook receiver was returning a 400 HTTP error code for a ping event which can be confusing for users so ensure to return a 200 HTTP code. Related to T4548
-
Antoine Lambert authored
Notably bump cypress to 11.0.1 (11.1.0 makes test hang on Jenkins so we cannot upgrade to latest version yet) and cy2 to 3.2.0.
-
- Nov 16, 2022
-
-
Antoine Lambert authored
It breaks parallel tests on Jenkins so revert that upgrade until finding a fix.
-
Antoine Lambert authored
-
Antoine Lambert authored
Increase first column width in tables of endpoints list page. Add ids to endpoint sections and links to the sections in top of that page. Use absolute URL in specific endpoint documentation (to ease copy paste).
-
Antoine Lambert authored
Previously, the save code now service was not allowing to create a new request for an origin if a previously created one for the same origin was currently running. However, new commits might have been pushed to the origin while a loading task is running so this restriction does not make sense, especially for the new forge webhook receivers feature. Related to T4548
-
- Nov 15, 2022
-
-
Antoine Lambert authored
Previously the snapshot releases view was only displaying the releases names and not the branches names targeting those. But it exist cases where multiple branches target the same release in a snapshot so also display branches names in the releases table in order to avoid confusion about duplicated releases. Related to T4686
-
vlorentz authored
The 'fields' query parameter is used by clients to indicate what fields the API should return. If 'metadata' is not in that field, then the 'metadata' object will be discarded by apiresponse, so the call to `idx_storage.origin_intrinsic_metadata_get` is useless. I expect no client actually uses this field, so this could save ressources. Additionally, I want to deprecate the field, so this may make it easier to figure if any client actually requests it by looking at server logs.
-
vlorentz authored
This is needed, because swh-search may now return results based on extrinsic metadata, in addition to intrinsic metadata. I do not want to query idx_storage.origin_extrinsic_metadata here, because it is not clear how to merge with the existing data structure. Additionally, I do not think anyone relies on the metadata returned by this endpoint because it is undocumented and rather inflexible. Instead, I would like to deprecate returning metadata from this endpoint altogether, as there is a more appropriate endpoint to get metadata once you have the origin URL.
-
- Nov 14, 2022
-
-
Antoine Lambert authored
Instead of manually setting some HTTP headers, prefer to use django FileResponse class that set those. It fixes the download of raw files with non ascii filenames.
-
- Nov 09, 2022
-
-
Antoine Lambert authored
-
Antoine Lambert authored
When an origin URL is provided as URL argument to a Web API call performed by XHR, only percent encode the '?' character as using encodeURIComponent results in a 404 error in production and staging otherwise (maybe a side effect of Varnish cache). Related to T4675
-
- Nov 08, 2022
-
-
Antoine Lambert authored
-
Antoine Lambert authored
Move tests folder related to a django application from the swh/web/tests folder into the application folder for commodity of use. Remove some no longer used test data files.
-
Antoine Lambert authored
In the origins search Web UI, XHRs are sent client side to get the visit type and status for each found origin. However origin URLs used as Web API URL arguments were not encoded which could result in request errors when an origin URL contain a '?' character for instance. So ensure to encode those origin URLs used as Web API URL arguments.
-
Antoine Lambert authored
Content type sent by django test client on debian buster is equal to 'application/json; charset=None' so tests were failing.
-
- Nov 07, 2022
-
-
Antoine Lambert authored
-
- Nov 04, 2022
-
-
Antoine Lambert authored
It exist cases where the vault_cooking template variable is set to None (when browsing a snapshot branch targeting a content for instance), so ensure to prevent VariableDoesNotExist exception thrown by django in debug mode as it generates noise in debug output.
-
Antoine Lambert authored
Previously, the snapshot branches list view was only displaying branches targeting revisions but it now exists cases where branches can target contents or directories. So update view implementation to display all type of branches and add visual clues to indicate which object types they are targeting. Related to T4669
-
Antoine Lambert authored
Previously swh-web was only supporting the browsing of snapshot branches targeting revisions but we recently introduced new Software Heritage loaders producing snapshots whose branches target contents or directories but no revisions. So add support to browse such snapshots as previously they were flagged as empty when trying to display them. Related to T4669
-
- Nov 03, 2022
-
-
Antoine Lambert authored
Make that class instantiable in order for each swh django application to manage its related Web API URLs independently from the swh.web.api django application. It also simplifies initialization of applications as their ordering does not matter anymore but also improves tests related to URLs registration of an application. Also add typing to UrlsIndex class.
-
- Nov 02, 2022
-
-
Antoine Lambert authored
Add new Web API endpoints accepting only POST requests coming from push webhooks of the following popular forges or their instances: - Bitbucket - Gitea - GitHub - GitLab - SourceForge There is one API endpoint per forge type enabling to request or update the archival of a repository when new commits are pushed to it through the Save Code Now service. Each endpoint simply processes the webhook JSON payload sent by a forge in order to extract the repository URL and the visit type in order to create a new save request for the repository. Related to T4548
-
- Oct 31, 2022
-
-
Antoine Lambert authored
Previous URLs targetting endpoints documentation were in the form /1/<endpoint_route> while they should have been in the form /api/1/<endpoint_route> so fix them and add redirections from old URLs for backward compatibility. Breadcrumbs located in the top left part of Web API endpoint doc could contain links to non existent endpoints so ensure to remove those and render spans instead.
-
- Oct 28, 2022
-
-
Antoine Lambert authored
It improves rendering of Web API HTML documentation.
-
- Oct 26, 2022
-
-
Antoine Lambert authored
-
Antoine Lambert authored
-
Antoine Lambert authored
Some exception texts like the RemoteException ones were not correctly rendered in HTML error page as they were not escaped.
-
Antoine Lambert authored
-
- Oct 19, 2022
-
-
Antoine Lambert authored
This type of exception should not be reported to sentry as it is expected.
-
Antoine Lambert authored
-
Antoine Lambert authored
This should prevent a race condition when multiple cypress processes process default support file paths in parallel that sometimes make support file fails to load and triggers errors when running tests.
-
- Oct 18, 2022
-
-
David Douard authored
- pre-commit from 4.1.0 to 4.3.0, - codespell from 2.2.1 to 2.2.2, - black from 22.3.0 to 22.10.0 and - flake8 from 4.0.1 to 5.0.4. Also freeze flake8 dependencies. Also change flake8's repo config to github (the gitlab mirror being outdated).
-
- Oct 12, 2022
-
-
Antoine Lambert authored
-
Antoine Lambert authored
-
Antoine Lambert authored
Add the following origin types for new listers/loaders currently in development: conda, cpan, puppet and rubygems.
-
- Sep 28, 2022
-
-
Antoine Lambert authored
-
Antoine Lambert authored
In public requests table and moderation one, add a link to search for origins loaded from a forge once request status is FIRST_ORIGIN_LOADED. Also add a more visual link to navigate to request moderation page in requests moderation table. Related to T4552
-