question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

electron-forget publish : Cannot read property 'succeed' of undefined

See original GitHub issue

Unable to publish due to an undefined error.

Command:

DEBUG=electron-forge:* ./node_modules/.bin/electron-forge publish

Output:

WARNING: DEBUG environment variable detected.  Progress indicators will be sent over electron-forge:lifecycle
  electron-forge:lifecycle Process Started: Checking your system +0ms
  electron-forge:lifecycle Process Succeeded: Checking your system +23ms
  electron-forge:runtime-config setting key: verbose to value: false +13ms
WARNING: DEBUG environment variable detected.  Progress indicators will be sent over electron-forge:lifecycle
  electron-forge:lifecycle Process Started: Resolving Forge Config +0ms
  electron-forge:project-resolver searching for project in: /Users/stan/Sites/markbook +3ms
  electron-forge:lifecycle Process Started: Resolving Forge Config +5ms
  electron-forge:project-resolver searching for project in: /Users/stan/Sites/markbook +1ms
  electron-forge:project-resolver electron-forge compatible package.json found in /Users/stan/Sites/markbook/package.json +6ms
  electron-forge:project-resolver electron-forge compatible package.json found in /Users/stan/Sites/markbook/package.json +2ms
  electron-forge:lifecycle Process Succeeded: Resolving Forge Config +9ms
We need to package your application before we can make it
  electron-forge:lifecycle Process Started: Preparing to Package Application for arch: x64 +1ms
  electron-forge:project-resolver searching for project in: /Users/stan/Sites/markbook +1ms
  electron-forge:lifecycle Process Succeeded: Resolving Forge Config +2ms
We need to package your application before we can make it
  electron-forge:lifecycle Process Started: Preparing to Package Application for arch: x64 +1ms
  electron-forge:project-resolver searching for project in: /Users/stan/Sites/markbook +0ms
  electron-forge:project-resolver electron-forge compatible package.json found in /Users/stan/Sites/markbook/package.json +1ms
  electron-forge:project-resolver electron-forge compatible package.json found in /Users/stan/Sites/markbook/package.json +0ms

An unhandled rejection has occurred inside Forge:
Cannot read property 'succeed' of undefined
TypeError: Cannot read property 'succeed' of undefined
    at _callee4$ (/Users/stan/Sites/markbook/node_modules/electron-forge/dist/api/package.js:308:28)
    at tryCatch (/Users/stan/Sites/markbook/node_modules/regenerator-runtime/runtime.js:64:40)
    at GeneratorFunctionPrototype.invoke [as _invoke] (/Users/stan/Sites/markbook/node_modules/regenerator-runtime/runtime.js:355:22)
    at GeneratorFunctionPrototype.prototype.(anonymous function) [as next] (/Users/stan/Sites/markbook/node_modules/regenerator-runtime/runtime.js:116:21)
    at GeneratorFunctionPrototype.tryCatcher (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/util.js:16:23)
    at PromiseSpawn._promiseFulfilled (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/generators.js:97:49)
    at Promise._settlePromise (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/promise.js:572:26)
    at Promise._settlePromise0 (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/promise.js:612:10)
    at Promise._settlePromises (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/promise.js:691:18)
    at Async._drainQueue (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/async.js:133:16)
    at Async._drainQueues (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/async.js:143:10)
    at Immediate.Async.drainQueues (/Users/stan/Sites/markbook/node_modules/bluebird/js/release/async.js:17:14)
    at runCallback (timers.js:637:20)
    at tryOnImmediate (timers.js:610:5)
    at processImmediate [as _immediateCallback] (timers.js:582:5)

config.forge:

    "forge": {
      "make_targets": {
        "darwin": [
          "zip",
          "dmg"
        ]
      }
    }

This is just a straight forward electron-forge publish. This worked previously, I’ve only run into this issue since upgrading from 2.2.0 to 2.5.1.

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:6 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
MarshallOfSoundcommented, Jan 7, 2017

Fixed in v2.5.2

0reactions
johnhaldemancommented, Aug 6, 2017

Just a tip in case someone sees this error for a version higher than v2.5.2 it might be that you’re running electron-forge under a non-administrative user in Windows. I ran into the same error and it was cleared up when I started my terminal as an administrator.

Read more comments on GitHub >

github_iconTop Results From Across the Web

"Cannot read property 'succeed' of undefined" occurs ... - GitHub
When I execute the make for Mac(darwin), "Cannot read property 'succeed' of undefined" occurred. ... Console output when you run electron-forge ...
Read more >
Electron Forge Error - cannot read property 'close' of undefined
I just ran into this today and managed to find a hint here. You have to bind to the Electron app 's window-all-closed...
Read more >
Electron Forge Error Cannot Read Property 'Close' Of Undefined
JavaScript TypeError is thrown when an operand or argument passed to a function is incompatible with the type expected by that operator or...
Read more >
Electron's blog
Introducing Electron Forge 6, a complete pipeline for building your Electron apps. Read more in the Forge 6 announcement blog!
Read more >
electron-packager - npm
For creating distributables like installers and Linux packages, consider using either Electron Forge (which uses Electron Packager ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found