How’s everybody eating their corn?
http://bentilly.blogspot.com/2010/08/analysis-vs-algebra-predicts-eating.html
It probably means that you don't like constraints. The question was how you eat corn cobs, not if you'd rather eat something else! But it seems you are free to invent yet another strategy to deal with cobs.
For me, it's spirals. Not sure I accept all the apparent consequence though ;-)
I’m a row person and definitely algebra oriented. I haven’t programmed that much so it’ll be interesting to see where I’m drawn to in programming in the future.
I've been thinking for awhile of writing something about the historical user interfaces that aren't much talked about (i.e. not the Alto -> Mac -> Windows lineage). In this instance, I decided to do a "tweet storm" instead of a blog post to see if that would be a more effective way to get the ideas into the world. As this is probably of interest to the community, I thought I should link to it here as well. The entrance to this particular Garden of Forking Paths:
https://twitter.com/jackrusher/status/1300737671497691136?s=20
🐦 ⸘Jack Rusher‽: I've been thinking about roads not taken lately, wondering whether we should revisit some of them... https://pbs.twimg.com/media/Eg0l3uGXsAAD_Aa.png
https://news.ycombinator.com/item?id=23811382 great post on the lisp REPL’s difference from other REPLs. sidenote: can someone explain to me how lisp programmers go from talking to the REPL to updating the code in their source files? in talks and stuff it always seems to be with copy and paste. is that accurate?
Your question has been a long-standing frustration for me with all REPLs. The dominant way I've seen people deal with it is by not typing directly into the REPL, but keeping their queries in a text editor and then sending them to the REPL with a keystroke. Which feels quite barbaric. I'd rather Alt-Tab and run a command on a shell at that point. But I seem to be in the minority there.
For me (and many clojure programmers I know). There is no distinction between working at the repl and editing the source code. I build the program in the file and have an active running repl connected to that file/project. In fact, I can even load up multiple projects in one repl and work on changes across them. So if I have some library I depend on I can load up it's code, edit it, evaluate it, and have those changes reflected live in my program.
I never do any copy and paste. I am working with a live running program and I can do all sorts of things with that. One example is testing out failure modes and simulating in real time systems going down and coming back up, watching how the system handles it.
Another is what I've called interactive integration tests. I have some namespace of code that is meant to be run at the repl. It imports parts of my apps and lets me combine them in various ways to test the live working system, but fully parameterizable.
This flow is the main reason I enjoy programming in clojure so much. I get immediate feedback and a much closer connection to my program.
I'd love to hear more.
There is no distinction between working at the repl and editing the source code.
Does typing something at the repl add it to the file open in the editor?
testing out failure modes and simulating in real time systems going down and coming back up, watching how the system handles it.
How do you turn the manual test into a reproducible automated one?
Does typing something at the repl add it to the file open in the editor?
The opposite I am just typing in the file. I know you mentioned sending them to the repl, that is kind of sort of what is happening. But there isn’t some separate repl window I am sending text to. I am just typing and evaluating code. The repl is a background process. I can pull it up and type in it directly, or see print statements there. But generally, I just see the results of my evaluation in line, or in a bigger pretty print buffer. Here is little gif of that (with lots of typos)
📷 repl.gif
How do you turn the manual test into a reproducible automated one?
Once it is in the shape I want, wrap on assert around it and make sure it is where my test runner picks it up. But many times that isn’t the point of the code. It is for a continually evolving system and I am just trying to understand it more, test the bounds, explore data, etc.
Interesting. I would say you aren't really using a repl here, you are evaluating 'in line' (even if what is happening under the covers is that the text is being sent and received via a repl). Perhaps that's the standard way of working, but like Kartik Agaram, I think I expected you to hop into another repl buffer.
But there isn’t some separate repl window I am sending text to. I am just typing and evaluating code. The repl is a background process.
Ah, I see. That is cool. I wouldn't call this a REPL, the REPL is just an implementation detail at this point. But it feels perfectly self-contained and internally consistent without needing a REPL. 👍 👍
I am using a repl. But a repl in the lisp sense isn’t a user interface. It is a process. There is read-eval-print-loop. I am doing that just sending the print back to my editor. It also exposes an interface which is what people think of as a repl. But the two are connected you can just go back and forth. (at the end I pretty print, small value here so no real difference, just showing it can do that too)
Just to add a bit more flavor to all of this. My repls are usually left open for as long as my computer is running. At work, I usually have 6-10 repls running in the background of various projects. I will have a repl open for weeks or months at a time. I can often go from scratch to full working project and never kill my repl, just continuing to refine my program.
When I was learning some neural network stuff, I had an aws machine with a beefy gpu. I had a remote repl on the machine, would run my training overnight, reconnect to the running repl and see the results in some var.
I truly can’t imagine being as productive without this sort of setup. It changes not only how you code, but what you code. I can immediately tell Clojurians who don’t use a decent repl setup from how they structure their code.
I see what you mean. It sounds really cool, a state I've read about but never experienced, where the program is effectively immortal: http://steve-yegge.blogspot.com/2007/01/pinocchio-problem.html
I can immediately tell Clojurians who don't use a decent repl setup from how they structure their code.
I've encountered something similar from the opposite direction. I always found all the architecture astronomy Java programmers got into to be extremely frustrating -- until I started using an IDE and realized that they were using operations that their tooling made much easier than it was for me in Vim.
This is why C++ programmers write longer functions than Java programmers: the C++ grammar is context-sensitive and harder to build an IDE for. Which connects up neatly with another thread this morning, with @Jason Brennan: https://futureofcoding.slack.com/archives/C5T9GPWFL/p1599495354127000?thread_ts=1599070210.092100&cid=C5T9GPWFL
There is read-eval-print-loop. I am doing that just sending the print back to my editor. It also exposes an interface which is what people think of as a repl.
This should seem like pedantic philosophical hairsplitting, but I'm finding it interesting for some reason. The way I see it:
Your environment allows showing values of variables anywhere.
For historical reasons, it does this by using a REPL behind the scenes.
Since there's a REPL, it exposes it to you that you could use.
But as you said, you don't normally use the REPL. That says to me you have something better. There's a spatial component here that sounds awesome. While it's technically correct to call it a read-eval-print-loop, I think that understates the value.
[September 7th, 2020 9:15 AM] ak: <@U01286RNB70> the original thread seems to be about designing languages. I interpret that as about designing textual programming languages. Does prototyping those still have a limitation with text files? (Earlier phases certainly benefit from the ability to draw lines and boxes and so on.)
In general I'm a bit bemused by this thread. As a programmer it all feels quite waterfall-y. If you try to "mock up" a language before giving it a grammar you're quite likely to end up introducing ambiguities that need modifying the language to resolve. Similarly with many other aspects of the activity. If an activity eventually needs to be mapped on non-linear primitives (as computer programs do), it seems to me that it benefits from lots of feedback loops.
Funny story: the original waterfall diagram [1] had feedback loops between phases, so even waterfall practiced right can be quite effective. Of course, that's not what anybody means by the term anymore..
[1] http://www-scf.usc.edu/~csci201/lectures/Lecture11/royce1970.pdf, figure 3
There are people in the clojure community that take that point to the pedantic level and would say that technically I don't have a repl at all because I am not using the built-in one. I ignore that discussion.
What I actually find more interesting is the fact that actually the editor interface and the repl interface are both just interfaces over the process. What is really happening behind the scenes is some separate server process that is running my code and accepting socket connections and sending output to various places. That behind the scenes process is the real repl going on and everything else is just a view on top of it.
Quite similar to Jimmy Miller. If you're interested in further elaboration, I wrote something about my own practices https://clojureverse.org/t/share-the-nitty-gritty-details-of-your-clojure-workflow/1208/8?u=jackrusher.
wow, this conversation has cleared up a whole lot of long-standing questions i didn’t even realize had been nagging me! is there a beginner, out-of-the-box setup for getting a clojure repl working like that?
☝ Yes, I’d like to learn about that too.
And does it have to be a Clojure REPL or can it be any REPL?
This is what I followed back in the day. Probably a more up to date one exists somewhere. This is clojure specific. Languages really have to be built
with this workflow in mind to work well with it. I've seen someone do it well with Ruby, but I have had many failed attempts at making a js repl have the properties I want.
If you use a different editor let me know what it is and I can see if there is a decent setup for that.
i use vim but i’d be interested in any vscode setup (or if someone’s written a blogpost for doing lisp repls with evil mode)
Lots of people I know use evil mode. Usually they use it with https://www.spacemacs.org/ Shouldn't be hard to adapt the tutorial I linked but start with spacemacs.
I don't know anyone with a decent vim setup. People do it, but they never have the workflow I show above. (And are typically very proud of that fact).
For vs code I've heard good things about https://calva.io/
Maybe the focus on the REPL is not the best way to approach the topic of this thread. It's a technicality, a detail of implementation. The more fundamental distinction is that between a programming language and a programming system.
In a programming system, there is a system state that includes code and data, and events that update the system state. A particular important type of event is a code update event, but it's just a special case of an instruction sent to the system for updating its internal state. There is no notion of a "program" that you could write, compile, and run. A REPL is a tool to send events to the system, but there can be others, and much better ones, as discussed above. Emacs is such a programming system by itself, and it also become a popular user interface to other Lisp-bases systems such as Common Lisp or Clojure. The other well-known family of programming systems is Smalltalk, which pioneered better-than-REPL interfaces to programming systems.
In contrast, a programming language is designed to write a program, representing a process that runs inside a larger computing system that is considered outside. The process is seen as primarily self-contained, and interaction with the rest of the system is considered exceptional and must be made explicit using relatively cumbersome techniques (I/O, shared memory, etc.).
Both points of view have good and bad points, and what I'd really like to see is a hybrid: a programming system that permits the creation of well-defined subsystems with well-defined interfaces that can be the subject of contracts, type-checking, sandboxing, etc.
Stefan Lesser From my above-linked workflow writeup: "the keybindings I use to perform these operations are the same for every dynamic language I use, so my process is similar from Clojure to Racket to OCaml to Ruby to Python". That said, I strongly prefer using a language whose syntax facilitates easy structural operations. An example of this in the case of Lisp-family languages is that with syntax like (foo (bar 1) (baz 2))
it's trivial to position the cursor after the sub-expression (bar 1)
and evaluate just that, allowing one to tease apart a larger piece of code in order to test/understand it. In languages with more complicated syntax that lack clear scope delimiters it's much harder to make a good UX for this.
Garth Goldwater Also, for a very lightweight introduction to this kind of in-place evaluation, you can take a pass through: https://www.maria.cloud/intro
Back in my day the Lisp image was a source of truth. When you're done for the day, commit whatever image you're working on back into CSV. Source files were there to reset parts of the image. This worked only slightly better than you might expect what with no clean way to merge images.
Jack Rusher i did the maria cloud tutorial a little while ago—it’s one of the things that makes me want to be directly interacting with that kind of system in my development work
@William Taysom this is pretty much what i want lol
Garth Goldwater though we don't keep whole images around these days, we do store whole runs for debugging/testing/auditing. Could work a more smoothly, but there is a direct line from bug report to getting to the same screen on your own development environment.
This from Jack Rusher's nitty-gritty details description is great:
I resist anything that involves a context change (changing windows/buffers, copy/pasting more than absolutely needed, etc) – flow states are sacred.
(https://clojureverse.org/t/share-the-nitty-gritty-details-of-your-clojure-workflow/1208/8)
Compare https://futureofcoding.slack.com/archives/C5U3SEW6A/p1598741044000700?thread_ts=1598713285.112800&cid=C5U3SEW6A. It almost sounds like the world that CA and his acolytes were trying to bring to pass may already exist?!
https://youtu.be/mjVtXfdTZIQ the rebol community is wild. i like this prototype way of building webpages
Roc: a new Elm-derived language for servers, CLIs, desktop UIs, built in Rust, compiles to binary, very alpha rn - talk starts ~1:19:00
Sharing this section of the talk that talks about aspirations for a BVictor-inspired editor that will ship with the language https://youtu.be/ZnYa99QoznE?t=5870
Once upon a time ago, we talked about that for Light Table as well! https://www.chris-granger.com/2012/05/21/the-future-is-specific/
In case the video embed doesn’t work, here’s the video: https://vimeo.com/42595773
Thanks for sharing Christopher Galtenberg!
And after seeing the video I also wanted to share the same screenshot as you! 🙂 Especially the one about the requirements for shipping a package.
I rewrite it here so it can be searchable/copy-pasteable:
It's a cultural norm that > every package> ships with:
Code
Documentation
Custom editor integration
https://youtu.be/R3MNcA2dpts i really, really like the ux model from this demo of a concatenative programming environment—in particular, how the cursor gives you a live update of the stack and the definition of new words at ~2:40. anyone know of any similar projects?
This feels like the same family as loglo which is a stack based spreadsheet programming env
like. direct manipulation of source tokens, and definition of new functions is done by selecting the tokens that you’d like to be the definition and then giving a name
Sorry, my question was just about the first of the two features that you pointed out.
oh—i guess time-travel debuggers let you “step through” code and place your cursor at it, but i’d say that this is different because the emphasis is on like... editing that timestream directly
Some very nice affordances for concatenative programming! Appears abandoned, which is a shame because this deserves further development...
The little exchange between Kartik Agaram and Garth Goldwater is telling: we have come to consider the distinction between writing and debugging code as something fundamental. Which I think is mainly the fault of compilers. There's a development style popular with some Smalltalkers, a variant of test-driven development, in which most code is written in the debugger as a "fix" to failing tests. There is also a lot of overlap with Jonathan Edwards’s work on subtext.
Funny thing was, as I was asking those questions the thing I was really thinking about was Joshua Horowitz's PANE. It seemed somehow undesirable that the UI here had lots of "mutation" going on in the same part of the screen, where "the PANE way" would be to show all the states of the stack at once, which feels nice and "functional/immutable". But that property of PANE is also shared by logs if you set them up right. So I "simplified down" to time-travel debugging.
Bret Victor's "Magic Ink" paper makes the same point: just show all the data so it can be just read, rather than requiring operations to see different peepholes of it: http://worrydream.com/MagicInk/#interactivity_considered_harmful
I finally got around to finishing the video. Extremely thought-provoking. It's kinda interesting to think of PANE and Brief as two poles with complementary strengths and weaknesses (with LoGlo in the uncanny valley in between)
PANE shows everything, but it's less dense. A single value is often printed in multiple places on screen. In Brief there's a designated place for showing runtime values, so less real estate is expended on them.
Brief shows a stack at the top level, but once definitions are created they get 'reified' into textual definitions. This is nice and dense, but solves just one level of the problem of not making me simulate in my head. I kept waiting for the author to show some way to "drill down" into a defined word to visualize how it constructs its intermediate results, but that still seems to be an open problem. It's also a little klunky that there are two ways visually to represent the same expression, one with boxes and the other in plain text.
LoGlo seems to have the drawbacks of both. It doesn't have any way to show intermediate stack states, and it also has no way to drill down into intermediate expressions the way PANE does.
Kartik Agaram In addition to sharing Konrad Hinsen's impression, it also felt in reading that exchange that what stack means is rather special in this sort of language, which would wrong-foot someone who hasn't done a bit of programming in this paradigm.
Very interesting! I agree with previous comments and want to add that something nice here is some kind of programming by example then refactor to extract and create new abstractions.
Jack Rusher Hmm, can you elaborate on how 'stack' is special? I have done a bit of Forth, RPN isn't new to me..
Kartik Agaram What I was vaguely gesturing towards is that in most high level languages the implicit mental model uses variables to represent an unbounded number of pseudo-registers while the stack is a largely invisible piece of machinery that facilitates function calls under the covers. In such a language, reifying the stack is a natural debugging affordance because it reveals that hidden mechanism. In concatenative languages, we invert that mental model by centering the stack and mostly pretending that there are no registers/variables. This makes the feeling of the stack very different in, say, FORTH vs Pascal.
The thing that was mind-bending to me a few years ago was that by splitting up the arg and return address stacks procedures could pass args to callees of callees! There's no well-defined stack-frame.
Finally watched this video and came here to make essentially the point Konrad Hinsen made already.
The phenomenal thing about this is unifying "actual debugging" with "brain debugging". When you are writing and reading code, moving the cursor, you are naturally "running" it and maintaining the state in your head. This offloads that to the computer.
excited for this, Ries has been working on this for like a decade I think. But there’s like 0 details on what makes this different than a regular stock exchange besides “hey guys, we do LT investing here”
The website seems to be a lot of marketing without any actual exchange as far as I can see.
From other places:
but its nothing like a B-corp, which has more strict rules (but is also kinda vague tbh)
I quite like the look of the small exchange over at tastytrade, but I'm done with trading for the time being 😉
Unity released a Lego themed micro-game (basically a small template + tutorial to teach the engine and make small games) today. One of the interesting things about it is adding a set of behavior blocks. In practice they aren't much different than basic triggers and behaviors most level designers have access to, but I'm into environments that take ideas from tangible coding and apply them back to digital spaces
https://blogs.unity3d.com/2020/09/09/create-your-first-game-brick-by-virtual-brick-with-the-lego-microgame
but I'm into environments that take ideas from tangible coding and apply them back to digital spaces
Very much, yes. That'd be a great collection to include in our (eventual) community wiki.
Hey everyone, I found out today that the Alan Kay wiki I made was deleted without notice and cannot be restored. I'm doing my best to restore it from an incomplete 2016 http://archive.org backup but there's definitely stuff missing. Any help would be greatly appreciated, especially the Writing page which has been completely lost. Here's its new home: https://www.notion.so/Alan-Kay-Wiki-0bee993e14874b66b7b9fcfc83a91c92
Argh that's terrible. What happened?.. I always do a wget --mirror
on my online stuff that isn't sourced from my laptop in the first place. No help to you now, of course! 😄
can we use https://tinlizzie.org/IA/index.php/Talks_by_Alan_Kay to help? I think by Yoshiki
it was hosted on wikia/fandom and they just deleted it completely without notice and don't have backups
I mean yeah it just doesn't have the page: https://web.archive.org/web/20160609113912/https://alan-kay.wikia.com/wiki/Alan_Kay_Wiki
I searched for site:
http://www.vpri.org/pdf/ "Alan Kay"
on Google and that surfaces a bunch of writings by Kay. Would need to be curated though.
Lately I try to drop the middle people and just host with archive.org..
I suppose Ctrl-F for Kay here would also work: http://www.vpri.org/writings.php
hm, looks like https://mprove.de/visionreality/media/kay.html does a better job than I could
Oh no! I was just looking at the wiki a couple months ago. It was a really good reference. The mprove page is nice as an overview but personally what I found valuable about the wiki was the guided tour through his most important works and the Concepts page.
(fyi, in case there's any confusion, the Yoshiki of tinlizzie linked to by Srini Kadamati https://futureofcoding.slack.com/archives/C5U3SEW6A/p1599752481131300?thread_ts=1599752310.130600&cid=C5U3SEW6A is Yoshiki Oshima, I am Yoshiki Schmitz, no relation!)
oh yeah, I knew it was Oshima 🙂 but he’s not in this SLack I think
Also @Glen Chiacchieri the link to "Powerful Ideas Need Love To" is broken. This one should work:
http://worrydream.com/refs/Kay%20-%20Powerful%20Ideas%20Need%20Love%20Too.html
Ouch. One more good argument for (1) working local-first and (2) regular donations to the Internet Archive.
brand new member @U01AN8DFFBN did this data structure visualization extension for vscode and it’s really cool: https://github.com/hediet/vscode-debug-visualizer/blob/master/extension/README.md
reminds me of glamorous toolkit
i’m trying to recall the name of a language/development environment from the 80s/early 90s (likely from a master’s/doctoral thesis, perhaps that had something to do with pictograms) that was basically a white canvas that you type into where the “characters” were treated as rasters (so it allowed for overtyping characters and erasing program output with the backspace key, etc). basically just a 2d grid of pixels that could be manipulated directly. does this ring a bell to anyone? i’ve been searching through my history and can’t seem to find it… offering 100 internet points to whoever can tell me the name lol
bingo! thanks yoshiki! i can’t believe i forgot the name “viewpoint” lol
Folks have you seen this project: https://infocentral.org/
One excerpt:
The > https://pchiusano.github.io/2013-05-22/future-of-software.html> is app-free computing – fully-integrated, composeable, and adaptive software functionality that comes alongside neutral information rather than creating artificial boundaries.Another:
InfoCentral is a next-generation internet engineering project and proposal. It combines Information-Centric Networking, persistent graph data models, declarative programming, and the best elements of the Semantic Web into a new software and internet architecture – one that is fundamentally decentralized and distribut> able> , while also easier to secure.
Tweet where I found this:
https://twitter.com/ChrisGebhardtIC/status/1304169300199120898
🐦 Chris Gebhardt: @codexeditor Indeed! And if the OS was natively built around a knowledge graph, we'd no longer need files, applications, or desktops. That's one of the core philosophies of my project in a nutshell.