Skip to content
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

publishing to gitthub fails: Searching for target release: 1.0.0 An unhandled error has occurred inside Forge: HttpError: Not Found #1476

Closed
stepheneb opened this issue Feb 5, 2020 · 3 comments
Labels

Comments

@stepheneb
Copy link

Preflight Checklist

  • [ x] I have read the contribution documentation for this project.
  • [x ] I agree to follow the code of conduct that this project follows, as appropriate.
  • [x ] I have searched the issue tracker for a bug that matches the one I want to file, without success.

Issue Details

  • Electron Forge Version:
    • 6.0.0-beta.48
  • Electron Version:
    • v7.1.11
  • Operating System:
    macOS 10.15.3
  • Last Known Working Electron Forge version::
    • na

Expected Behavior

Running: $ node_modules/.bin/electron-forge publish would publish a release to github repo: https://github.com/stepheneb/electron-forge-app-webpack-d3

Actual Behavior

While Searching for target release: 1.0.0 and unhandled error occurs:

An unhandled error has occurred inside Forge:
Not Found
HttpError: Not Found
    at /Users/stephen/dev/electron/apps/forg

See full log:
electron-publish.log

To Reproduce

Fork and clone https://github.com/stepheneb/electron-forge-app-webpack-d3

Modify publisher-github in package.json to refer to username and repo of forked repository.

https://github.com/stepheneb/electron-forge-app-webpack-d3/blob/master/package.json#L25-L32

$ npm install && npm start

Simple test app should start.

Export appropriate GITHUB_TOKEN

export GITHUB_TOKEN=e1c5b...

Run publish task:

$ node_modules/.bin/electron-forge publish

Additional Information

Running the same command with debugging enabled: DEBUG=electron-forge:* doesn't seem to display any more info about the specific issue.

Here's the debug log anyway:
electron-publish-debug.log

config forge section

  "config": {
    "forge": {
      "packagerConfig": {},
      "publishers": [
        {
          "name": "@electron-forge/publisher-github",
          "config": {
            "repository": {
              "owner": "stepheneb",
              "name": "electron-forge-app-webpack-d3"
            },
            "prerelease": true
          }
        }
      ],
      "makers": [
        {
          "name": "@electron-forge/maker-squirrel",
          "config": {
            "name": "forge_app_webpack"
          }
        },
        {
          "name": "@electron-forge/maker-zip",
          "platforms": [
            "darwin"
          ]
        },
        {
          "name": "@electron-forge/maker-dmg",
          "config": {
            "background": "images/cabbage-bw-transparent.png",
            "format": "ULFO"
          }
        },
        {
          "name": "@electron-forge/maker-deb",
          "config": {}
        },
        {
          "name": "@electron-forge/maker-rpm",
          "config": {}
        }
      ],
      "plugins": [
        [
          "@electron-forge/plugin-webpack",
          {
            "mainConfig": "./webpack.main.config.js",
            "renderer": {
              "config": "./webpack.renderer.config.js",
              "entryPoints": [
                {
                  "html": "./src/index.html",
                  "js": "./src/renderer.js",
                  "name": "main_window",
                  "preload": {
                    "js": "./src/preload.js"
                  }
                }
              ]
            }
          }
        ]
      ]
    }
  },

Might be related to this closed issue #493

@stepheneb stepheneb added the bug label Feb 5, 2020
@stepheneb
Copy link
Author

Solved by adding additional oauth scopes to GITHUB_TOKEN.

X-OAuth-Scopes: public_repo, repo:status, repo_deployment

@nzhul
Copy link

nzhul commented Apr 26, 2023

hey @stepheneb ,
how did you added those additional oauth scopes ? Is it somewhere in the github UI, or you added them to your yml file using permissions: ?

Can you give an example please.

@baselakasha
Copy link

Anyone fixed this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants