kodi-czsk / plugin.video.sosac.ph

GNU General Public License v2.0
17 stars 31 forks source link

Trakt.tv + sosac library #25

Open sprattek opened 8 years ago

sprattek commented 8 years ago

Nazdar,

skusal som rozchodit synchronizaciu trakt.tv s kniznicou zo sosacu ale bez uspechu, pretoze .strm subory neposkytuju dostatocne info. Log hadze rovnaku chybu ako tu https://github.com/trakt/script.trakt/issues/227 a v tomto vlakne je uvedene ake info treba k uspesnemu scrobblovaniu https://github.com/trakt/script.trakt/wiki/Providing-id%27s-to-facilitate-scrobbling , je mozne s tym nieco robit alebo sa to tyka sosacu ako takeho? Tisicere diky.

co5mo commented 8 years ago

mne to synclo bez problemov strm nemaju obsahovat ziadne dodatocne info (je to ako avi) ked potrebujes extra info vygeneruj nfo ku kazdemu strm cez Ember Media Manager

sprattek commented 8 years ago

To je zaujimave, takze ak si pustis nejaky film/serial hned ti to nabehne na trakt.tv? Samotna synchronizacia kniznice zbehla aj mne ale len ked dam manualne spustit plugin, nefunguje mi automaticky scrobble, ten hodi tuto chybu:

09:29:29 T:1846063880   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - {u'item': {u'type': u'unknown', u'label': u' - Stesk'}}
09:29:29 T:1846063880   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Started playing a non-library file, checking available data.
09:29:29 T:1879072032   DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 0
09:29:29 T:1846063880   DEBUG: [script.trakt] service: [traktPlayer] info - ids: , showtitle: , Year: , Season: , Episode:
09:29:29 T:1846063880   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Non-library file, not enough data for scrobbling, skipping.

V kazdom pripade dakujem a skusim ten manager ci nepomoze.

co5mo commented 8 years ago

scroble novych spusteni som neriesil neviem... ale asi pomoze pridat nfo

sprattek commented 8 years ago

hmm....no ak to chapem spravne a je docela mozne ze nie, tak tuto srandu by bolo fajn dat niekam do scriptu:

ids = json.dumps({u'tmdb': 264660, u'imdb': u'tt0470752', u'slug': u'ex-machina-2014', u'trakt': 163375})
xbmcgui.Window(10000).setProperty('script.trakt.ids', ids)

samozrejme nahradit prislusne idcka tak aby sedeli so spustenym suborom, problem je ze netusim kam ten kusok scriptu pridat a cim nahradit placeholdre

co5mo commented 8 years ago

skus plugin od lambda genesis a jeho librarty integraciu ci ti scrobne len ako test.. ci to ma niekto funkcne

sprattek commented 8 years ago

Genesis pracuje s trakt.tv uplne fajnovo aspon co sa tyka spustenia suboru priamo cez addon, este skusim nahodit nieco do library ci to pobezi tiez bez problemov.

sprattek commented 8 years ago

Co sa tyka genesisu asi sa oplati pozriet na tieto dva subory kde maju trakt.tv implementovany, mne osobne to nic moc nehovori ale vam borci asi hej:

https://github.com/lambda81/lambda-addons/blob/master/plugin.video.genesis/resources/lib/libraries/player.py https://github.com/lambda81/lambda-addons/blob/master/plugin.video.genesis/resources/lib/libraries/trakt.py

sprattek commented 8 years ago

Potvrdzujem funkcnost automatickej synchronizacie aj pri spusteni filmu z kniznice cez Genesis.

edit: v tomto logu bol spusteny film San Andreas z kniznice najprv cez Genesis a potom cez Sosac, v prvom pripade vsetko fici ako ma a v druhom nie.

14:35:35 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - {u'item': {u'type': u'unknown', u'label': u'San Andreas (2015)'}}
14:35:35 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Started playing a non-library file, checking available data.
14:35:35 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] info - ids: {"imdb": "tt2126355"}, showtitle: , Year: , Season: , Episode:
14:35:35 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Playing a non-library 'movie' - San Andreas (2015) (NaN).
14:35:35 T:1848148336   DEBUG: [script.trakt] service: Queuing for dispatch: {'action': 'started', 'video_ids': {u'imdb': u'tt2126355'}, 'type': 'movie', 'title': 'San Andreas (2015)'}
14:36:15 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - {u'item': {u'type': u'unknown', u'label': u'San Andreas (2015)'}}
14:36:15 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Started playing a non-library file, checking available data.
14:36:15 T:1945407864   DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 1
14:36:15 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] info - ids: , showtitle: , Year: , Season: , Episode:
14:36:15 T:1848148336   DEBUG: [script.trakt] service: [traktPlayer] onPlayBackStarted() - Non-library file, not enough data for scrobbling, skipping.
sprattek commented 8 years ago

Ako sa tak prehrabavam kodom predpokladam, ze jedine co treba dohodit do sosacovho pluginu je nieco taketo:

class player(xbmc.Player):
    def __init__ (self):
        xbmc.Player.__init__(self)
    def run(self, content, name, url, imdb, tvdb):
        self.getVideoInfo(content, name, imdb, tvdb)
    def getVideoInfo(self, content, name, imdb, tvdb):
        try:
            self.imdb = 'tt' + imdb if imdb.isdigit() else imdb
            self.tvdb = tvdb if not tvdb == None else '0'
        except:
            pass
        try:
            if self.content == 'movie':
                xbmcgui.Window(10000).setProperty('script.trakt.ids', json.dumps({'imdb': self.imdb}))
            elif self.content == 'episode':
                xbmcgui.Window(10000).setProperty('script.trakt.ids', json.dumps({'tvdb': self.tvdb}))
        except:
            pass

Problem je, ze neviem ako ani kde a ci by to vobec fungovalo. V kazdom pripade ide len o to zistit imdb/tvdb id spusteneho suboru a dohodit ho do 'script.trakt.ids' o ostatne by sa mal uz postarat plugin trakt.tv

sonics007 commented 8 years ago

A načo je vlastne trakt. Tv?

sprattek commented 8 years ago

Hmm no uvediem to na priklade, ked sa ma niekto opyta ci som nevidel nejaky dobry film, vzdy odpoviem, ze nie lebo si uz proste nepamatam, trakt.tv v spojeni s kodi ti automaticky film co si dopozeral hodi na tvoj profil a mozes ho ohodnotit , takze ziskas svoju databazu videnych filmov + mas syncnutu kniznicu priamo na trakt.tv, rozne grafy, progress serialov atd atd

greedyyy commented 7 years ago

zdravim, pracuje sa na tom? ocenil by som spolupracu s takt tak ako to ma exodus.

lzoubek commented 7 years ago

Nevim o nikom, kdo by na tom momentalne pracoval

iChUdY commented 7 years ago

Plná podpora Trakt.tv tzn.: One click subscription, trakt manager, automatic watched(local + trakt) je poslední věc, která tady k plnohodnotnému používání chybí... vyřešilo by se tím v podstatě všechno co v Sosáči oproti ostatním doplňkům chybí. Dle mého největší priorita v budoucím vývoji 🍀

co5mo commented 7 years ago

este by som prijal resume streamu a mark watched v library to dokaze napriklad specto/exodus

E000001 commented 6 years ago

Podpora by se hodila :)