Last.FM Rework and Auto DJ mode | Page 30

Discussion in 'Area 51 - Testing Area' started by jameson_uk, February 8, 2013.

  1. Sebastiii
    • Team MediaPortal

    Sebastiii Development Group

    Joined:
    November 12, 2007
    Messages:
    16,270
    Likes Received:
    6,221
    Gender:
    Male
    Location:
    France
    Ratings:
    +10,229 / 9
    Home Country:
    France France
    Show System Specs
    So i think it crash here :
    Code (Text):
    1. /// <summary>
    2.     /// Attempt to get XML web response via HTTP
    3.     /// </summary>
    4.     /// <param name="querystring">Querystring to be passed to webservice</param>
    5.     /// <param name="httpMethod">GET or POST</param>
    6.     /// <param name="useHttps">Whether to use HTTPS</param>
    7.     /// <returns>The xml returned by Webservice</returns>
    8.     /// <exception cref="LastFMException">Details of last.fm error or will wrap actual exception as inner exception</exception>
    9.     private static XDocument GetXml(string querystring, string httpMethod, bool useHttps)
    10.     {
    11.       HttpWebResponse response;
    12.       XDocument xDoc;
    13.       var url = useHttps ? BaseURLHttps : BaseURL;
    14.       if (httpMethod == "GET")
    15.       {
    16.         url = url + "?" + querystring;
    17.       }
    18.  
    19.       bool webExceptionStatus = false;
    20.       var postArray = Encoding.UTF8.GetBytes(querystring);
    21.       var request = (HttpWebRequest) WebRequest.Create(url);
    22.       request.Method = httpMethod;
    23.       request.ServicePoint.Expect100Continue = false;
    24.       if (httpMethod == "POST")
    25.       {
    26.         request.ContentType = "application/x-www-form-urlencoded";
    27.         request.ContentLength = postArray.Length;
    28.         var s = request.GetRequestStream();
    29.         s.Write(postArray, 0, postArray.Length);
    30.         s.Close();
    31.       }
    Can you try attached bin ?


     

    Attached Files:

  2. Google AdSense Guest Advertisement



    to hide all adverts.
  3. seco
    • Team MediaPortal

    seco Development Group

    Joined:
    August 7, 2007
    Messages:
    1,579
    Likes Received:
    897
    Gender:
    Male
    Ratings:
    +1,234 / 4
    Home Country:
    Finland Finland
    Show System Specs
    Too busy with fontEngine stuff now, I tested with build from "Early 1.6.0..." thread, unfortunately I had my modified Core.dll on but I really think it should not matter in these cases.

    I think that for b) the problem is just that the processing is done in a separate thread without error handling -> all errors lead to hard-crash. In this case error is probably just a connection timeout to Last.FM site.
     
    • Like Like x 1
  4. royne

    royne Portal Member

    Joined:
    January 4, 2007
    Messages:
    41
    Likes Received:
    2
    Occupation:
    Project Leader and progammer
    Location:
    Asker
    Ratings:
    +2 / 0
    Home Country:
    Norway Norway
    Show System Specs
    Hi
    I have a valid Subscription in Norway for last.fm, but i cant get Radio to work. (Autoscrobler Works fine).
    Radio is ok when using it With web/IE, but in MP i get this Message:
    "radio station not supported with this country/client combination"

    Why does last.fm work in IE but not in MP 1.6 ?
     
    Last edited: January 5, 2014
  5. jameson_uk
    • Premium Supporter

    jameson_uk Retired Team Member

    Joined:
    January 27, 2005
    Messages:
    7,258
    Likes Received:
    2,228
    Gender:
    Male
    Occupation:
    Data Warehousing Consultant
    Location:
    Birmingham
    Ratings:
    +2,405 / 0
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    • Like Like x 1
    • Thank You! Thank You! x 1
    • Agree Agree x 1
  6. royne

    royne Portal Member

    Joined:
    January 4, 2007
    Messages:
    41
    Likes Received:
    2
    Occupation:
    Project Leader and progammer
    Location:
    Asker
    Ratings:
    +2 / 0
    Home Country:
    Norway Norway
    Show System Specs
    Thanks, I liked to use last.fm radio (no need to act as a DJ) This seems to be difficult from all countries except UK, Germany and US :(
    Is the country sendt to last.fm via the API?
     
  7. jameson_uk
    • Premium Supporter

    jameson_uk Retired Team Member

    Joined:
    January 27, 2005
    Messages:
    7,258
    Likes Received:
    2,228
    Gender:
    Male
    Occupation:
    Data Warehousing Consultant
    Location:
    Birmingham
    Ratings:
    +2,405 / 0
    Home Country:
    United Kingdom United Kingdom
    Show System Specs
    It is based on your IP address /ISP
     
    • Like Like x 1
  8. seco
    • Team MediaPortal

    seco Development Group

    Joined:
    August 7, 2007
    Messages:
    1,579
    Likes Received:
    897
    Gender:
    Male
    Ratings:
    +1,234 / 4
    Home Country:
    Finland Finland
    Show System Specs
    It would be nice if this would be a separate plugin in the future, I don't think it should ship with default MP setup. Maybe when blowing WindowPlugins to separate projects is done (see Area-51).
     
    • Agree Agree x 1
  9. edterbak
    • Team MediaPortal

    edterbak Test Group

    Joined:
    March 4, 2008
    Messages:
    2,114
    Likes Received:
    736
    Gender:
    Male
    Occupation:
    Researcher
    Ratings:
    +1,178 / 5
    Home Country:
    Netherlands Netherlands
    Show System Specs
    Same maybe for Minidisplay?
     
  10. Peter2
    • Premium Supporter

    Peter2 MP Donator

    Joined:
    September 18, 2006
    Messages:
    848
    Likes Received:
    45
    Ratings:
    +52 / 1
    Home Country:
    Belgium Belgium
    Show System Specs
    Hi guys,
    What is that numeric field in the plugin - in my case it holds the number 100.
    P.
     
  11. olli14

    olli14 Portal Pro

    Joined:
    December 17, 2008
    Messages:
    738
    Likes Received:
    19
    Ratings:
    +31 / 5
    Home Country:
    Germany Germany
    Show System Specs
    I'm on Mediaportal 1.3 final and want to test this plugin. What do I have to do? Do I have to make a clean re-install?

    olli14
     
Loading...

Users Viewing Thread (Users: 0, Guests: 0)

  1. This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
    By continuing to use this site, you are consenting to our use of cookies.
    Dismiss Notice
  • About The Project

    The vision of the MediaPortal project is to create a free open source media centre application, which supports all advanced media centre functions, and is accessible to all Windows users.

    In reaching this goal we are working every day to make sure our software is one of the best.

             

  • Support MediaPortal!

    The team works very hard to make sure the community is running the best HTPC-software. We give away MediaPortal for free but hosting and software is not for us.

    Care to support our work with a few bucks? We'd really appreciate it!