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

Rework pipeline messages #4626

Draft
wants to merge 36 commits into
base: main
Choose a base branch
from
Draft

Conversation

qwerty287
Copy link
Contributor

@qwerty287 qwerty287 commented Dec 27, 2024

supersedes #3421
closes #2971
closes #4677

Currently, our pipeline model has fields like the message, title etc., but every field is used differently, dependending on the event.

This PR changes this and splits these reused fields to have a more clear pipeline model.

The model now has fields like:

  • commit (containing sha, author, forge url and message)
  • pull request (index, title, from fork, labels)
  • release title

and similar.

Advantages:

  1. cleaner model and less differently used fields
  2. fix the problem that there is a difference between commit and pipeline author (pipeline author = pusher) Environment Variable CI_COMMIT_AUTHOR_EMAIL is wrong #2971
  3. store and show the commit message for every pipeline
  4. store and show the context of a pipeline (PR title, deployment target, release title etc.) and show it

Especially 3 and 4 and are the enhancement parts here, as we can now store both context and commit message and not only one.

new UI for a PR:
grafik

TODO

@qwerty287 qwerty287 added the refactor delete or replace old code label Dec 27, 2024
@qwerty287 qwerty287 added the breaking will break existing installations if no manual action happens label Jan 5, 2025
@pat-s
Copy link
Contributor

pat-s commented Jan 6, 2025

@qwerty287 Why is that breaking? Because of the env var change?

@qwerty287
Copy link
Contributor Author

Yes, env var change and it also changes the json for the pipeline model

@woodpecker-bot
Copy link
Contributor

woodpecker-bot commented Jan 11, 2025

Deployment of preview was successful: https://woodpecker-ci-woodpecker-pr-4626.surge.sh

@qwerty287
Copy link
Contributor Author

@woodpecker-ci/maintainers somebody has an idea how to fix the DB tests? https://ci.woodpecker-ci.org/repos/3780/pipeline/24869/38

Besides that, this PR can get first reviews. It still needs testing and the UI is probably not the best.

Also, there are some todos, especially in the bitbucket code. Maybe @langecode you can check this out?

@xoxys
Copy link
Member

xoxys commented Jan 11, 2025

Can you add a bit more context about what has changed and how it fixes the linked issue? IMO it helps to provide a more detailed PR description in addition to the code.

@qwerty287
Copy link
Contributor Author

@xoxys updated the description

@xoxys
Copy link
Member

xoxys commented Jan 11, 2025

Thank you! ❤️

@xoxys
Copy link
Member

xoxys commented Jan 17, 2025

Will finally take a look this evening.

@xoxys

This comment was marked as resolved.

@xoxys
Copy link
Member

xoxys commented Jan 17, 2025

image

I would stick to a two line layout, even if the second line would be empty. The pipeline id is not show for me.

@qwerty287
Copy link
Contributor Author

I would stick to a two line layout, even if the second line would be empty.

I'm not sure if I'd do this.

grafik

This looks kinda weird.

The pipeline id is not show for me.

This is very weird, as it seems to be a problem in the migration. However, I couldn't find the bug in the code, everything seems correct…

@xoxys
Copy link
Member

xoxys commented Jan 19, 2025

I'm not sure if I'd do this.

True. But I would prefer to not change the layout depending on the event. Ill try to find another approach if not Im also fine with the current way.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
breaking will break existing installations if no manual action happens refactor delete or replace old code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

tag pipelines are missing avatar and commit title Environment Variable CI_COMMIT_AUTHOR_EMAIL is wrong
4 participants