Comments (19)
Hmm I'm looking at it now, I'm thinking a way around it would be to save a timestamp in ms when you pause then pass that back when you play it again. I'll try to figure something out with that.
from googleplayechomusicservice.
Cool It would be amazing to figure that out. Would you use flask-ask to get the timestamp in ms? We would have to "restart" the song with the offset included since the .resume()
function won't take it.
from googleplayechomusicservice.
Right now I'm using Python's time library. I have that working sort of.. my timestamps are off at the moment so if you let it sit too long (I'm talking like less than a minute here) the offset becomes greater than the length of the song and nothing plays back.
from googleplayechomusicservice.
I need to take into the account the song length right now, if I can get that I'll have it pausing and resuming no problem.
UPDATE:
Looks like songs returned have a durationmillis associated with them.
from googleplayechomusicservice.
I'm capturing the time when the song is acquired and then subtracting that from the time it's paused to use later for the resume. There's a bit of an offset to it.
from googleplayechomusicservice.
Sweet! I've been working on playing playlist support and about have that wrapped up but I need to figure out a better way to choose the playlist, right now it's pretty bad. Is the offset of the offset like 3 seconds or 5?
from googleplayechomusicservice.
Wait, I just looked and you reverted it? Did it not work?
from googleplayechomusicservice.
Pausing and playing again worked fine once but after that the timestamp isn't exactly right I think so I reverted it. I have a development branch for it now. Once I get it sorted out locally I'll push up my branch.
from googleplayechomusicservice.
Okay cool.
from googleplayechomusicservice.
Pushed what I have up to the pause/resume branch, it's not much right now. I'll try to wrap it up when I have some time.
from googleplayechomusicservice.
Looks great so far. I almost have upvote/downvote working but their seems to be a problem with the gmusicapi. I made an issue so hopefully something comes of it.
from googleplayechomusicservice.
Turns out the context dict saves the song offset when it stops, I'm pulling that now so there's accurate pause and resume times. Problem now is that when you resume it doesn't always pick up again, not sure how to fix that at the moment. I've pushed the changes up if you'd like to take a look at them.
from googleplayechomusicservice.
Could you do a wait 5 or something and then try again if it failed?
from googleplayechomusicservice.
maybe wait 2. Does it throw an error message if it doesn't pick up?
from googleplayechomusicservice.
When I resume ngrok gives a code 200 then several 400s afterwards. Sometimes the song picks up but other times it doesn't
from googleplayechomusicservice.
https://github.com/stevenleeg/geemusic so It looks like this guy made a thing like yours too.
from googleplayechomusicservice.
Should we merge our code and features into his?
from googleplayechomusicservice.
👋 damn, I wish I had known about this a few days ago before I started geemusic.
this project looks great though; I'm glad someone else has been working on the same idea 😄 . feel free to open PRs/issues on geemusic if there's anything in this skill that you'd like to see incorporated!
from googleplayechomusicservice.
Hey that's cool! The only reason I started one was because no one else had anything out there. I think it'd be best to merge. I started this as a hobby project to see if I could make it work. I honestly wasn't expecting anyone to pick up on it xD
from googleplayechomusicservice.
Related Issues (3)
- Intent Schema and Sample Utterances HOT 6
- Gee Music link HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from googleplayechomusicservice.