Hi Andreas,
On Sep 26, 2017 10:48, "Andreas Doering" ado@zurich.ibm.com wrote:
Hello all,
I want to use BaseX in a python environment and found PyBaseX by Luca Lilianas. Unfortunately, the email address associated with github does not seem to exist.
What is not clear to me how the url has to be formatted. I tried 'http://localhost:1984:/rest/' but got timeouts.
Have you tried 'http://localhost:1984/rest/'; e.g. removing the trailing ':'?
I started a basexserver (with default port/user/password) and I can create and work with my example database with the the textual client from BaseX. But I could not find out how I have to format the url parameter so that the python interface works.
I created a client by c = BaseXClient('http://localhost:1984:/rest/%27,default_database= None,user='admin',password='admin') c.connect c.create_database('TestName')
The last line hangs in socket read.
The log file does not show anything of that.
Furthermore, it seems, that the current code in github is python2 specific, or maybe some package it depends on. I remember that during installation on python3 something broke, so I am using python2 in the moment. Any plans to port to python3?
Regards,
Andreas
I can't speak to the python3 question, apologies.
Best, Bridger
If pybasex is using http, the port is probably not 1984. It would be the port used by the web server that is serving basex rest services. 1984 would usually be the basex server port (not using http).
Kendall
From: basex-talk-bounces@mailman.uni-konstanz.de on behalf of Bridger Dyson-Smith bdysonsmith@gmail.com Date: Tuesday, September 26, 2017 at 8:20 AM To: Andreas Doering ado@zurich.ibm.com Cc: BaseX basex-talk@mailman.uni-konstanz.de Subject: Re: [basex-talk] pyBaseX url
Hi Andreas,
On Sep 26, 2017 10:48, "Andreas Doering" <ado@zurich.ibm.commailto:ado@zurich.ibm.com> wrote:
Hello all,
I want to use BaseX in a python environment and found PyBaseX by Luca Lilianas. Unfortunately, the email address associated with github does not seem to exist.
What is not clear to me how the url has to be formatted. I tried 'http://localhost:1984:/rest/' but got timeouts. Have you tried 'http://localhost:1984/rest/https://urldefense.proofpoint.com/v2/url?u=http-3A__localhost-3A1984_rest_&d=DwMFaQ&c=DS6PUFBBr_KiLo7Sjt3ljp5jaW5k2i9ijVXllEdOozc&r=JgwnBEpN1c-DDmq-Up2QMq9rrGyfWK0KtSpT7dxRglA&m=vkvRcYv4M28bGeYb9BDYMIruu8pY9f70v9oGsahgB0Y&s=n6cs1v2KvRW9TXoN6QKdCk66WP10lQ9o9hOZTi0LTMA&e='; e.g. removing the trailing ':'?
I started a basexserver (with default port/user/password) and I can create and work with my example database with the the textual client from BaseX. But I could not find out how I have to format the url parameter so that the python interface works.
I created a client by c = BaseXClient('http://localhost:1984:/rest/https://urldefense.proofpoint.com/v2/url?u=http-3A__localhost-3A1984-3A_rest_&d=DwMFaQ&c=DS6PUFBBr_KiLo7Sjt3ljp5jaW5k2i9ijVXllEdOozc&r=JgwnBEpN1c-DDmq-Up2QMq9rrGyfWK0KtSpT7dxRglA&m=vkvRcYv4M28bGeYb9BDYMIruu8pY9f70v9oGsahgB0Y&s=pylIoP0UXvsemU8HK7Irdizv6s_-UPgiFfvSGb1NmGY&e=',default_database=None,user='admin',password='admin') c.connect c.create_database('TestName')
The last line hangs in socket read.
The log file does not show anything of that.
Furthermore, it seems, that the current code in github is python2 specific, or maybe some package it depends on. I remember that during installation on python3 something broke, so I am using python2 in the moment. Any plans to port to python3?
Regards,
Andreas I can't speak to the python3 question, apologies.
Best, Bridger
basex-talk@mailman.uni-konstanz.de