January 2018

S M T W T F S
  123456
78910111213
14151617181920
21222324252627
28293031   

Style Credit

Expand Cut Tags

No cut tags
Monday, March 31st, 2008 11:33 am (UTC)
OK, the first thing to note is that dynamic languages mostly deal with the problem of large codebases by keeping them small in the first place. So yes, the kind of thing you mention is a bit of a problem. Some partial solutions that spring to mind:
  1. Use of a refactoring browser, like Python's Bicycle Repair Man (http://bicyclerepair.sourceforge.net/) (disclaimer: I've never used it).
  2. grep. Problematic if you have many different functions called logMessage, but why would you want to do that? :-) In this case, I think you'd be OK.
  3. Making the severity parameter optional, and giving it a sensible default.
  4. Depending on your logging needs, you might be able to isolate your calls to logMessage in some sort of aspect/hook/advice/thingy.


OTOH: you're unit testing, right? And your tests have 100% statement coverage, as measured by eg coverage (http://nedbatchelder.com/code/modules/coverage.html)? Then any broken calls will be picked up :-)

Reply

This account has disabled anonymous posting.
If you don't have an account you can create one now.
HTML doesn't work in the subject.
More info about formatting