Console output for debugging
Post MTG Forge Related Programming Questions Here
Moderators: timmermac, Blacksmith, KrazyTheFox, Agetian, friarsol, CCGHQ Admins
Console output for debugging
by slapshot5 » 21 Apr 2010, 17:18
Hi all,
Trying to use the console in Eclipse for debugging is almost useless right now due to the excessive writing of stuff like this:
I'd like to comment this stuff out and check it in to make the console useful for debugging. (Or if someone wants to set up some kind of debug context around stuff like this to only display when running in that context.)
Objections?
-slapshot5
Trying to use the console in Eclipse for debugging is almost useless right now due to the excessive writing of stuff like this:
- Code: Select all
Currently 16 images in the cache
New Image for key: mana_pool
File not found, no image created: res\pics\mana_pool.jpg
I'd like to comment this stuff out and check it in to make the console useful for debugging. (Or if someone wants to set up some kind of debug context around stuff like this to only display when running in that context.)
Objections?
-slapshot5
- slapshot5
- Programmer
- Posts: 1391
- Joined: 03 Jan 2010, 17:47
- Location: Mac OS X
- Has thanked: 25 times
- Been thanked: 68 times
Re: Console output for debugging
by slapshot5 » 21 Apr 2010, 18:05
On the same topic, what about all this stuff?
-slapshot5
- Code: Select all
java.lang.Exception: TreeProperties returns null for Display--properties
java.lang.Exception: TreeProperties returns null for Display/concede--properties
java.lang.Exception: TreeProperties returns null for Display/concede/button
java.lang.Exception: TreeProperties returns null for Display--properties
java.lang.Exception: TreeProperties returns null for en/Display--properties
java.lang.Exception: TreeProperties returns null for Display--properties
java.lang.Exception: TreeProperties returns null for en/Display--properties
-slapshot5
- slapshot5
- Programmer
- Posts: 1391
- Joined: 03 Jan 2010, 17:47
- Location: Mac OS X
- Has thanked: 25 times
- Been thanked: 68 times
Re: Console output for debugging
by DennisBergkamp » 21 Apr 2010, 18:33
Yeah, feel free to comment out the caching stuff.
The treeproperties exceptions are minor, Silly Freak is still working on finishing those I think, let's keep those warnings in for now.
The treeproperties exceptions are minor, Silly Freak is still working on finishing those I think, let's keep those warnings in for now.
-
DennisBergkamp - AI Programmer
- Posts: 2602
- Joined: 09 Sep 2008, 15:46
- Has thanked: 0 time
- Been thanked: 0 time
Re: Console output for debugging
by Chris H. » 21 Apr 2010, 19:34
`slapshot5 wrote:I'd like to comment this stuff out and check it in to make the console useful for debugging. (Or if someone wants to set up some kind of debug context around stuff like this to only display when running in that context.)
Objections?
These debugging messages can sometimes stick around when then are no longer useful. Human tendency I guess.
We also tend to comment out code when we convert cards from code objects to keywords. The commented out code can also stick around for a longer period of time than is necessary.
-
Chris H. - Forge Moderator
- Posts: 6320
- Joined: 04 Nov 2008, 12:11
- Location: Mac OS X Yosemite
- Has thanked: 644 times
- Been thanked: 643 times
Re: Console output for debugging
by silly freak » 21 Apr 2010, 20:38
I haven't thought too much about those TreeProperties outputs lately, but after looking a the code again, I resolved it. My property lookup code works recursive, and if a recursive call returns null, this is also printed
generally for debugging output, I'm using log4j for my program, and it works perfect for me. log4j lets you configure for which classes to print debug output, without changing the source code.
generally for debugging output, I'm using log4j for my program, and it works perfect for me. log4j lets you configure for which classes to print debug output, without changing the source code.
___
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
where's the "trust me, that will work!" switch for the compiler?
Laterna Magica - blog, forum, project, 2010/09/06 release!
- silly freak
- DEVELOPER
- Posts: 598
- Joined: 26 Mar 2009, 07:18
- Location: Vienna, Austria
- Has thanked: 93 times
- Been thanked: 25 times
5 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 28 guests