Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Repository search doesn't work when language name has a space #55

Open
punchagan opened this issue Jun 4, 2011 · 6 comments
Open

Repository search doesn't work when language name has a space #55

punchagan opened this issue Jun 4, 2011 · 6 comments

Comments

@punchagan
Copy link

Repository searches fail, when the language name contains a space.

gh.repos.search('vim', language='Emacs Lisp')
@lambdapilgrim
Copy link

github api gives server error for the requests containing unknown language names or language names with a space (%20)

Examples:
https://github.com/api/v2/xml/repos/search/physics?language=emacs%20lisp
https://github.com/api/v2/xml/repos/search/physics?language=fkjdlreqre

Should handling these special cases be an option in this library or should the server error be reflected?

@punchagan
Copy link
Author

https://github.com/api/v2/xml/repos/search/physics?language=Emacs%20Lisp doesn't seem to give an error. Though, it doesn't return any search results as well.

@lambdapilgrim
Copy link

I see error 500 with the above link.

@punchagan
Copy link
Author

It seems to work for me.

curl -i https://github.com/api/v2/xml/repos/search/physics?language=Emacs%20Lisp

gives me

HTTP/1.1 200 OK
Server: nginx/1.0.4
Date: Thu, 04 Aug 2011 04:49:11 GMT
Content-Type: application/xml; charset=utf-8
Connection: keep-alive
Status: 200 OK
X-RateLimit-Limit: 60
ETag: "edc574a846575639a3bb6c6de36e5f5b"
X-RateLimit-Remaining: 59
X-Runtime: 327ms
Content-Length: 68
Cache-Control: private, max-age=0, must-revalidate

<?xml version="1.0" encoding="UTF-8"?>
<repositories type="array"/>

@lambdapilgrim
Copy link

Interesting. I see 200 with curl command too. Pasting that link in a web browser gives an internal server error.

@lambdapilgrim
Copy link

And well, it is working on a browser too today. There is something going on behind the curtains.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants