Error when compiling free4chat
This is probably pretty basic but I'm at square one. I get an error when I'm compiling free4chat, a user-contributed elixir app that depends on membrane.
> mix ecto.reset
how do I make sure the membrane dep is built first?6 Replies
Hi @michaelh!
Correct me if I'm wrong, but it appears like the app you're referring to is locking onto the
master
branch of the membrane_rtc_engine
github repo instead of a specific version or commit. This is highly discouraged and should never be done, as the Engine is under constant development and its API can change between releases.
The reason you're seeing this specific error is due to a restructure of the repo we've done around half a year ago. Starting with v0.16.0, you have to explicitly specify the Endpoints you're using (in your case, probably only membrane_rtc_engine_webrtc
) as well as the membrane_rtc_engine
package.
To fix this error, try replacing the relevant line in mix.exs with
I can't guarantee that this will make the app compile, though, as there may have been changes to the API since the restructure. You might need to roll back the Engine version a bit and find the most recent one that works.
If the app you've mentioned is still maintained, you might additionally want to notify their maintainers of this issue 😉@sgfn hey thanks, that actually helped a lot and I'm at the point where I'm just hitting runtime errors due to library deprecation.
so for rtc engine
0.6.0
it looks like there is no longer a Membrane.RTC.Engine.Message.MediaEvent
because I got this error:
so I know my choice is either to rollback or fix the error. What would you recommend? Would it be as simple as trying to find the changelog for the rtc engine in the attempt to upgrade the codebase or maybe just rollback?
UPDATE: after trying to rollback both dependencies, I keep running into conflicts. Looks like I'll have to learn more about membrane in generalRollback will definitely be easier, especially if you're not too familiar with Membrane
This version of the engine is rather ancient. You certainly won't find any upgrade guides, and the changelogs will probably be limited to github autogenerated release notes, so it will be an arduous task to upgrade it
Yeah, it's easy to end up in dependency hell when dealing with all of the packages. I'd suggest looking at the time when that app was first written and trying to find a version that was around then
Ok I’ll give it one more try
I almost got this to compile with these dependencies but because I need
SimulcastConfig%{}
from a newer library, compilation fails
but I get this error:
Strangely, this is in a much newer library:
https://hexdocs.pm/membrane_rtc_engine_webrtc/0.1.0/Membrane.RTC.Engine.Endpoint.WebRTC.SimulcastConfig.htmlEndpoint.WebRTC.SimulcastConfig
was part of membrane_rtc_engine
prior to v0.16.0.
Try {:membrane_rtc_engine, "== 0.6.0"},
. This was the last version with the :default_encoding
key in this structThat was it! It compiled. Thanks