-
Bug
-
Resolution: Done-Errata
-
Minor
-
6.10.0
-
0
-
False
-
-
False
-
VERIFIED
-
0
-
Phoenix
-
-
-
Sprint 126, Sprint 127, Sprint 128, Sprint 129, Sprint 130, Sprint 131
-
Low
-
None
Description of problem:
- When using Hammer to sync a repository, the option --source-url is not used for the sync, it will use existing url.
- However, when I pass --source-url on a repo with no existing url, it will try and sync, not giving a hammer error,
and will fail with HTTP 400: Server Error for no remote.
Version-Release number of selected component (if applicable):
6.10 and up
Reproduced on 6.15.0 snap 36.0
How reproducible:
Every time
Steps to Reproduce:
1. Create some repository with no upstream_url defined. (--url in hammer).
2. >> hammer repository synchronize --id
3. Add a valid url to the repository field upstream_url (--url in hammer).
4. >> hammer repository synchronize --id {repo_id}
--source-url
{some_other_valid_url}Actual results:
2: Unsuccessful sync, does not use --source_url, gives 400 error that there is no remote (See Additional details).
4: The repository is synced to the existing url, instead of respecting the temporary --source-url passed.
Expected results:
Successful sync to the temporary '--source-url' passed in 'hammer repository synchronize'.
Or we can drop references to '--source-url', if we do not plan to support it.
Additional details:
-
-
- When synchronizing a repository that has no existing url, and passed --source-url:
-
[root@HOST ~]# hammer repository synchronize --id 362 --source-url "https://partha.fedorapeople.org/test-repos/pteradactyl/"
[................................................................................................................] [100%]
Error: Error message: the server returns an error
HTTP status code: 400
Response headers:
Response body:
{"remote":["This field is required since a remote is not set on the repository."]}^^ Instead, would expect source_url to be used for sync, or a hammer error like-
""" Could not synchronize the repository:
attempted to sync without a feed URL. """
-
-
- When synchronizing a repository that has an existing url that was already synced,
perform sync again passing a different --source-url:
- When synchronizing a repository that has an existing url that was already synced,
-
[root@HOST ~]# hammer repository synchronize --id 363 --source-url "https://partha.fedorapeople.org/test-repos/pteradactyl/"
[................................................................................................................] [100%]
No content added.
Total steps: 1/1
--------------------------------
Skipping Sync (no change from previous sync): 1/1
- external trackers
- links to
-
RHBA-2024:140284 Important: Satellite 6.16.0 release