How do you navigate and refactor code written in a dynamic language?

Posted by Philippe Beaudoin on Programmers See other posts from Programmers or by Philippe Beaudoin
Published on 2011-02-02T20:33:13Z Indexed on 2011/02/02 23:33 UTC
Read the original article Hit count: 282

I love that writing Python, Ruby or Javascript requires so little boilerplate. I love simple functional constructs. I love the clean and simple syntax.

However, there are three things I'm really bad at when developing a large software in a dynamic language:

  • Navigating the code
  • Identifying the interfaces of the objects I'm using
  • Refactoring efficiently

I have been trying simple editors (i.e. Vim) as well as IDE (Eclipse + PyDev) but in both cases I feel like I have to commit a lot more to memory and/or to constantly "grep" and read through the code to identify the interfaces.

As for refactoring, for example changing method names, it becomes hugely dependent on the quality of my unit tests. And if I try to isolate my unit tests by "cutting them off" the rest of the application, then there is no guarantee that my stub's interface stays up to date with the object I'm stubbing.

I'm sure there are workarounds for these problems. How do you work efficiently in Python, Ruby or Javascript?

© Programmers or respective owner

Related posts about programming

Related posts about ide