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.

part download request failed with status code 416

See original GitHub issue
  • electron-builder version:

20.20.4

  • Target:

node 8.9.1

npm 5.6.0

package.json

{
  "name": "emp-admin-developer-app",
  "version": "1.3.0",
  "private": true,
  "main": "build/electron/index.js",
  "devDependencies": {
    "antd": "^3.6.3",
    "babel-cli": "^6.26.0",
    "babel-core": "^6.26.3",
    "babel-eslint": "^8.2.3",
    "babel-preset-es2015": "^6.24.1",
    "babel-preset-stage-2": "^6.24.1",
    "concurrently": "^3.6.0",
    "copyfiles": "^1.2.0",
    "electron": "^2.0.4",
    "electron-builder": "^20.20.4",
    "react-scripts": "1.1.0",
    "redux-form": "^7.4.2",
    "require-context": "=1.0.4",
    "wait-on": "^2.1.0"
  },
  "dependencies": {
    "ajv": "^6.5.1",
    "ajv-i18n": "^3.3.0",
    "electron-is-dev": "^0.3.0",
    "emp-admin-entity-administration-config-app": "^0.8.3",
    "emp-admin-icons": "^1.4.0",
    "jsoneditor-react": "^0.1.9",
    "open": "0.0.5",
    "react": "^16.4.1",
    "react-dom": "^16.4.1",
    "react-redux": "^5.0.7",
    "react-router-dom": "^4.3.1",
    "redux": "^3.7.2"
  },
  "scripts": {
    "dev": "react-scripts start",
    "build:app": "react-scripts build",
    "build:electron": "node buildElectron.js",
    "build": "npm run build:app && npm run build:electron",
    "test": "react-scripts test --env=jsdom",
    "eject": "react-scripts eject",
    "electron": "npm run build:electron && electron .",
    "electron-dev": "concurrently \"npm run dev\" \"wait-on http://localhost:3000 && npm run electron\"",
    "electron-pack:win": "electron-builder -w -c electron-builder.json",
    "electron-pack:linux": "electron-builder -l -c electron-builder.json",
    "electron-pack": "electron-builder -c electron-builder.json",
    "preelectron-pack": "rimraf \"dist\" && npm run build",
    "preelectron-pack:win": "npm run preelectron-pack",
    "preelectron-pack:linux": "npm run preelectron-pack"
  }
}

electron-builder.json

{
  "appId": "ru.altarix.admin.emp",
  "files": [
    "build/**/*",
    "node_modules/**/*"
  ],
  "directories":{
    "buildResources": "assets"
  },
  "win": {
    "target": "nsis",
    "icon": "assets/icons/png/256x256.png"
  },
  "linux": {
    "target": [
      "deb",
      "AppImage"
    ],
    "icon": "assets/icons/png/256x256.png"
  }
}
  • Issue

Can not download builded remotely deb package. Complete console log:

> emp-admin-developer-app@1.3.0 electron-pack:linux C:\Users\kopeykinia\Repositories\emp-admin-developer-app
> electron-builder -l -c electron-builder.json

  • electron-builder version=20.20.4
  • loaded configuration file=C:\Users\kopeykinia\Repositories\emp-admin-developer-app\electron-builder.json
  • loaded parent configuration preset=react-cra
  • writing effective config file=dist\electron-builder-effective-config.yaml
  • no native production dependencies
  • packaging       platform=linux arch=x64 electron=2.0.4 appOutDir=dist\linux-unpacked
  • scheduling remote build target=deb arch=x64
  • scheduling remote build target=appImage arch=x64
  • compressing and uploading to remote builder
  • uploaded to remote builder duration=2m47.87s
  • remote building           status=job started (queue time: 2ms)
  • remote building           status=  • electron-builder version=20.20.0
  • building        target=AppImage arch=x64 file=out/emp-admin-developer-app-1.3.0-x86_64.AppImage
  • application Linux category is set to default "Utility" reason=linux.category is not set and cannot map from macOS docs=https://electron.build/configuration/configuration#LinuxBuildOptions-category
  • building        target=deb arch=x64 file=out/emp-admin-developer-app_1.3.0_amd64.deb
  • application Linux category is set to default "Utility" reason=linux.category is not set and cannot map from macOS docs=https://electron.build/configuration/configuration#LinuxBuildOptions-category

  ⨯ part download request failed with status code 416
github.com/develar/app-builder/pkg/download.(*Part).doRequest
        /Users/develar/go/src/github.com/develar/app-builder/pkg/download/Part.go:127
github.com/develar/app-builder/pkg/download.(*Part).download
        /Users/develar/go/src/github.com/develar/app-builder/pkg/download/Part.go:46
github.com/develar/app-builder/pkg/download.(*Downloader).DownloadResolved.func1.1
        /Users/develar/go/src/github.com/develar/app-builder/pkg/download/downloader.go:96
github.com/develar/app-builder/pkg/util.MapAsyncConcurrency.func1
        /Users/develar/go/src/github.com/develar/app-builder/pkg/util/async.go:56
runtime.goexit
        /usr/local/Cellar/go/1.10.3/libexec/src/runtime/asm_amd64.s:2361

Error: C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\app-builder-bin\win\x64\app-builder.exe exited with code 1
    at ChildProcess.childProcess.once.code (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\builder-util\src\util.ts:251:14)
    at Object.onceWrapper (events.js:317:30)
    at emitTwo (events.js:126:13)
    at ChildProcess.emit (events.js:214:7)
    at maybeClose (internal/child_process.js:925:16)
    at Process.ChildProcess._handle.onexit (internal/child_process.js:209:5)
From previous event:
    at RemoteBuilder._build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\remoteBuilder\RemoteBuilder.ts:56:83)
    at _bluebirdLst.default.mapSeries.arch (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\remoteBuilder\RemoteBuilder.ts:51:19)
From previous event:
    at RemoteBuilder.build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\remoteBuilder\RemoteBuilder.ts:50:28)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\linuxPackager.ts:99:30
From previous event:
    at RemoteTarget.finishBuild (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\linuxPackager.ts:97:20)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:377:36
    at Generator.next (<anonymous>)
    at runCallback (timers.js:789:20)
    at tryOnImmediate (timers.js:751:5)
    at processImmediate [as _immediateCallback] (timers.js:722:5)
From previous event:
    at Packager.doBuild (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:337:39)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:313:52
    at Generator.next (<anonymous>)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\graceful-fs\graceful-fs.js:99:16
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\graceful-fs\graceful-fs.js:43:10
    at FSReqWrap.oncomplete (fs.js:135:15)
From previous event:
    at Packager._build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:290:133)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:286:23
    at Generator.next (<anonymous>)
    at runCallback (timers.js:789:20)
    at tryOnImmediate (timers.js:751:5)
    at processImmediate [as _immediateCallback] (timers.js:722:5)
From previous event:
    at Packager.build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\packager.ts:243:14)
    at C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\src\index.ts:52:40
    at Generator.next (<anonymous>)
From previous event:
    at build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder-lib\out\index.js:220:17)
    at build (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder\src\builder.ts:224:10)
    at then (C:\Users\kopeykinia\Repositories\emp-admin-developer-app\node_modules\electron-builder\src\cli\cli.ts:42:48)
    at <anonymous>
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! emp-admin-developer-app@1.3.0 electron-pack:linux: `electron-builder -l -c electron-builder.json`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the emp-admin-developer-app@1.3.0 electron-pack:linux script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\kopeykinia\AppData\Roaming\npm-cache\_logs\2018-07-13T10_20_22_736Z-debug.log

Issue Analytics

  • State:open
  • Created 5 years ago
  • Comments:29 (3 by maintainers)

github_iconTop GitHub Comments

22reactions
digauscommented, Jan 8, 2020

Also getting 403:


• downloading     url=https://github.com/electron/electron/releases/download/v7.1.7/electron-v7.1.7-win32-x64.zip size=63 MB parts=8                                                                                                    ize=63 MB parts=8
  • retrying        attempt=1
  • retrying        attempt=2
  • retrying        attempt=3
  ⨯ part download request failed with status code 403
github.com/develar/app-builder/pkg/download.(*Part).doRequest
        /Volumes/data/Documents/app-builder/pkg/download/Part.go:126
github.com/develar/app-builder/pkg/download.(*Part).download
        /Volumes/data/Documents/app-builder/pkg/download/Part.go:67
github.com/develar/app-builder/pkg/download.(*Downloader).DownloadResolved.func1.1
        /Volumes/data/Documents/app-builder/pkg/download/downloader.go:107
github.com/develar/app-builder/pkg/util.MapAsyncConcurrency.func2
        /Volumes/data/Documents/app-builder/pkg/util/async.go:68
runtime.goexit
        /usr/local/Cellar/go/1.12.7/libexec/src/runtime/asm_amd64.s:1337  
  ⨯ C:\Projekte\ShellyHomeCapacitor\electron\node_modules\app-builder-bin\win\x64\app-builder.exe exited with code ERR_ELECTRON_BUILDER_CANNOT_EXECUTE  stackTrace=
4reactions
amanharwaracommented, Nov 8, 2019

I got the same issue except the status code is 403. It’s the first time it happened to me and it only happens when trying to build for macOS. It downloaded just fine on Linux and Windows. My electron-builder version is v21.2.0 and the electron version is v7.1.0

Edit: Tried it again today and it worked.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Android studio download error(Request failed with status code ...
Go to this location-. C:\Users\gauta\AppData\Local\Android\Sdk.downloadIntermediates. In place of *gauta write your username.
Read more >
416 Range Not Satisfiable - HTTP - MDN Web Docs
The HyperText Transfer Protocol (HTTP) 416 Range Not Satisfiable error response code indicates that a server cannot serve the requested ranges.
Read more >
How to Fix Http Error 416 Range Not Satisfiable on ... - MiniTool
Http error 416 was called Requested Range Not Satisfiable. When a server cannot support the portion of the file that the client has...
Read more >
I keep getting this error trying to download a Battlefield update ...
416 Http status code could be something to do with the PlayStation adding the wrong Range headers which are used for big downloads...
Read more >
416 HTTP Response Status Code Definition - Holistic SEO
The 416 HTTP Status Code which means that range is not satisfiable indicates that the server is unable to provide the requested ranges....
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