distubejs / ytdl-core

YouTube video downloader in javascript.
MIT License
289 stars 50 forks source link

cannot read properties of undefined (reading 'split') #45

Closed arcovoltaico closed 4 months ago

arcovoltaico commented 4 months ago

Describe the bug

After substituting ytdl-core by yours my Angular 14 Electron app, now fails when start with: cannot read properties of undefined (reading 'split')

Debug File

e> [webpack-dev-middleware] HookWebpackError: ENOENT: no such file or directory, scandir ''

at makeWebpackError (/Users/jordi.alhambraherraiz/MyRepos/U-Vox/player3/node_modules/@angular-devkit/build-angular/node_modules/webpack/lib/HookWebpackError.js:48:9) at /Users/jordi.alhambraherraiz/MyRepos/U-Vox/player3/node_modules/@angular-devkit/build-angular/node_modules/webpack/lib/Compilation.js:3060:12 ## Environment - @distube/ytdl-core version: 4.13.5 - Node.js version: 20.14.0 - Operating system: MacOs Sonoma 14.5 "dependencies": { "@angular/animations": "14.0.7", "@angular/cdk": "14.0.6", "@angular/common": "14.0.7", "@angular/compiler": "14.0.7", "@angular/core": "14.0.7", "@angular/forms": "14.0.7", "@angular/language-service": "14.0.7", "@angular/material": "14.0.6", "@angular/platform-browser": "14.0.7", "@angular/platform-browser-dynamic": "14.0.7", "@angular/router": "14.0.7", "@distube/ytdl-core": "4.13.5", "@jcbrouwer/itunes-music-library-tracks": "1.0.8", "@videogular/ngx-videogular": "5.0.1", "angular-user-idle": "3.0.1", "angular2-fontawesome": "5.2.1", "aws-sdk": "2.1379.0", "byline": "5.0.0", "class-transformer": "0.5.1", "electron-platform": "1.2.0", "email-validator": "2.0.4", "ffmpeg-static-electron": "2.0.3", "file-uri-to-path": "2.0.0", "fluent-ffmpeg-corrected": "github:arcovoltaico/fluent-ffmpeg-corrected", "ng-connection-service": "9.0.3", "ngx-mat-select-search": "4.2.1", "ngx-toastr": "14.3.0", "ngx-webstorage": "10.0.1", "ngx-youtube-player": "13.0.0", "normalize-text": "2.4.1", "pusher-js": "8.3.0", "rxjs": "7.5.7", "s3-upload-stream": "1.0.7", "shelljs": "0.8.5", "truncate-utf8-bytes": "1.0.2", "tslib": "2.4.1", "xml2js": "0.4.23", "zone.js": "0.11.8" }, "devDependencies": { "@angular-builders/custom-webpack": "14.0.1", "@angular-devkit/build-angular": "14.0.7", "@angular-eslint/builder": "14.0.4", "@angular-eslint/eslint-plugin": "~14.0.2", "@angular-eslint/eslint-plugin-template": "~14.0.2", "@angular-eslint/schematics": "14.0.4", "@angular-eslint/template-parser": "14.0.4", "@angular/cli": "14.0.7", "@angular/compiler-cli": "14.0.7", "@ngx-translate/core": "14.0.0", "@ngx-translate/http-loader": "7.0.0", "@playwright/test": "1.23.4", "@types/core-js": "2.5.6", "@types/jasmine": "3.10.13", "@types/jasminewd2": "2.0.11", "@types/node": "16.11.68", "@typescript-eslint/eslint-plugin": "5.30.7", "@typescript-eslint/parser": "5.30.7", "buffer": "6.0.3", "conventional-changelog-cli": "2.2.2", "electron": "24.1.2 ", "electron-builder": "24.3.0", "electron-reload": "1.5.0", "eslint": "8.19.0", "eslint-plugin-import": "2.26.0", "eslint-plugin-jsdoc": "37.9.7", "eslint-plugin-prefer-arrow": "1.2.3", "isexe": "github:arcovoltaico/isexe", "jasmine-core": "3.99.1", "jasmine-spec-reporter": "7.0.0", "karma": "6.4.2", "karma-coverage": "2.2.1", "karma-electron": "7.3.0", "karma-jasmine": "4.0.2", "karma-jasmine-html-reporter": "1.7.0", "node-polyfill-webpack-plugin": "1.1.4", "npm-run-all": "4.1.5", "playwright": "1.23.4", "ts-node": "10.9.1", "typescript": "4.7.4", "wait-on": "6.0.1", "webdriver-manager": "12.1.9", "webpack": "5.79.0" },
skick1234 commented 4 months ago

This fork support server side only, I don't have any plan to make it work on browser

warren-bank commented 3 months ago

fwiw: upstream PR-1253 adds the tooling to use Webpack to produce a browser build. If run with each newly tagged npm release, then a CDN (like unpkg) could be used to always pull from the latest version in the browser-build/dist directory of your git repo.

warren-bank commented 1 month ago

quick update: since neither repo has any interest in including a browser build with their releases, I recently made a standalone repo for that purpose. The dist/ directory for each tag is published to an npm package, so it gets added to common CDNs.