Page Menu
Home
Software Heritage
Search
Configure Global Search
Log In
Files
F9346767
D5661.id20221.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Flag For Later
Size
1 KB
Subscribers
None
D5661.id20221.diff
View Options
diff --git a/swh/web/common/origin_save.py b/swh/web/common/origin_save.py
--- a/swh/web/common/origin_save.py
+++ b/swh/web/common/origin_save.py
@@ -378,7 +378,6 @@
"""
_check_visit_type_savable(visit_type)
_check_origin_url_valid(origin_url)
- _check_origin_exists(origin_url)
# if all checks passed so far, we can try and save the origin
save_request_status = can_save_origin(origin_url, bypass_pending_review)
task = None
diff --git a/swh/web/tests/admin/test_origin_save.py b/swh/web/tests/admin/test_origin_save.py
--- a/swh/web/tests/admin/test_origin_save.py
+++ b/swh/web/tests/admin/test_origin_save.py
@@ -122,7 +122,6 @@
def test_accept_pending_save_request(client, mocker):
mock_scheduler = mocker.patch("swh.web.common.origin_save.scheduler")
- mock_origin_exists = mocker.patch("swh.web.common.origin_save._check_origin_exists")
visit_type = "git"
origin_url = "https://v2.pikacode.com/bthate/botlib.git"
save_request_url = reverse(
@@ -131,7 +130,6 @@
)
response = check_http_post_response(client, save_request_url, status_code=200)
assert response.data["save_request_status"] == SAVE_REQUEST_PENDING
- assert mock_origin_exists.called
accept_request_url = reverse(
"admin-origin-save-request-accept",
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Thu, Jul 3, 4:26 PM (2 w, 4 d ago)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
3231054
Attached To
D5661: Save code now: Do not check origins for existence
Event Timeline
Log In to Comment