Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generic package from registry can't be extracted #490

Closed
paulojmdias opened this issue Jan 31, 2023 · 3 comments · Fixed by #491
Closed

Generic package from registry can't be extracted #490

paulojmdias opened this issue Jan 31, 2023 · 3 comments · Fixed by #491
Labels

Comments

@paulojmdias
Copy link

Hi everyone 👋

I'm using GitLab registry to push an asset with the format gzip compressed data (.tar.gz) but when I download the uploaded package, I can't decompress it.

Follow my .releaserc.yml

branches:
  - "main"
plugins:
  - "@semantic-release/commit-analyzer"
  - "@semantic-release/release-notes-generator"
  - - "@semantic-release/exec"
    - verifyConditionsCmd: 'tar -czf package.tar.gz --exclude=".git*" --exclude="__pycache__" aws/'
  - - "@semantic-release/gitlab"
    - assets:
        - path: "package.tar.gz"
          filepath: "/package.tar.gz"
          label: "package.tar.gz"
          target: generic_package
          status: default
tagFormat: ${version}

If we do a cat to the package file, we will see weird data on top and at the end of the file.

❯ cat package.tar.gz
----------------------------636039438515691214353669
Content-Disposition: form-data; name="file"; filename="aws.tar.gz"
Content-Type: application/gzip

<REDACTED BINARY DATA>
----------------------------636039438515691214353669--

If we remove the first 4 files from the file with the command sed -e '1,4d' < package.tar.gz > package2.tar.gz, we will decompress it.

If we compress the file manually, upload it, and download it after we can decompress it since the data are been untouched.

Can someone give any insight?

@fgreinacher
Copy link
Contributor

Thanks for the detailed report!

@JonasSchubert This seems to be related to #343. Could you have a look?

@JonasSchubert
Copy link
Contributor

Thanks for the detailed report!

@JonasSchubert This seems to be related to #343. Could you have a look?

Will do

JonasSchubert added a commit to JonasSchubert/gitlab that referenced this issue Feb 1, 2023
JonasSchubert added a commit to JonasSchubert/gitlab that referenced this issue Feb 2, 2023
fgreinacher pushed a commit that referenced this issue Feb 2, 2023
Fixes #490 

Co-authored-by: Jonas Schubert <jonas.schubert@siemens.com>
@github-actions
Copy link

github-actions bot commented Feb 2, 2023

🎉 This issue has been resolved in version 10.1.3 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants