mbklein
I’ve been playing with the Remote Execution smart cell, and it’s been mostly fantastic. Just about everything I was looking for when I made this offhand comment back in May. ![]()
I’m left with two major questions:
-
I’m working on creating a LiveBook that will be mostly focused on interacting with one specific application. I’d like to be able to set the node name and cookie somewhere (maybe in the setup; maybe in a regular cell) and have those become the values (or at least the defaults) used for each Remote Execution smart cell I add. I’d be happy to use secrets for them[1], but it looks like you can’t use a secret or variable for the node name. I suppose the alternative would be to create my own smart cell that uses my target runtime’s settings instead of allowing for user input.
-
I’ve found that I get an error if the Elixir/OTP versions of the livebook environment and the remote are not exactly the same, down to the elixir point release (i.e., Livebook built on
1.15.2-otp-26while my remote runtime is1.15.4-otp-26). Is there a way around that, or is it just how it is? I don’t mind building a livebook container using the same base image as my app, but if there’s another way, I’d love to know it.
[1] Side question: Is it possible to programatically set a secret from a cell (or in the notebook setup) for use in another cell?
Trending in Questions
Other Trending Topics
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #deployment
- #library
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #channels
- #elixirconf
- #exunit
- #discussion
- #code-sync
- #javascript
- #podcasts
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #elixir-ls
- #blog-post
- #ai
- #phoenix_html
- #iex
- #elixirconf-us
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
josevalim
Can you please open up an issue? EDIT: Nevermind, I created an issue here. If you want to explore it and send a PR, it will be welcome: Improvements to remote execution cell · Issue #355 · livebook-dev/kino · GitHub
Which error do you get?
Secrets are env vars, so try setting or overriding “LB_SECRET_NAME”, and let us know how it goes.
jonatanklosko
@mbklein what OTP versions are you using on remote and locally?
mbklein
Will do, thanks.
Wow, I even had the error on my clipboard ready to go, and completely failed to hit paste.
My test remote runtime’s startup log looks like this:
Then I run this in a livebook cell:
Output:
I get the same result if I change the remote function to
fn -> :ok end, so clearly it’s not the code. Both functions work fine if the livebook node and the remote runtime node are on matching versions.I tried setting the env var in the notebook setup, and it didn’t create a secret that I could browse and select in the remote execution cell’s cookie field. But maybe it would work if I create the cookie beforehand and then change its value in code. I’ll play around with it and get back to you.
josevalim
I see. So you need to create a secret, choose it, and then you can replace its value dynamically inside the runtime using
System.put_env/2.mbklein
OTP 26 on both. The only difference when I get the error is the Elixir patch version.
codyjroberts
@josevalim @jonatanklosko super excited to see the remote smart cell. But I’ve been having some issues.
I saw your PRs and reddit post around the fix for
:eprc.call(node, fn -> :ok end)failing on differing OTP/elixir versions, yet I’m seeing the same issue on latest with and without the smart cell. I can’t for the life of me find any documentation around how to get OTP minor/patch versions from the repl though.Error:
Remote node, local livebook (connected via wireguard), and fly notebook all show
and Livebook v0.11.3 (also tried v0.11.2)
:erpc.callworks fine w/ MFA. I’m stumped on how to debug this further and I’m probably doing something silly so figured I’d post here rather than open an issue. Any ideas?josevalim
You need both nodes on 1.15.7+, which means it requires the same version for now but not for future versions.
codyjroberts
Thanks for the reply and sorry for the confusion.
What I’m saying is that the nodes are on 1.15.7. They all return the same value from
System.build_info().josevalim
Can you call
:erpc.call(node, :elixir, :module_info, [])on both nodes and let me know what it returns? Is the vsn attribute the same? Are the OTP versions exactly the same too?EDIT: Nevermind, I know what is wrong. The fix we provided for Elixir is not enough.
josevalim
Can you folks please try Kino’s main? GitHub - livebook-dev/kino: Client-driven interactive widgets for Livebook · GitHub We have pushed a new approach that should work and be more robust across both Erlang and Elixir version changes.