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

🐞 Dagger Publish Does Not Work with Tags #7161

Open
levlaz opened this issue Apr 23, 2024 · 3 comments
Open

🐞 Dagger Publish Does Not Work with Tags #7161

levlaz opened this issue Apr 23, 2024 · 3 comments
Labels
kind/bug Something isn't working

Comments

@levlaz
Copy link
Contributor

levlaz commented Apr 23, 2024

What is the issue?

The dagger publish command does not work as expected when you are working with git tags and puts the daggerverse into a strange state.

Here is what I expect.

Running dagger publish or dagger publish $TAG inside of a dagger module should publish the latest tag into the daggerverse.

Here is what happens.

  1. If I run dagger publish it will publish the most recent commit and even find the correct git tag that shows up in the daggerverse UI. But trying to go to https://daggerverse.dev/mod/github.com/levlaz/daggerverse/module@$TAG results in a 404.

  2. If I run dagger publish $TAG it will publish the most recent commit and even find the correct git tag that shows up in the daggerverse UI. But trying to go to https://daggerverse.dev/mod/github.com/levlaz/daggerverse/module@$TAG results in a screen that says "uploading module" forever.

The only way to get my module to show up properly at https://daggerverse.dev/mod/github.com/levlaz/daggerverse/module@$TAG is to go through the publish process manually via the daggerverse UI.

You can see this bug live here: https://www.youtube.com/live/1M0sNwMjFLE?si=M-BiNAVj2W-xT0e3&t=1560

Dagger version

0.11.1

Steps to reproduce

No response

Log output

No response

@levlaz levlaz added the kind/bug Something isn't working label Apr 23, 2024
@jpadams
Copy link
Contributor

jpadams commented Apr 23, 2024

This was a result of a change that was made some time back to make Daggerverse URLs only really support full git shas -- with only two ways to get to a url with a full sha:

  1. Full sha: https://daggerverse.dev/mod/github.com/levlaz/daggerverse/novu@56559412d83814e93eb6444608119f03e5c1dec7
  2. No sha: https://daggerverse.dev/mod/github.com/levlaz/daggerverse/novu -> https://daggerverse.dev/mod/github.com/levlaz/daggerverse/novu@56559412d83814e93eb6444608119f03e5c1dec7 becuase that is the sha of the latest tag (or would go to the chronologically latest sha if no tags)

There is an internal issue expressing the sentiment that any reasonable ref should be supported in the URL/location bar of the browser, but we haven't decided to act on that yet. https://linear.app/dagger/issue/DEV-3494

It does seem that sometimes a ref like https://daggerverse.dev/mod/github.com/levlaz/daggerverse/[email protected] will work and redirect to the sha version, but in some other cases it does not. Need to understand why and make the behavior consistent.

@sagikazarmark
Copy link
Contributor

Here is a module I just published: https://daggerverse.dev/mod/github.com/sagikazarmark/daggerverse/kustomize@833905febeb1c77937712dd9f69a2c85898c74d9

I'm starting to think the issue is caused by modules that were published prior to having any tags.

In the above case I immediately tagged the module after creating it and it showed up as a tagged module.

@aweris
Copy link
Contributor

aweris commented Apr 28, 2024

I was looking the same thing and ➗ to what @sagikazarmark said. I added a CI/CD workflow to publish my modules, and when I use a tag trigger to publish, it is able to detect the tag.

Workflow: https://github.com/aweris/daggerverse/actions/runs/8867226311/workflow
Module: [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants