-
Notifications
You must be signed in to change notification settings - Fork 61
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
Fetch Metadata action returns null update-type output for pull requests #339
Comments
Can you link to the If it's not public, it's hard for us to diagnose, you'd need to run the action locally yourself and step through to figure out why it's breaking. Or create a super simple repo that triggers a See also #338, which just landed and hasn't been released yet, may be a potential cause. |
Alternatively, you can extract and attach the patch as it will probably include everything we need to start debugging You can get it adding Example : https://patch-diff.githubusercontent.com/raw/dependabot/fetch-metadata/pull/278.patch |
The version bump dependabot is trying is actually fairly simple:
One thing I might have missed when creating the issue is that this version bump is attempted before a poetry.lock file is created. Could that be the issue? |
Would it be possible to share the workflow logs as well? |
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
This comment was marked as outdated.
I apologize I posted the wrong log file. The log below pertains to the same action, but with null metadata.
|
Is there anything else I can supply to make the debugging process easier? |
A Reproducer would be ideal, but I don't know if you'll be able to set that up Where a Reproducer is a public repository that shows the same problem |
We are seeing this as well for internal Docker image update tags (either incoming or outgoing) have a prefixing We have tried every variant of this and we have found (using internal docker builds) the following:
While it is true that this sort of tag is not strictly semver compliant, I would expect Dependabot to be able to infer this sort of thing with a non-complex tag. I did just create an issue in Dependabot Core but I looked here to see this and thought it was out issue so I closed it. |
This does not seem to be just an
This action extracts versions from the default commit message, but your custom configuration looks like it removes the versions or changes the format here. commit-message:
prefix: "build: "
prefix-development: "build: "
include: "scope"
fetch-metadata/src/dependabot/update_metadata.ts Lines 30 to 32 in d1defa4
(But I also don't fully understand what https://github.com/dependabot/dependabot-core/blob/8fee559e211d8292aad095256e300d02d9ba451f/common/lib/dependabot/pull_request_creator/message_builder.rb#L151 does either.) As I understand it, there is no perfect solution for deciding the versions from the commit message with providing the user customization feature. But I think by providing fixed metadata fields in all commit messages with the dependabot-core, the parser could be made simpler and more stable. |
This is a reproducible PR haoliangyu/dependabot-minor-version-update-demo#1 for this problem. The workflow run is here. It was initially used to test a bug in fastify/github-action-merge-dependabot and that bug originates from this issue. If you check the workflow run raw log, you can see
This is the initial state of the repo https://github.com/haoliangyu/dependabot-minor-version-update-demo/tree/4ceb6428814f98a70bc836537eebe21558fbdf5f if you want to setup your test. |
I have added this test on my local, using the commit message from the above PR, and it doesn't set the update-type correctly:
To fix it, we could change the |
I started having this issue when I started using the grouped updates feature on some of my private repositories and on a public repository today.
|
Description
I am using the
dependabot/fetch-metadata
action (v1.3.6) in my workflow to handle Dependabot pull requests. However, I am encountering an issue where theupdate-type
output is returning null, even though the pull request is created by Dependabot.Repository Configuration
Here's the
dependabot.yml
configuration for the repository:The pyproject.toml file is located in the /dependabot/ directory, which is specified in the dependabot.yml configuration
Workflow Configuration
The following is the configuration for the workflow that uses the dependabot/fetch-metadata action:
Issue Details
When the workflow runs for a pull request created by Dependabot, the action returns a null update-type output, which causes issues in the subsequent steps that rely on this output.
Here's an example of the outputs returned by the dependabot/fetch-metadata action:
The issue persists even after verifying that the pull request is created by Dependabot and that the workflow is triggered by the correct event (pull_request_target with opened and synchronize types).
Request for Assistance
I would appreciate any help in diagnosing and resolving this issue. If there's any additional information or logs that would be useful, please let me know, and I will provide them.
The text was updated successfully, but these errors were encountered: