Agent panic 0.8.0

I’ve encountered an agent panic that leaves a builds waiting:

9/28/2017 10:10:17 AMgoroutine 10 [running]:
9/28/2017 10:10:17 AMmain.(*runner).run(0xc4201ef7c0, 0xbbace0, 0xc4201ef780, 0x0, 0x0)
9/28/2017 10:10:17 AM	/go/src/github.com/drone/drone/cmd/drone-agent/agent.go:163 +0x170d
9/28/2017 10:10:17 AMmain.loop.func2(0xc420298fc0, 0xc420298f70, 0xbbd240, 0xc420266f00, 0xc4201b98f0, 0x0, 0x0, 0xc420298f10, 0xc420298f80)
9/28/2017 10:10:17 AM	/go/src/github.com/drone/drone/cmd/drone-agent/agent.go:113 +0x193
9/28/2017 10:10:17 AMcreated by main.loop
9/28/2017 10:10:17 AM	/go/src/github.com/drone/drone/cmd/drone-agent/agent.go:118 +0x86e

It seems to be when a build is triggered, but the .drone.yml file doesn’t have any work to do.
The below is the .drone.yml I can reproduce this with. Taking out the clone step or taking out the when clause on the clone step will result in successful builds.

clone:
  clone:
    image: plugins/git
    recursive: true
    when:
      event: push
      branch: master

pipeline:
  build:
    image: golang:1.8
    commands:
      - echo "success"
    when:
      event: push
      branch: master

I’m not sure if selectively running the clone step in this way is supported, but it always worked in the past.
Our projects are large and I don’t currently want to trigger any kind of build unless it’s a PR merge (e.g. push to master).

Even so, I guess this should fail more gracefully.

Having a quick look at the code, it looks like it’s crashing in agent.go:extractRepositoryName as the work.Config struct doesn’t appear to have the correct information (presumably as there are no steps) and so the array indexing is out of bounds.