Git Product home page Git Product logo

themoviedbwrapper's People

Contributors

arividar avatar jack4h3 avatar matt-mccabe avatar ncubed avatar rhada avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

themoviedbwrapper's Issues

Upgrade Solution to VS 2019

Will migrate away from the portable project library and into the newer VS 2019 netstandard project library.

Full trust level

When I run call your methods to get data it works fine locally . but when I host it doesnt work ..... my services provider say it due to Full trust level its there a way it can be Medium trust level?

Integration Tests Broken

After a couple of years of neglect, several of the integration tests are broken. Is anyone surprised? I'm not. Let's get this project running again.

Exception thrown when requesting certain TVShow details

There is a problem when the info for requested TV show Task<ApiQueryResponse<TVShow>> FindByIdAsync(int tvShowId, string language = "en"); returns a null value for a season air_date because the property AirDate in the class Season is not supposed to be null.
This is the case with a TV show called "Haven" with 33001 as TMDBId which has a record with a special season that has air_date: null
To replicate:
ApiQueryResponse<TVShow> responseInfo = await tvApi.FindByIdAsync(33001);
Error: Cannot convert null value to System.DateTime. Path 'seasons[0].air_date', line 1, position 1006.

HttpClient instance creation

This function:

public async Task<ApiQueryResponse> QueryAsync( string command, IDictionary<string, string> parameters, Func<string, T> deserializer )
{
using( HttpClient client = CreateClient() )
{
string cmd = CreateCommand( command, parameters );
...

creates a HttpClient each time the function is called.

Is that necessary? Would it not be more efficient to create an instance of the HttpClient in the constructor of ApiRequestBase?

Not installing into PCL(i.e. Portable Class Library project) on Cross platform app

I am trying to install this package with nuget into a Cross-Platform Blank Portable app,
It does install fine into the .Droid and .iOS but when I try to install with nuget into the PCL(Portable Library) project it always gives me the following error. Even if I change Targets so the .NETPortable goes up to v4.5=Profile259 it gives me the same Error.


Error 	Could not install package 'TheMovieDbWrapper 0.8.0'. 
You are trying to install this package into a project that targets '.NETPortable,Version=v4.0,Profile=Profile24', 
but the package does not contain any assembly references or content files 
that are compatible with that framework. For more information, contact the package author.

Upgrade Nuget Package

The latest release on Nuget is too old and has a null ref bug which was resolved with #25 while fixing integration tests. Additionally, the packaging for nusepc files is built-in to VS 2019.

Xamarin.iOS

When I try to install TheMovieDbWrapper into a Xamarin.iOS project, I get the following error:

Could not install package 'TheMovieDbWrapper 0.7.1'. You are trying to install this package into a project that targets 'Xamarin.iOS,Version=v1.0', but the package does not contain any assembly references or content files that are compatible with that framework. For more information, contact the package author.

What is the problem here?

IMDB ID

There does not seem a way to get the associated IMDB ID when using SearchByTitleAsync()?

The current type for Revenue is insufficient.

When retrieving the movie "Avatar" (id= 19995), I received a JsonReaderException.

"Additional information: JSON integer 2781505847 is too large or small for an Int32. Path 'revenue', line 1, position 1122."

Port to PCL broke support for IMovieDbApi

When porting to .netstandard (PCL support), the MovieDbFactory required refactoring to accommodate the changes in MEF as currently supported in .netstandard. Specifically, MEF2 no longer supports attributes for describing imports/exports which IMovieDbApi implementation heavily relied upon.

The current release no longer uses MEF. This issue is to continue the refactor of the MovieDbFactory and introduction of an alternative IoC container.

Exception in compiled release

Hi! I have tested your library for a while and I have not got the release version to work at all.
Check these error-series:

Error: 2018.04.17 00:19:18.711 (+02) [5] In HandleAsyncConnection: System.Reflection.ReflectionTypeLoadException: Unable to load one or more of the requested types. Retrieve the LoaderExceptions property for more information.
at System.Reflection.RuntimeModule.GetTypes(RuntimeModule module)
at System.Reflection.RuntimeAssembly.get_DefinedTypes()
at DM.MovieApi.MovieDbFactory.ApiRequestResolver.GetAvailableConstructors(TypeInfo typeInfo) in C:_dev\github.nCubed\TheMovieDbWrapper\DM.MovieApi\MovieDbFactory.cs:line 179
at DM.MovieApi.MovieDbFactory.ApiRequestResolver.GetConstructor(Type t) in C:_dev\github.nCubed\TheMovieDbWrapper\DM.MovieApi\MovieDbFactory.cs:line 153
at System.Collections.Concurrent.ConcurrentDictionary2.GetOrAdd(TKey key, Func2 valueFactory)
at DM.MovieApi.MovieDbFactory.ApiRequestResolver.GetT in C:_dev\github.nCubed\TheMovieDbWrapper\DM.MovieApi\MovieDbFactory.cs:line 126
at System.Lazy1.CreateValue() at System.Lazy1.LazyInitValue()
at System.Lazy`1.get_Value()
at myapp.myapp_Moviescraper.Query(String sQuery) in C:\Source\myapp\Moviescraper.cs:line 0

My code in Query is this:

    public ArrayList Query(string sQuery)
    {
        var movieApi = MovieDbFactory.Create< IApiMovieRequest >().Value;

        apiSearchResponse = Task.Run(() => {
            return movieApi.SearchByTitleAsync(sQuery);
        }).Result;

        ArrayList pArray = new ArrayList();
        foreach(MovieInfo pMovie in apiSearchResponse.Results)
        {
            DateTime dateTime = pMovie.ReleaseDate;
            pArray.Add(pMovie.OriginalTitle + " (" + dateTime.Year.ToString() + ")");
        }
    return pArray;

This code runs just fine compiled as debug, but crashes as release.
Is this a known problem? Any tips to handle this exception?

Regards. Lars

Exception thrown when call API

I'm new with C#, I followed the sample and got this error. Please help me.

Exception thrown: 'System.InvalidOperationException' in System.Net.Http.dll
Exception thrown: 'System.InvalidOperationException' in mscorlib.dll
private async void materialFlatButton1_Click(object sender, EventArgs e)
{
     MovieDbFactory.RegisterSettings(this.getAPI(), "http://api.themoviedb.org/3/");
     var movieApi = MovieDbFactory.Create<IApiMovieRequest>().Value;
     ApiSearchResponse<MovieInfo> response = await movieApi.SearchByTitleAsync("Star Trek");
     foreach (MovieInfo info in response.Results)
     {
          Console.WriteLine("{0} ({1}): {2}", info.Title, info.ReleaseDate, info.Overview);
      }
}

Runtime error in a Xamarin.UWP project

Using TheMovieDbWrapper in a Xamarin Forms UWP project I get the following runtime exception:

An exception of type 'System.PlatformNotSupportedException' occurred in mscorlib.ni.dll 
but was not handled in user code
Additional information: The value 'False' is not supported for property 'PreAuthenticate'.

I fixed it by removing line 145 from ApiRequestBase.cs:

PreAuthenticate = false,

This should have no side-effects as PreAuthenticate defaults to false anyway. Could submit a pull-request with this.

Need more Person information

The MovieCastMember object has a PersonId and Name, which represents the name of the actor. Is it possible to get any more information about the actor, like DOB, Bio, etc?

JsonReaderException

When using IApiPeopleRequest.FindByIdAsync() (retrieving cast members for top rated movies), I get the following unhandled exception:

Newtonsoft.Json.JsonReaderException: Could not convert string to DateTime: 1994. Path 'birtday', line 1, position 226.

Wouldn't it be appropriate for your Json serialization code to include an error delegate for handling DateTime parsing errors like this one?

ApiTvShowRequestTests Fails with Game of Thrones Search

SearchByNameAsync_GameOfThrones_Returns_PopulatedGenres() needs to be updated to accommodate two search results being returned; as of a month or two ago, there was only a single result.

response.Results
Count = 2
    [0]: {Game of Thrones (1399 - 2011-04-17)}
    [1]: {Autópsia Game Of Thrones (138757 - 2020-04-14)}

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.