Hello all,
I've been trying to write a plugin for Avogadro to use cclib, but
there's one or two things causing import problems. One of these is
urllib - the reason why it's causing problems isn't very interesting
(just a C extension that isn't available in Avogadro's Python on
Windows), but I was thinking that there's no need for cclib to be
importing it in the first place.
Our existing code for openlogfile can already handle any file-like
object. That is, you can pass a string (as a StringIO) into ccopen,
and it will work. You can also pass a url.urlopen("http://whatever")
into openlogfile and it will work fine (AFAIK). Since urls are already
handled in this way, I don't think we need a second way to handle them
via urllib (and removing it will solve one of my import problems).
- Noel
|