Right so - that's not our Pybel then. We have one file, pybel.py,
containing readstring.
I think you have installed pyBEL (the python interface to BEL) with
"pip install pybel". It's starting to get annoying that another newer
project has adopted the same name. Uninstall it, e.g. by removing the
pybel folder, or maybe there's some way to do it with pip, or just
rename the folder to wrongpybel. Feel free to lodge a complaint for
time wasted with the other project, and ask them to rename.
On 19 March 2017 at 20:09, ***@lyonstech.net <***@lyonstech.net> wrote:
> Hi,
>
> When I execute your suggested command I do not get pybel.py instead I get the path to __init__.py . This is the case with two independent versions of python. No mention of these missing methods.
>
> T
>
> X64:
> C:\Program Files\Python35>python
> Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:18:55) [MSC v.1900 64 bit (AMD64)] on win32
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import pybel
>>>> print (pybel.__file__)
> C:\Program Files\Python35\lib\site-packages\pybel\__init__.py
>>>>
>
> Win32:
>>python
> Python 3.5.2 (v3.5.2:4def2a2901a5, Jun 25 2016, 22:01:18) [MSC v.1900 32 bit (Intel)] on win32
> Type "help", "copyright", "credits" or "license" for more information.
>>>> import pybel
>>>> print(pybel.__file__)
> C:\ProgramData\chocolatey\lib\python3-x86_32\tools\lib\site-packages\pybel\__init__.py
>
> From: Noel O'Boyle [via Open Babel] [mailto:ml-node+***@n4.nabble.com]
> Sent: 18 March 2017 21:53
> To: Terry Lyons <***@lyonstech.net>
> Subject: Re: Cannot use readstring() or readfile()
>
> Take a look at pybel.py. The location is given by "print
> pybel.__file__" after importing it. Does it have readstring? Our one
> does.
>
> On 18 March 2017 at 19:02, Terry Lyons <[hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=0>> wrote:
>
>> Yes, I did
>>
>> python -m pip install openbabel
>>
>> I guess that is why I was able to import openbabel into Python.
>>
>> Does the install order matter?
>>
>> On 18 Mar 2017, at 15:17, Noel O'Boyle <[hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=1>> wrote:
>>
>> Did you try my suggestion?
>>
>> On 18 Mar 2017 3:06 p.m., "[hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=2>" <[hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=3>>
>> wrote:
>>>
>>> Hi Guys,
>>>
>>> We have basically the same challenge - which is not answered by the
>>> initial
>>> response from Frederick.
>>>
>>> As you will note from the error message in the subsequent email, readfile
>>> and readstring are reported as not being members of pybel. So using
>>> pybell.readfile does not work. From your email Frederick, you clearly
>>> think
>>> is would normally be a member. So there seems an issue in picking up the
>>> information.
>>>
>>> At my end we have tried numerous approaches to try and resolve this. The
>>> openbabel gui works, openbabel, and pybel import happily but, wherever one
>>> looks one cannot find readfile or readstring.
>>>
>>> Unfortunately this is a showstopper so any pointers as to how to fix it
>>> would be much appreciated. We have the most up to date versions of pip,
>>> setuptools, wheel, etc.
>>>
>>> Thanks
>>>
>>> Terry
>>>
>>>
>>>
>>>
>>> --
>>> View this message in context:
>>> http://forums.openbabel.org/Cannot-use-readstring-or-readfile-tp4659795p4659829.html
>>> Sent from the General discussion mailing list archive at Nabble.com.
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Check out the vibrant tech community on one of the world's most
>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>> _______________________________________________
>>> OpenBabel-discuss mailing list
>>> [hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=4>
>>> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> OpenBabel-discuss mailing list
> [hidden email]</user/SendEmail.jtp?type=node&node=4659836&i=5>
> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss
>
> ________________________________
> If you reply to this email, your message will be added to the discussion below:
> http://forums.openbabel.org/Cannot-use-readstring-or-readfile-tp4659795p4659836.html
> To unsubscribe from Cannot use readstring() or readfile(), click here<http://forums.openbabel.org/template/NamlServlet.jtp?macro=unsubscribe_by_code&node=4659795&code=dGx5b25zQGx5b25zdGVjaC5uZXR8NDY1OTc5NXwxMzE1MTg3Nzcz>.
> NAML<http://forums.openbabel.org/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>
>
> __init__.py (2K) <http://forums.openbabel.org/attachment/4659837/0/__init__.py>
>
>
>
>
> --
> View this message in context: http://forums.openbabel.org/Cannot-use-readstring-or-readfile-tp4659795p4659837.html
> Sent from the General discussion mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> _______________________________________________
> OpenBabel-discuss mailing list
> OpenBabel-***@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/openbabel-discuss