greptilian logo

IRC log for #sourcefu, 2016-07-28

http://sourcefu.com

| Channels | #sourcefu index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

All times shown according to UTC.

Time S Nick Message
03:08 kzisme joined #sourcefu
03:11 kzisme joined #sourcefu
03:54 kzisme joined #sourcefu
03:54 kzisme joined #sourcefu
17:39 dotplus a few days ago, I was working on some code that generates some XML to be consumed by <something else>, so I had lots of code like 'foo = etree.SubElement(...)'. The various "foo"s were by specified by the consumer's docs so I copypasted and did some vim-magic search/replace to get what I wanted.
17:39 dotplus lovely you say? except one of those "foo"s was 'os'. So I ended up with 'os = etree.SubElement(...)'
17:39 dotplus a few days ago, I was working on some code that generates some XML to be consumed by <something else>, so I had lots of code like 'foo = etree.SubElement(...)'. The various "foo"s were by specified by the consumer's docs so I copypasted and did some vim-magic search/replace to get what I wanted.
17:39 dotplus I'm sure you can see where I'm going with this. That didn't exactly help my later usage of the stdlib's os/os.path functionality.
17:39 dotplus So my question is: What Vim (plugin?) functionality can I enable to have vim 'understand' python well enough to warn me that I'm overwriting something from stdlib?
17:40 dotplus or tell me the jargon for this, so I can search for it myself?
17:43 sivoais dotplus: that might be possible to check with a linter / static analysis ?
17:43 sivoais syntastic is a plugin that can run linters for you when you save
17:44 sivoais Some specific linters are listed here <http://stackoverflow.com/questions/5168830/how-to-stop-myself-overwriting-python-functions-when-coding>
17:44 dotplus I use syntastic. Indeed, I *think* you & I have discussed it before. But I don't think that syntastic is going to help that is it? perhaps there's a "check harder" config item I can ask for.
17:47 sivoais that's usually the case :-P Too many options
17:47 sivoais I specifically see: "W0622: Redefining built-in %r" at <http://pylint-messages.wikidot.com/all-messages>
17:50 dotplus I'll check those out as well my syntastic settings. thanks
18:24 semiosis dotplus: i'll be pycharm has a rename refactoring that will do exactly what you want
18:24 semiosis i'll bet*
18:24 semiosis pretty sure it has a vim mode too ;)
18:46 dotplus I'm sure. But I wasn't really looking for a new editor:)
20:13 dotplus whew. pylint has what I need. But given the codebase I'm working with, I'm gonna have to turn off a fair chunk of the messages.

| Channels | #sourcefu index | Today | | Search | Google Search | Plain-Text | plain, newest first | summary

http://sourcefu.com