Giter Club home page Giter Club logo

checkmate's People

Contributors

roryq avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

alex3236

checkmate's Issues

Check fails when PR comment edited

Log:

Reading Config From Inputs
Config: checkmate.Config{
    PathsChecklists: {
        "test/**": {"test1", "test2"},
    },
    Preamble: "## Test\nChecklist test",
}
panic: interface conversion: interface {} is nil, not map[string]interface {}

goroutine 1 [running]:
github.com/roryq/checkmate/pkg/pullrequest.getPRNumber(...)
	/home/runner/work/checkmate/checkmate/pkg/pullrequest/client.go:93
github.com/roryq/checkmate/pkg/pullrequest.NewClient(0xc000093e90?, 0xc0000d5900)
	/home/runner/work/checkmate/checkmate/pkg/pullrequest/client.go:79 +0x30f
github.com/roryq/checkmate/pkg/checkmate.Run({0x87c7b0, 0xc000096000}, 0xc00009a738, 0xc0000a8360?, 0x7f15feee43b8?)
	/home/runner/work/checkmate/checkmate/pkg/checkmate/action.go:20 +0x86
main.run()
	/home/runner/work/checkmate/checkmate/main.go:33 +0xed
main.main()
	/home/runner/work/checkmate/checkmate/main.go:37 +0x[19]

Workflow:

on:
  pull_request:
    types: [edited, opened, reopened, synchronize]
    paths:
      - test/**
  issue_comment:

name: Checklist
jobs:
  validate-checklists:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3
      - name: Validate Checklists
        uses: roryq/checkmate@master
        with:
          github_token: ${{ secrets.GITHUB_TOKEN }}
          preamble: |
            ## Test
            Checklist test
          paths: |
            test/**:
              - test1
              - test2

Check still fails when PR comment edited

panic: interface conversion: interface {} is nil, not map[string]interface {}

goroutine 1 [running]:
github.com/roryq/checkmate/pkg/checkmate.getPullRequestBody(...)
	/home/runner/work/checkmate/checkmate/pkg/checkmate/action.go:75
github.com/roryq/checkmate/pkg/checkmate.Run({0x87f3f0, 0xc000096000}, 0xc00009a738, 0xc0000a8360?, 0x7effe06e63b8?)
	/home/runner/work/checkmate/checkmate/pkg/checkmate/action.go:39 +0x[44](https://github.com/alex3236/test/actions/runs/4259534064/jobs/7411846810#step:3:45)b
main.run()
	/home/runner/work/checkmate/checkmate/main.go:33 +0xed
main.main()
	/home/runner/work/checkmate/checkmate/main.go:37 +0x19

Workflow is still the same as mentioned in #13
Seems that it can't get the pull request body for checking :(

Workflow result not show on PR when triggered by comments

The action runs triggered from the comments on PRs are not reporting back to the originating PR, so the PR check status doesn’t change as it is only connected to the first run or when there is any change on the PR description or code.

Fetch latest data instead of processing event data

Toggling multiple checkboxes quickly will only trigger one workflow job, which potentially causes a false failure due to processing the older state in the payload.

Need to update the tests to mock the api and then fetch for the latest state for each invocation.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.