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

Input string was not in a correct format #37

Closed
drake7707 opened this issue Jan 19, 2014 · 5 comments
Closed

Input string was not in a correct format #37

drake7707 opened this issue Jan 19, 2014 · 5 comments
Assignees

Comments

@drake7707
Copy link

Use:

var tvshow = client.GetTvShow(1399);

to replicate.

I haven't determined which property it is that's causing it, but it's an integer (stacktrace mentions Convert.ToInt32).

@drake7707
Copy link
Author

It's caused by the Status? enum:

The json returned is:

"status":"Returning Series",

@Naliath
Copy link
Collaborator

Naliath commented Jan 19, 2014

That does seem to be the issue, looking into it now. Seems that the library we use to handle the rest calls is not dealing well with values with spaces.

@ghost ghost assigned Naliath Jan 19, 2014
@Naliath
Copy link
Collaborator

Naliath commented Jan 19, 2014

I found the issue and will be submitting a fix for it. for now you could change the return type to string to prevent the issue. We won't be publishing a new nuget untill the tv show api is final anyway

@Naliath
Copy link
Collaborator

Naliath commented Jan 19, 2014

restsharp/RestSharp#497, when a new version comes out of restsharp I'll be sure to update this issue so that it's properly fixed

@Naliath
Copy link
Collaborator

Naliath commented Apr 6, 2014

Changed the property to a string since this approach will not work for other languages, the service really just returns a string not a code that can be mapped consistently to an enumeration.

@Naliath Naliath closed this as completed Apr 6, 2014
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