This is a test version of Biostars. For the public version, visit https://www.biostars.org.
Problems connecting to NCBI using NCBI edirect

Hello All,

I am trying to run my program which uses NCBI edirect, somehow not able to connect to NCBI

python taxon_check.py tempid.list

    get_taxInfo = "esearch -db taxonomy -query txid%s[Organism:exp] | efetch -format docsum | xtract -pattern DocumentSummary -element TaxId ScientificName Species Subsp" % (taxid)
 output = subprocess.check_output(get_taxInfo, shell=True)
                for res in output.strip().split('\n'):
                        res = res.strip()
                        taxid_pass.write("\t".join(str(i) for i in  [taxid] + res.split('\t')) + "\n")

I get the following error

500 Can't connect to eutils.ncbi.nlm.nih.gov:443 (Connection timed

out) No do_post output returned from 'https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esearch.fcgi?db=taxonomy&term=txid9606%5BOrganism%3Aexp%5D&retmax=0&usehistory=y&edirect_os=linux&edirect=8.50&tool=edirect&email=tinu@node1.server.ch'

However when I do wget "https://eutils.ncbi.nlm.nih.gov/entrez/eutils/esearch.fcgi?db=taxonomy&term=txid9606%5BOrganism%3Aexp%5D&retmax=0&usehistory=y&edirect_os=linux&edirect=8.50&tool=edirect&email=tinu@node1.server.ch"

<eSearchResult>
<Count>3</Count>
<RetMax>0</RetMax>
<RetStart>0</RetStart>
<QueryKey>1</QueryKey>
<WebEnv>
NCID_1_251456449_130.14.18.34_9001_1524747720_1001819887_0MetA0_S_MegaStore
</WebEnv>
<IdList/>
<TranslationSet/>
<TranslationStack>
<TermSet>
<Term>txid9606[Organism:exp]</Term>
<Field>Organism</Field>
<Count>3</Count>
<Explode>N</Explode>
</TermSet>
<OP>GROUP</OP>
</TranslationStack>
<QueryTranslation>txid9606[Organism:exp]</QueryTranslation>
</eSearchResult>

Any help would be much appreciated.

Thanks

ncbi edirect esearch

Do you have the latest version of eutils installed? If not I suggest you start by upgrading them.

Since you are able to get the wget to work there should no local firewall issues.

Occasionally there might be something wrong when using it. Try later and hopefully the problem will be solved.

0 answers

No answers yet.

Log in to answer this question.