pull icon indicating copy to clipboard operation
pull copied to clipboard

How to validate and use this app?

Open matthew-carroll opened this issue 1 year ago • 2 comments

Hi, I've tried following the README instructions as best I can to use this app, but I seem to be unable to either validate my pull.yml, nor generate and merge an update PR.

The repo where I'm trying to run this app is here: https://github.com/Flutter-Foundation/flutter/tree/upstream_sync

The upstream repo I'm trying to sync with is here: https://github.com/flutter/flutter

Following the README instructions, I created a new default branch. In my case I called it upstream_sync. There, I added the following pull.yml: https://github.com/Flutter-Foundation/flutter/blob/upstream_sync/.github/pull.yml

I tried validating my configuration with: https://pull-validation-uxx737qt0sl1.runkit.sh/?url=https://raw.githubusercontent.com/Flutter-Foundation/flutter/refs/heads/upstream_sync/.github/pull.yml

The result is:

{
  "error": "initialization_error",
  "message": "There was an error initalizing your endpoint."
}

Given I couldn't seem to validate the configuration, I then tried to run the app to see what happens. Based on README instructions, I navigated to: https://pull.git.ci/process/Flutter-Foundation/flutter

At that address, the page simply reads "Success". However, no PR was created in my repo, and no PR was merged.

At this point I'm unsure what else to try.

Additionally, assuming that I'm able to get the app to create and merge update PRs, how can I setup the app to do this once per day?

matthew-carroll avatar Oct 01 '24 22:10 matthew-carroll

Hi @matthew-carroll thanks for opening the issue.

It appears runkit has changed some things on their end, I have created a new endpoint that can be used to validate any configuration: https://eoe2bl0x7c3h05e.m.pipedream.net/?url=https://raw.githubusercontent.com/Flutter-Foundation/flutter/refs/heads/upstream_sync/.github/pull.yml

The process endpoint currently adds the job to the queue but depending on the number of jobs currently there, it could take a while to get to, also if there are permission issues with your GitHub installation, it will fail silently. This is planned to be updated for 2.0.

There is currently not a way to schedule once per day, pull will get to it whenever it gets to it. Scheduling is on our roadmap for Pull 2.0.

wei avatar Oct 03 '24 00:10 wei

Thanks @wei - until you're able to get to scheduling, do you have any advice or references for those of us who need to write a GitHub app to keep an upstream source sync'ing with a fork on a recurring basis?

I'm also curious, I came to Pull because I discovered that when trying to merge upstream into a fork using a Workflow Action (on a cron job schedule), you can't actually merge the PR if the upstream changes includes any alteration to other Workflow files. Do you know if GitHub apps like Pull are able to merge such PRs automatically, despite the changes to Workflow files?

matthew-carroll avatar Oct 03 '24 03:10 matthew-carroll

Hello @matthew-carroll I am happy to announce that Pull 2.0 is in soft launch right now. This includes a much more reliable scheduling system which guarantees at least once per day at the moment (I plan to increase the frequency and allow for custom scheduling down the line).

If you'd like to give it another go, once installed you should be able to use the https://pull.git.ci/check/Flutter-Foundation/flutter endpoint to validate the config directly and the https://pull.git.ci/process/Flutter-Foundation/flutter endpoint to trigger it on-demand.

Feedback welcome!

wei avatar Nov 18 '24 05:11 wei

Thanks for letting me know. For the moment, we've taken a significantly different approach to sync'ing our fork. If we end up in a position that can utilize the approach of this app, we'll try it again.

matthew-carroll avatar Nov 19 '24 01:11 matthew-carroll

Sounds great! Much appreciated.

wei avatar Nov 19 '24 01:11 wei