ricardomatias / ableton-live

A library for communicating with Live via WebSockets, works both in NodeJS and in the Browser.
https://ricardomatias.net/ableton-live/
79 stars 10 forks source link

Issues with Ableton 11.3.20 #24

Closed f-f closed 9 months ago

f-f commented 10 months ago

Hi - I was happily using this on Ableton 11.3.13, but it seems to have stopped working now that I am on version 11.3.20 (I double checked this on a different machine that was running .13, and later upgraded that one to .20 as well, and I replicated the failure)

The error I'm getting is that track.volume() crashes with TypeError: Cannot read properties of undefined (reading 'id'), but that seems a symptom of overall funkiness: all track.id and track.name are 0, and live.song.children("track") only returns midi tracks.

So something is quite off somewhere - I went looking for the changelog, and the most relevant change seems to be the "Updated the bundled Max build to version 8.5.6", so maybe something in Max changed?

I know nothing about Max so I am not sure where to look for more info on how to debug this, but I'm happy to assist.

f-f commented 10 months ago

Hm, I get this even after I downgraded to 11.3.13, so I wonder if some internal settings were updated

f-f commented 10 months ago

I found the Max editor and got some logs, it doesn't seem very happy:

image
f-f commented 10 months ago

It seems like the above errors appear once I call const tracks = await live.song.children('tracks');

Repro in the node repl:

global.WebSocket = require('ws');
const { AbletonLive } = require('ableton-live');
const live = new AbletonLive();
await live.connect();
const tracks = await live.song.children('tracks');

Produces this log in a fresh live set:

image
f-f commented 10 months ago

Hmm, I tried to verify things worked on an entirely different machine running 11.2, and it still fails in the same way, so I am pretty confused right now. This is using Node 18.18.2.

f-f commented 9 months ago

Closing as there doesn't seem to be any activity here

ricardomatias commented 9 months ago

Hey @f-f, I didn't have time till now to look at it. I'm reopening this to use as the base issue for the problem since it has relevant information.

f-f commented 9 months ago

No worries @ricardomatias, we all busy 😄 I was just in a hurry because I have a performance in a few days and I needed my setup to work, and it seemed irrimediably broken after the update (i.e. even downgrading Ableton didn't fix it), so I switched to this thing in the meantime (which I'm now happy about because I don't know enough Max to properly debug things in haste) - all of this to say that I won't need the fix myself anymore. Nonetheless, thanks for putting this thing together, I enjoyed it 🙂

ricardomatias commented 9 months ago

@f-f I understand your situation.

Bug is fixed with 0.0.11 release.

f-f commented 9 months ago

Is that pushed? I don't see it on the repo page

ricardomatias commented 9 months ago

My bad, I thought git push --tags uploaded code + tags, but it's only tags. Now it's up.

f-f commented 9 months ago

Lovely, JS' null vs undefined bites once more 🙂