other-languages

pavlosmelissinos 2022-11-25T10:49:23.758389Z

How many of you have switched to Clojure from Python and has any of you gone through http://hylang.org/ as an intermediate step? It has seamless bidirectional interop with Python, so I'm wondering if it could give Python people a taste of (kinda) Clojure and perhaps nudge them to this side 🤔

whilo 2022-11-28T06:46:11.651169Z

You can abuse hy-lang to macroexpand Python from Clojure https://github.com/plai-group/daphne/blob/master/src/daphne/hy.clj#L193

Frank C. 2022-11-25T12:15:04.544359Z

I think hylang is too esoteric for this step. I checked it out because I'm interested in Lisps. I would guess people going from Python to Clojure are more interested in the specifics of Clojure than in Lisps themselves. One dev I know is very interested in Clojure because of the REPL -- but only because Clojure has mainstream creds. Will he investigate other Lisps? Not a chance. Unfortunately.

🤔 1
pavlosmelissinos 2022-11-25T12:17:21.560899Z

hylang is not exactly Clojure but, last I checked, it's much closer to it than other lisps iirc

pavlosmelissinos 2022-11-25T12:21:00.344139Z

It's probably easier (for a Python developer) to write a python module in hylang than to start a project in Clojure from scratch (and have to learn CLI/lein & find replacements for your libraries if you write specialized code, e.g. data science).

walterl 2022-11-25T13:37:49.131269Z

> "switched to Clojure from Python" Didn't get here "through" Hy, but did have a look at it as a potential way to use Clojure in Python space. Hy wants to allow writing Python code with a lisp/Clojure-inspired syntax, while I'm looking for something that would bring the core Clojure ideas and values (immutability, simplicity, interop, etc.) to Python, including the syntax. Basically, I'm looking for a Python-hosted Clojure, in the same vein as ClojureScript, ClojureDart and ClojureCLR. One day I'll write it if someone else doesn't 😅🤞. For now I'll settle for using https://pyrsistent.readthedocs.io/en/latest/intro.html whenever possible. 🙂

☝️ 1
🤔 1
pavlosmelissinos 2022-11-25T14:29:09.183469Z

A Python-hosted Clojure would indeed be very nice... I doubt I'd ever start a greenfield project in hylang. I think its niche is sprinkling Clojure-like bits over an existing Python project.

robertfw 2022-11-25T19:11:54.184559Z

I came from Python, but not via Hy. I'd been dabbling with Clojure for quite a while, then got a job at a very functionally-oriented python shop who wanted to start using some Clojure.

🤘 1
pavlosmelissinos 2022-11-25T19:16:58.662859Z

Nice! Well done, hope you're happy there 🙂

robertfw 2022-11-25T19:18:07.950229Z

Sadly our whole team got laid off at the end of 2020 😛

😞 1
pavlosmelissinos 2022-11-25T19:19:26.817499Z

Damn, I'm sorry to hear that.

robertfw 2022-11-25T19:19:58.991549Z

Ancient history now, and a great lesson in spotting signs that your acquiring company is only interested in your tech, not your team

💯 2
2022-11-25T19:24:37.414909Z

It's not really quite what you're looking for but https://github.com/clj-python/libpython-clj also seems relevant. It allows nice access to python from (jvm) clojure

👍 2