deepaksathya

deepaksathya

Programming WebRTC:Prerequisite for Starting Server not given(page 7)

@karlstolley

The instructions for starting the server is given. If a user doesn’t know how node.js works he/she will not be able to start the server. There is no mention about doing an npm install before npm start, as the dependency packages will not be available.
The user will get some error like below:
Error: Cannot find module ‘http-errors’
Require stack:

  • /home/tom/webrtc/code/server.js
  • /home/tom/webrtc/code/scripts/start-server
    at Function.Module._resolveFilename (node:internal/modules/cjs/loader:985:15)
    at Function.Module._load (node:internal/modules/cjs/loader:833:27)
    at Module.require (node:internal/modules/cjs/loader:1057:19)
    at require (node:internal/modules/cjs/helpers:103:18)
    at Object. (/home/tom/webrtc/code/server.js:12:21)
    at Module._compile (node:internal/modules/cjs/loader:1155:14)
    at Object.Module._extensions…js (node:internal/modules/cjs/loader:1209:10)
    at Module.load (node:internal/modules/cjs/loader:1033:32)
    at Function.Module._load (node:internal/modules/cjs/loader:868:12)
    at Module.require (node:internal/modules/cjs/loader:1057:19) {
    code: ‘MODULE_NOT_FOUND’,
    requireStack: [
    ‘/home/tom/webrtc/code/server.js’,
    ‘/home/tom/webrtc/code/scripts/start-server’
    ]
    }
0 397 1

Marked As Solved

karlstolley

karlstolley

Author of WebRTC: Build Real-Time Web Applications in the Browser

Thanks for this report, @deepaksathya! The instructions to install dependencies come a bit earlier and seem to be easily overlooked, so there will be a more prominent reminder to do just that in this section.

Popular Prag Prog topics Top

kuroneko
Whilst the author has been careful to provide exact results for the tests elsewhere in the book (such as surds with the transformation te...
3 1053 0
New
iPaul
page 37 ANTLRInputStream input = new ANTLRInputStream(is); as of ANTLR 4 .8 should be: CharStream stream = CharStreams.fromStream(i...
4 981 0
New
Mmm
Hi, build fails on: bracket-lib = “~0.8.1” when running on Mac Mini M1 Rust version 1.5.0: Compiling winit v0.22.2 error[E0308]: mi...
1 1213 1
New
AndyDavis3416
@noelrappin Running the webpack dev server, I receive the following warning: ERROR in tsconfig.json TS18003: No inputs were found in c...
3 1432 3
New
fynn
This is as much a suggestion as a question, as a note for others. Locally the SGP30 wasn’t available, so I ordered a SGP40. On page 53, ...
0 1284 2
New
AufHe
I’m a newbie to Rails 7 and have hit an issue with the bin/Dev script mentioned on pages 112-113. Iteration A1 - Seeing the list of prod...
0 2602 9
New
taguniversalmachine
It seems the second code snippet is missing the code to set the current_user: current_user: Accounts.get_user_by_session_token(session["...
0 1877 8
New
EdBorn
Title: Agile Web Development with Rails 7: (page 70) I am running windows 11 pro with rails 7.0.3 and ruby 3.1.2p20 (2022-04-12 revision...
0 1120 1
New
mcpierce
@mfazio23 I’ve applied the changes from Chapter 5 of the book and everything builds correctly and runs. But, when I try to start a game,...
0 1143 10
New
dachristenson
@mfazio23 Android Studio will not accept anything I do when trying to use the Transformations class, as described on pp. 140-141. Googl...
0 2035 5
New

Other popular topics Top

AstonJ
If it’s a mechanical keyboard, which switches do you have? Would you recommend it? Why? What will your next keyboard be? Pics always w...
144 8219 50
New
AstonJ
What chair do you have while working… and why? Is there a ‘best’ type of chair or working position for developers?
74 4636 41
New
PragmaticBookshelf
A PragProg Hero’s Journey with Brian P. Hogan @bphogan Have you ever worried that your only legacy will be in the form of legacy...
50 3238 20
New
AstonJ
Or looking forward to? :nerd_face:
480 9107 251
New
DevotionGeo
I know that -t flag is used along with -i flag for getting an interactive shell. But I cannot digest what the man page for docker run com...
7 6542 2
New
Rainer
My first contact with Erlang was about 2 years ago when I used RabbitMQ, which is written in Erlang, for my job. This made me curious and...
195 6223 96
New
foxtrottwist
Here’s our thread for the Keyboardio Atreus. It is a mechanical keyboard based on and a slight update of the original Atreus (Keyboardio ...
9 3076 7
New
Exadra37
I am asking for any distro that only has the bare-bones to be able to get a shell in the server and then just install the packages as we ...
66 20132 25
New
PragmaticBookshelf
Build efficient applications that exploit the unique benefits of a pure functional language, learning from an engineer who uses Haskell t...
15 4338 2
New
PragmaticBookshelf
Author Spotlight Mike Riley @mriley This month, we turn the spotlight on Mike Riley, author of Portable Python Projects. Mike’s book ...
62 6125 20
New

Latest in PragProg

View all threads ❯