Fork me on GitHub
#hyperfiddle
<
2023-09-21
>
grounded_sage16:09:55

What is the relationship here: HYPERFIDDLE_ELECTRIC_APP_VERSION clj -M -m prod HYPERFIDDLE_ELECTRIC_SERVER_VERSION jvm property must be set in prod I have tried setting the environment variable to HYPERFIDDLE_ELECTRIC_SERVER_VERSION and running the prod from clj. I'm doing some interesting stuff with my builds and need a deeper understanding of this.

Dustin Getz17:09:17

where did you see HYPERFIDDLE_ELECTRIC_APP_VERSION

Dustin Getz17:09:50

and what version of electric are you running

grounded_sage18:09:00

• electric-starter-app • version: v2-alpha-422-g96e5c0a5 Seen in the readme for how to do a build. HYPERFIDDLE_ELECTRIC_APP_VERSION=git describe --tags --long --always --dirty

Dustin Getz18:09:22

currently the app's git sha is baked into the client by the build and passed into the server as an env variable

Dustin Getz18:09:45

they must match, if they do not match the client will refresh (assuming that it has become stale from a deploy)

Dustin Getz18:09:58

you absolutely must do this

Dustin Getz18:09:16

if the client and server don't match, undefined behavior

Dustin Getz18:09:18

soon this will be taken care of automatically, the electric build will bake everything automatically into both client and server – i have this on a branch but it hasn't landed yet unfortunately

grounded_sage18:09:47

I’m doing some a packaging for distribution as a local app on different OS’s so I’m in new territory and unsure exactly what is happening. Just noodling at debugging it atm.

grounded_sage18:09:41

It might even be stripping it out.

grounded_sage18:09:58

How do I run “clj -M -m prod” ?

grounded_sage19:09:24

Got it working. A config issue on my end. Yay! got Electric running as a native mac app.

🎉 1
😁 1
Vincent20:09:16

@dustingetz a bit off topic but could you please elaborate on the concept that "the world is best modeled by differential equations" ? i think it is really intriguing and wonder if you could elucidate some

❤️ 1
Dustin Getz23:09:49

DEs describe forces and the evolution of the state of a particle or system under forces

Dustin Getz23:09:11

i have a book quote i’ll try to find tomorrow

Dustin Getz15:09:39

in other words the universe does not have mutable state, that is a made up concept caused by our models of computing

😮 1
🔥 1
joshcho04:09:49

also, personally not too familiar with DE, but i recall a close friend telling me DE and dynamics (linear or otherwise) explain much of the world

joshcho04:09:06

he’d read ML papers (phd atm) and see implicit dynamical systems everywhere

joshcho04:09:46

bringing this back to PL, i think the imperative model is very “unmathematical”. it’s not elegant and has low compression. FP is elegant, if you do Haskell it feels like you are playing with math

joshcho04:09:17

but also the limitations are there. i personally don’t think we have cracked it; FP is unsuited for time (a critical component for compute). if manual calculations are imperative and algebra is FP, then what is DE? maybe reactivity

joshcho21:09:57

Anyone else building more commercially facing projects (startups) via electric? Curious the advantages/disadvantages

Vincent21:09:24

I am building one. Advantage: can iterate quickly disadvantage: good luck finding a co-founder

👍 1
Vincent21:09:19

developing in electric is a joy, and the real-timeyness "out-of-the-box" is very apt for certain applications. if you have a good-to-great-to-excellent use-case, you will save lots of development time and eliminate entirely complexity around transmissions between server and client.

Vincent21:09:54

to do more nuanced things like client/server/client/server step-wise interactings, you can use locking mechanisms beween layers of (e/client ... (e/server ...)) blocks via atoms. but in the general case, you have a transparent lens into the database from the client and that can also lens through the server as need be. there is a paradigm shift in thinking required, not even GPT4 is good at electric yet but can pick it up well if you provide [rich] examples and ask for transforms. for a real-time shared-state canvas of sorts, it is really quite amazing. i have leveraged other clojurescript libraries in the past to develop cljs front-ends and then separately clj backends to accomodate the data needs and message-passing needs, but now with electric i essentially focus only on client-side development that allows me to transparently engage the server when need be within sub-blocks of the client invocations. that is certainly a significant complexity reduction/diminishment. however, if you are building a complex app, you must use version control, and you must proceed in a very nimble and tip-toe mode so as not to cludgeon working components. if you stray too far from working code with "imagined working code" you might find yourself with a brick and needing to rollback. this happens occasionally i think namely due to the very wonderful realtimey differential system of transmissions, and my tendency to have fat fingers. but for a small shop, or a one-person endeavor it can be a boon because needing chat-room functionality or shared-canvas functionality or user messaging functionality (not out of box but theoretically straightforward to extend for), you can now be a handful of engineers tackling the real problem while figuring out the optimal interface (also part of the problem) and that means you can compete with big giants who have big teams to build extensive apis for message-passing purposes

👍 1