PurelyFunctional.tv Newsletter 295: Deps, Categories, Dystopia

Sign up for weekly Clojure tips, software design, and a Clojure coding challenge.

Issue 295 - October 08, 2018 · Archives · Subscribe

Hi Clojurers,

Just a reminder that I am available if you want Clojure or functional programming training at your company.

Please enjoy the issue.

Rock on!
Eric Normand <eric@purelyfunctional.tv>

PS Want to get this in your email? Subscribe!


Announcement: No Clojure SYNC in 2019

I'm sorry to say it, but it won't be happening in 2019. I'm deliberately leaving 2020 open. This post talks about why, and the future of Clojure SYNC.


The Simple Essence of Automatic Differentiation YouTube

If you ever want to understand what the excitement about Category Theory is all about, Conal Elliott is the person to look into. No programmer I know of is doing as much rethinking of traditional algorithms as he is.

Let me be really clear: I don't fully understand this, and I could not do this myself. I don't know enough Category Theory. But schematically, the presentation is clear: he is representing operations as categories, defining transformations from one category to another (it's an abstract space where they are equivalent), then running the representation in that other category, where things have desirable properties.

This is amazing work that has the potential to redefine not just software but scientific and mathematical understanding as well. (See Sussman's Programming for the Expression of Ideas).


Stu Halloway on Apropos Oct 18

We invited Stu Halloway to discuss the work he has been doing with exception reporting in Clojure. And he said yes! You can catch him live on October 18. We record the show live on YouTube. Subscribe and click on the bell icon to be notified when we go live. When you are there live, you can ask us questions. We record every two weeks on Thursdays.


Disrupting Dystopia YouTube

I'm a big Bruce Sterling fan. When he gets into it, his straight talking analysis is refreshing and contrarian. I share this talk in particular because I really like one of the assertions in it: the culture of Silicon Valley is on the top of the economic food chain. There's nowhere to go. It's no longer a futuristic vision. It's real. It's time to start making art that shares deep human experience.


Cisco Systems & Urban Decay Podcast

I really liked this talk about Sandy Lerner. She was a networking pioneer at Stanford, then went on to co-found Cisco Systems. Her accomplishments are amazing. And, what's more, she just seems like such a good-hearted, down-to-earth person.


Managing State in Re-frame

This article talks about the choices you have for where to store state in Re-frame. Each has different properties and it can be daunting to have to decide where to store each thing. I think I do a pretty good job of figuring out exactly what easy decisions you have to make.


Lisp: A Language for Stratified Design Paper

There's a chapter in Structure and Interpretation of Computer Programs (SICP) that talks about Stratified Design, which is Abelson and Sussman's term for building your application in semantic layers. I recently found this paper (by the same authors) that hits on the same points more succinctly (SICP is a textbook style, this paper is academic paper style). Read it, because Stratified Design is the way to go!


Dependency Heaven YouTube

I was skeptical when tools.deps and deps.edn first came out. We already had Leiningen for dependencies. Why was Cognitect spending time replacing it? In this talk, given before the libraries were released, Alex Miller explains the reasoning behind the additions to 1.9. This talk answers a lot of my questions and inspired me to start using it for real. I have been using deps.edn recently and I'm really liking it.


Looking At The Web After Tomorrow Podcast

Nikita Prokopov talks with host Daniel Compton about his work. Nikita is the creator of Datascript and Rum.


Domain Modeling Made Functional: Tackle Software Complexity with Domain-Driven Design and F# Book

I've really enjoyed Scott Wlaschin's book on implementing a Domain-Driven Design (DDD) approach with a statically typed, functional language (F#). I've read two other books on DDD and I have to say that this is the clearest I've read. It walks through the design process and introduces concepts only as you need them. I appreciate the pragmatic use of types to enforce business rules.

My biggest beef with the book is that it doesn't deal with changing requirements. There's a lot of up front analysis and dialog with a domain expert (which I appreciate). Then things get encoded very tightly into types. I would have loved to have seen how the business rules respond to some nice monkey wrenches thrown at them. In my experience, modifying types is some of the hardest work you can do. I'm sure there are some practices that I could have learned from others' experience.

I would recommend the book. I don't know F#. The F# code is minimal, readable, and well-explained. The example given is complex enough to be interesting, and it is implemented in a straightforward way. Along the way, I learned some of the terms of DDD that I was confused about. After reading this book, I have a deeper respect for DDD, F#, and functional programming.


Clojure Collections Currently recording

I've been recording more lessons in this course all about Clojure collections and how we actually use this. In the new lessons, I go over all sorts of stuff about the two main collections, Vectors and HashMaps. I talk about:

  • Literal syntax
  • Constructor functions
  • Evaluation semantics
  • Function call semantics
  • The patterns for usage

Here they are: Vector and HashMap.