Created
January 25, 2012 21:05
-
-
Save cmcavoy/1678711 to your computer and use it in GitHub Desktop.
debugging session
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ node debug app.js | |
< debugger listening on port 5858 | |
connecting... ok | |
debug> c | |
< express-csrf is deprecated. Please use Connect's csrf middleware instead | |
< info: environment: local | |
< info: opening server on port: 8888 | |
< info: READY PLAYER ONE | |
break in controllers/backpack.js:203 | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
debug> print req | |
... | |
... ; | |
... | |
debug> | |
debug> | |
debug> | |
debug> help | |
Commands: run (r), cont (c), next (n), step (s), out (o), backtrace (bt), setBreakpoint (sb), clearBreakpoint (cb), | |
watch, unwatch, watchers, repl, restart, kill, list, scripts, breakpoints, version | |
debug> list | |
[Function] | |
debug> 03:02 PM:~/projects/openbadges | |
$ node debug app.js | |
< debugger listening on port 5858 | |
connecting... ok | |
debug> c | |
< express-csrf is deprecated. Please use Connect's csrf middleware instead | |
< info: environment: local | |
< info: opening server on port: 8888 | |
< info: READY PLAYER ONE | |
break in controllers/backpack.js:203 | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
debug> list | |
[Function] | |
debug> list() | |
198 return res.redirect(reverse('backpack.manage'), 303); | |
199 }) | |
200 } | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
207 var redirect = function(err) { | |
208 if (err) req.flash('error', err); | |
debug> print(req) | |
ReferenceError: req is not defined | |
at repl:1:8 | |
at Interface.controlEval (_debugger.js:930:21) | |
at REPLServer.eval (native) | |
at Interface.<anonymous> (repl.js:182:12) | |
at Interface.emit (events.js:67:17) | |
at Interface._onLine (readline.js:162:10) | |
at Interface._line (readline.js:426:8) | |
at Interface._ttyWrite (readline.js:603:14) | |
at ReadStream.<anonymous> (readline.js:82:12) | |
at ReadStream.emit (events.js:88:20) | |
debug> print(res) | |
ReferenceError: res is not defined | |
at repl:1:8 | |
at Interface.controlEval (_debugger.js:930:21) | |
at REPLServer.eval (native) | |
at Interface.<anonymous> (repl.js:182:12) | |
at Interface.emit (events.js:67:17) | |
at Interface._onLine (readline.js:162:10) | |
at Interface._line (readline.js:426:8) | |
at Interface._ttyWrite (readline.js:603:14) | |
at ReadStream.<anonymous> (readline.js:82:12) | |
at ReadStream.emit (events.js:88:20) | |
debug> list() | |
198 return res.redirect(reverse('backpack.manage'), 303); | |
199 }) | |
200 } | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
207 var redirect = function(err) { | |
208 if (err) req.flash('error', err); | |
debug> n | |
break in controllers/backpack.js:204 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
debug> list() | |
199 }) | |
200 } | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
207 var redirect = function(err) { | |
208 if (err) req.flash('error', err); | |
209 return res.redirect(reverse('backpack.manage'), 303); | |
debug> n | |
break in controllers/backpack.js:205 | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
207 var redirect = function(err) { | |
debug> list() | |
200 } | |
201 | |
202 exports.upload = function(req, res) { | |
203 debugger; | |
204 var email = emailFromSession(req); | |
205 if (!email) return res.redirect(reverse('backpack.login'), 303); | |
206 | |
207 var redirect = function(err) { | |
208 if (err) req.flash('error', err); | |
209 return res.redirect(reverse('backpack.manage'), 303); | |
210 } | |
debug> print(email) | |
ReferenceError: email is not defined | |
at repl:1:8 | |
at Interface.controlEval (_debugger.js:930:21) | |
at REPLServer.eval (native) | |
at Interface.<anonymous> (repl.js:182:12) | |
at Interface.emit (events.js:67:17) | |
at Interface._onLine (readline.js:162:10) | |
at Interface._line (readline.js:426:8) | |
at Interface._ttyWrite (readline.js:603:14) | |
at ReadStream.<anonymous> (readline.js:82:12) | |
at ReadStream.emit (events.js:88:20) | |
debug> print(req) | |
ReferenceError: req is not defined | |
at repl:1:8 | |
at Interface.controlEval (_debugger.js:930:21) | |
at REPLServer.eval (native) | |
at Interface.<anonymous> (repl.js:182:12) | |
at Interface.emit (events.js:67:17) | |
at Interface._onLine (readline.js:162:10) | |
at Interface._line (readline.js:426:8) | |
at Interface._ttyWrite (readline.js:603:14) | |
at ReadStream.<anonymous> (readline.js:82:12) | |
at ReadStream.emit (events.js:88:20) | |
debug> help | |
Commands: run (r), cont (c), next (n), step (s), out (o), backtrace (bt), setBreakpoint (sb), clearBreakpoint (cb), | |
watch, unwatch, watchers, repl, restart, kill, list, scripts, breakpoints, version | |
debug> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment