Fork me on GitHub
#off-topic
<
2017-12-08
>
roberto03:12:21

5 years remote. Agree on the importance of discipline. I work from a coffee shop once a week just to feed off the energy of people moving around me. On this remote job I’ve done, Clojure, Typescript, Kotlin, Groovy, Python & Go.

qqq04:12:22

I'd love to work in a coffeeshop. I'm not sure they'd let me move 3 40" monitors in.

qqq04:12:36

Do you code on just a single laptop screen ?

roberto04:12:01

single laptop. External monitors are distracting. When I’m home I have an external monitor. I use it when I’m working indoors. When the weather is good, I work from the backyard only on the laptop.

roberto04:12:40

even when I use the external monitor, I only have one app on full screen

roberto04:12:09

mostly my editor or ide, or terminal, or whatever application I’m using at the time

qqq04:12:43

Really? I need atleast: emacs + 3 terminals (cljs dev build, cljs prod build, clj build) + chrome (showing webpage) + chrome devtools for debugging + another chrome window [documentation / code I'm copying from]

roberto04:12:43

I don’t use glasses yet, but I’m 40, and having lots of screens with small fonts give me a headache.

seancorfield04:12:25

@qqq If you have Emacs, you shouldn't need additional terminals -- run it all inside Emacs! 🙂

seancorfield04:12:55

I work with my editor full screen, dock/menu/task bar hidden. Single screen. Multiple desktops. Browser full screen on one, editor on another. A couple of terminal windows on another (for when I want to kick off full build/test processes -- and go read stuff elsewhere while that's running). Email full screen on another desktop. Slack on another. Helps keep the focus on just one thing at once.

roberto04:12:21

I also find having multiple apps open on one screen distracting too.

borkdude09:12:22

@roberto I have the same (see discussion yesterday about monitors)

New To Clojure11:12:02

Have anyone used Scala? I wrote a hello-world with a test and it takes 30 seconds to compile and run it with sbt. It seems to be a pain to program with such slow compilation time.

Jon13:12:24

we should move the conversation to ClojureVerse http://clojureverse.org for better readability. it would be available for more people searching.

New To Clojure14:12:02

Is ClojureVerse yet another StackOverflow clone (what are it's procs)?

New To Clojure11:12:43

A the same time, Clojure usually takes only 3 seconds to run tests via lein test.

borkdude11:12:14

@ghsgd2 Usually you don’t run code in Clojure by starting a new JVM: the REPL is your main weapon there

New To Clojure11:12:36

@borkdude Yeah, repl reduces tests time even further. I worked on Java/Scala codebase and it seems that if code is simple enough and you could write it from 1st-2nd time that's fine otherwise it's just hard to use.

New To Clojure11:12:37

But there are people which used Scala for substantial time! I'm wondering how they managed to adapt to such a slow feedback loop.

New To Clojure11:12:56

Great cross-pollination example 🙂

Empperi12:12:51

@ghsgd2 yup, I’ve written Scala. It is super slow to compile and it is a well known fact

New To Clojure12:12:37

@niklas.collin Were you distracted from work by slow compilation?

Empperi12:12:01

I do not like Scala, really

New To Clojure12:12:23

Any tricks how to test some short Scala snippets?

Empperi12:12:37

just open the scala repl by typing scala

New To Clojure12:12:16

What if I need to use my own class methods?

Empperi12:12:23

scala> List(1,2,3,4).filter(_ > 3)
res0: List[Int] = List(4)

New To Clojure12:12:32

And it depends on class B and library C?

Empperi12:12:20

use sbt and type console

New To Clojure12:12:49

In Clojure I could re-evaluate defn in REPL and start using updated version immediately. Is there something similar for Scala?

New To Clojure12:12:11

(`C-c C-e` and it's loaded)

New To Clojure12:12:45

I see. That's why Scala isn't for me. Thank you, @niklas.collin!

Empperi12:12:00

I try to stay away from Scala but unfortunately that’s the main language in my team currently 😞

Empperi12:12:10

it has some neat things like pattern matching and relatively good type system but in general it is overly complex and most scala code is near to being unreadable due to all libraries using implicit keyword stuff and due to Scala’s obsession of trying to remove extra characters with syntatic sugar

Empperi12:12:44

and the compilation times are nuts

Empperi12:12:29

just did time sbt compile to one of our microservices, wait a bit it’s running

Empperi12:12:45

that does not execute tests or anything, just compiles scala files

Empperi12:12:54

I’ll tell you when it’s done 😄

New To Clojure12:12:00

Haha. It's yet another GWT. 🙂 May the force be with you and good luck maintaining it!

Empperi12:12:24

real	1m13.263s
user	3m17.573s
sys	0m5.665s

Empperi13:12:12

this destroys my mind since I’ve gotten used to instant feedback loop of Clojure development

Empperi13:12:52

it does get slightly better if you keep sbt running and let it auto compile stuff but still, it’s slow as hell

borkdude14:12:57

@ghsgd2 I think the fastest way is to make a file like this:

case class Foo(x: Int)

object Foo extends App {
  println(Foo(1))
}
and then call scala file.scala

New To Clojure14:12:16

@borkdude Thanks, that's much better!

$ time scala file.scala
Foo(1)
real	0m1.440s
user	0m1.078s
sys	0m0.130s

vemv17:12:54

which ML library (especially Deep Learning ones) offers the most power while requiring little to no ml/math/stats knowledge? (assuming there's such a thing) Personally atm I'm quite unwilling to learn ML - don't want to open the can of worms. I've heard there are some abstractions for non-ML-savvy devs, so I wonder - which is the best abstraction out there?

vemv17:12:09

(non-Clojure libraries acceptable)

seancorfield18:12:12

Re: Scala -- we tried Scala at work back in the 2.7/2.8 days. Slow compilation, impenetrable compiler errors relating to type conflicts, baroque code at times. We tried it because it had XML literal syntax and promised concurrency -- and we had a problem that involved producing a lot of XML exports. Back then the actor library had (known!) memory leaks so our app worked fine but had to be restarted via a cron job to avoid running out of heap(!).

seancorfield18:12:22

The migration from 2.7 to 2.8 was incredibly painful -- with every milestone build introducing new binary compatibility problems and the entire tool chain needing to be updated (so you couldn't start using the new build of the compiler until all the libraries and tools you depended on had been rebuilt with that version).

noisesmith18:12:39

yeah, scala never has compatibility between compilers, right?

seancorfield18:12:58

It's better now but binary compatibility is still a bit of a problem.

seancorfield18:12:03

That was 2009/2010. So I tried Clojure for the same problem and, although it initially ran slower, the code was even more concise than Scala, "compilation time" was effectively negligible due to the compile-on-demand nature of Cloure, and the syntax was way less confusing to read for newbies at the company. After some tweaks, the Clojure code ran faster than the Scala code (more concurrency was easier to write in Clojure). So we dropped Scala and started using Clojure for more things.

vuuvi19:12:58

are there any good frameworks for blogging in clojure? Like a jekyll or hugo?

nickbauman20:12:23

It made me kinda angry but I think it’s ultimately sobering.

nickbauman20:12:03

It was done in 1999. Maybe today it would be different.

noisesmith20:12:08

hasn’t ARM become much more successful as a RISC since that was published?

nickbauman20:12:31

Well and that everything is now RISC.

noisesmith20:12:43

even Intel is RISC with with a wrapper now yeah

nickbauman20:12:49

Intel-based processors have an internal instruction set that is RISC

noisesmith20:12:02

it’s like a fugue in here

nickbauman20:12:17

More of a crab-canon I’d say 😉

tbaldridge20:12:09

It'd be interesting to see a more up-to-date version of that @nickbauman

tbaldridge20:12:46

For example, parallel programming on GPUs has shared memory, but any sort of locks, or coordination between cores is extremely expensive.

tbaldridge20:12:52

and I mis-read some of the dates there, guess this is only 3 years old

nickbauman20:12:30

The parallelism argument for being still a maybe is probably right.

nickbauman20:12:51

Even with the superior way Clojure does it, allowing you to avoid the locking paradigm in nearly all situations.

nickbauman20:12:40

But parallel programming problems are considered “solved” only to the degree that the problems can be expressed as “share-nothing” problems.

nickbauman20:12:40

lotta interesting stuff isn’t “share nothing”

New To Clojure20:12:36

Thank you very much, @seancorfield! That's strange that Scala is popular in FinTech though.