lukasschwab / arxiv.py

Python wrapper for the arXiv API
MIT License
1.11k stars 123 forks source link

Cannot download PDF #116

Closed ucalyptus2 closed 1 year ago

ucalyptus2 commented 1 year ago

image

lukasschwab commented 1 year ago

Hi @forkbabu — I can't seem reproduce this. For the same paper:

>>> import arxiv
>>> paper = next(arxiv.Search(id_list=["1605.08386v1"]).results())
>>> paper
arxiv.Result(entry_id='http://arxiv.org/abs/1605.08386v1', updated=datetime.datetime(2016, 5, 26, 17, 59, 46, tzinfo=datetime.timezone.utc), published=datetime.datetime(2016, 5, 26, 17, 59, 46, tzinfo=datetime.timezone.utc), title='Heat-bath random walks with Markov bases', authors=[arxiv.Result.Author('Caprice Stanley'), arxiv.Result.Author('Tobias Windisch')], summary='Graphs on lattice points are studied whose edges come from a finite set of\nallowed moves of arbitrary length. We show that the diameter of these graphs on\nfibers of a fixed integer matrix can be bounded from above by a constant. We\nthen study the mixing behaviour of heat-bath random walks on these graphs. We\nalso state explicit conditions on the set of moves so that the heat-bath random\nwalk, a generalization of the Glauber dynamics, is an expander in fixed\ndimension.', comment='20 pages, 3 figures', journal_ref=None, doi=None, primary_category='math.CO', categories=['math.CO', 'math.ST', 'stat.TH', 'Primary: 05C81, Secondary: 37A25, 11P21'], links=[arxiv.Result.Link('http://arxiv.org/abs/1605.08386v1', title=None, rel='alternate', content_type=None), arxiv.Result.Link('http://arxiv.org/pdf/1605.08386v1', title='pdf', rel='related', content_type=None)])
>>> >>> paper.download_pdf()
'./1605.08386v1.Heat_bath_random_walks_with_Markov_bases.pdf'

The 403 status suggests arXiv itself is rejecting your download request for some reason; I'm not affiliated with them, so it's hard to explain why.

Some things to explore:

In the future, please actually fill out the bug report template.