openSUSE / obs-service-download_files

An OBS source service: download files
GNU General Public License v2.0
8 stars 23 forks source link

Downloaded filename wrong #40

Open hramrach opened 1 year ago

hramrach commented 1 year ago

When I run osc service run download_files in a package that specifies source-1.0.0.tar.gz as source I get _service:download_files:source-1.0.0.tar.gz. I cannot build the package, it's broken.

tacerus commented 1 year ago

I encounter this as well.

dirkmueller commented 11 months ago

I can not reproduce. is this still an issue? which version? I have 0.9.2

tacerus commented 11 months ago

Hi @dirkmueller,

example .spec contents:

...
Source:         https://files.pythonhosted.org/packages/source/r/requests-oauthlib/requests-oauthlib-%{version}.tar.gz
...
%setup -q -n requests-oauthlib-%{version}
...

If I recall correctly, the issue is with using

<service name="download_files" mode="disabled">

in _service - when running osc service run -v download_files it places a file

_service:download_files:requests-oauthlib-1.3.1.tar.gz

which it deletes during a osc build --local-package - and also the build fails with

[    5s] + /usr/lib/rpm/rpmuncompress -x /home/abuild/rpmbuild/SOURCES/requests-oauthlib-1.3.1.tar.gz
[    5s] error: File /home/abuild/rpmbuild/SOURCES/requests-oauthlib-1.3.1.tar.gz: No such file or directory

if on the other hand

<service name="download_files" mode="localonly">

is used, the file _service:download_files:requests-oauthlib-1.3.1.tar.gz is replaced with requests-oauthlib-1.3.1.tar.gz upon calling osc build ..., and the build succeeds.

Edit: I have obs-service-download_files-0.9.2-1.2.noarch installed.