You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
emulator logs missing functionality of online console logs #1859
Local logs should display clear differentiation between log types.
[REQUIRED] Actual behavior
log and error are not differentiated, making it difficult to visually scan what's going on.
For some context, I'm a beginner when it comes to back-end debugging, but I'd like to believe that Firebase is at least partially targeted at users like me, who have a front-end background, and are looking for a friendly way to add serverless functionality.
So, I'm used to looking at logs in the browser console, where log, warn, and error are presented visually differently, and can be filtered.
This is an accessibility issue as well, since not everyone can easily visually scan a giant block of undifferentiated text (see #1839) -- the symbols and colors of browser devtools are a boon in that regard.
So, to summarize, it would be extremely helpful to have better logging tools available locally,
symbols or text to differentiate log level
separation of explicit user logging from auto-generated logs
and at the bare minimum, to replicate the logging of the online console.
I hope this is helpful feedback. If I'm ignorant to a better way of debugging firebase functions, I would welcome suggestion. And again, kudos on these tools.
PS: Just a final thought: perhaps when running firebase serve, the logs from index.js could be sent to the browser console? I have no idea if that's possible, but if it were, it would certainly make life easier!
changed the title [-]emulator logs missing functionality of online console function logs[/-][+]emulator logs missing functionality of online console logs[/+]on Dec 11, 2019
Just to update this, when the firebase serve command is run, the output actually does have useful iconography:
i emulators: Starting emulators: functions, firestore, database, pubsub
⚠ Your requested "node" version "8" doesn't match your global version "12"
✔ functions: Emulator started at http://localhost:5001
i firestore: Serving ALL traffic (including WebChannel) on http://localhost:8080
⚠ firestore: Support for WebChannel on a separate port (8081) is DEPRECATED and will go away soon. Please use port above instead.
i firestore: Emulator logging to firestore-debug.log
✔ firestore: Emulator started at http://localhost:8080
So, symbols like that tied to console.log, warn, error, info would help make local logging easier to read!
Activity
[-]emulator logs missing functionality of online console function logs[/-][+]emulator logs missing functionality of online console logs[/+]ultraGentle commentedon Dec 13, 2019
Just to update this, when the
firebase servecommand is run, the output actually does have useful iconography:So, symbols like that tied to
console.log,warn,error,infowould help make local logging easier to read!samtstern commentedon Dec 16, 2019
@ultraGentle thanks for the feature request!
ultraGentle commentedon Dec 17, 2019
Sorry, just realized this is a duplicate of #1800 ! I'll do any additional communicating there.
christophe-g commentedon Dec 17, 2019
; ) Looks like a useful addition then !
samtstern commentedon Dec 18, 2019
I updated the title of #1800 so we can close this one and continue discussing there, as @ultraGentle suggested.