mithro / autolabeler

Add labels to Pull Requests based on matched file patterns
ISC License
103 stars 27 forks source link

Github Enterprise: "context.github.repos.getContents is not a function" #46

Closed aegershman closed 5 years ago

aegershman commented 5 years ago

Pushing a package.json that looks like this:

{
  "name": "probot-combo-value-pack",
  "private": true,
  "dependencies": {
    "probot-labeler": "probot/autolabeler"
  },
  "scripts": {
    "start": "probot run"
  },
  "engines": {
    "node": "10.x"
  },
  "probot": {
    "apps": [
      "probot-labeler"
    ]
  }
}

and getting an error within probot-config, which says context.github.repos.getContents is not a function:

2019-05-31T09:17:27.970-05:00 [APP/PROC/WEB/1] [OUT] at EventEmitter.events.on (/home/vcap/deps/0/node_modules/probot/lib/robot.js:102:17)
2019-05-31T09:17:27.970-05:00 [APP/PROC/WEB/1] [OUT] at robot.on (/home/vcap/deps/0/node_modules/probot-settings/index.js:9:26)
2019-05-31T09:17:27.970-05:00 [APP/PROC/WEB/1] [OUT] at getConfig (/home/vcap/deps/0/node_modules/probot-config/lib/index.js:114:24)
2019-05-31T09:17:27.970-05:00 [APP/PROC/WEB/1] [OUT] at loadYaml (/home/vcap/deps/0/node_modules/probot-config/lib/index.js:48:49)
2019-05-31T09:17:27.970-05:00 [APP/PROC/WEB/1] [OUT]  TypeError: context.github.repos.getContents is not a function

Using GitHub Enterprise Server 2.16.2

Guessing this is related to a change in an upstream dependency (probot-config, probot itself, etc.) that has deprecated one of the modules used for retrieving content within GHE.

[issue moved from probot/settings#123]

stale[bot] commented 5 years ago

Is this still relevant? If so, what is blocking it? Is there anything you can do to help move it forward?