Fork me on GitHub
#clojure-europe
<
2022-11-14
>
vijaykiran07:11:37

Morning!

❤️ 5
robert-stuttaford07:11:57

happy 0 degrees celcius!

🥶 4
Dimitar Uzunov07:11:25

holy crap is that in NL?

Dimitar Uzunov07:11:51

ah it is 3 degrees here

Dimitar Uzunov07:11:32

I spent some time outside, maybe because it wasn't windy it didn't feel like 3 degrees

reefersleep08:11:17

Good morning 🙂

genRaiy08:11:10

First frosty good morning

wow 1
😎 2
1
❤️ 1
simongray08:11:40

10-11 degrees in Copenhagen

otfrom09:11:59

14 in Dundee

dharrigan09:11:22

Good Morning!

thomas09:11:21

Morning lovely people

robert-stuttaford10:11:54

(not trying to be a gud photographerpher here, just sharing the 0 degree mist)

🌁 1
🥶 1
otfrom10:11:26

that looks cold

otfrom10:11:04

0 and misty feels a lot colder than -5 and dry

☝️ 2
borkdude10:11:54

I need a new phone. Either iPhone SE 2022 or iPhone 13 mini. I'm an average user, probably don't need the better screen or camera. Then again, I'm going to use this for 5 years... All these choices!

robert-stuttaford10:11:32

my colleague Mark just got the 13 mini, if you'd like to ask him about it

borkdude10:11:35

My brother in law also has one, so I'm good. Just trying to figure out what I want / need....

Dimitar Uzunov11:11:58

Get a Fairphone 4 if you don't mind the android. You get 5 years of support, and spare parts will be available too. https://shop.fairphone.com/

Dimitar Uzunov11:11:32

ah nvm this is a larger phone than those two

borkdude11:11:59

yeah I like the small phone

borkdude11:11:31

I had a Fairphone 1, ironically it only lasted 4 years or so because it got too slow with Android upgrades

borkdude11:11:56

Still have it laying around, I hope it will be a collectors item some day ;)

🤞 2
lread14:11:43

Yeah, am interested too. Probably time to replace my iPhone 5s!

vemv14:11:49

I got the 13 mini very recently. it's a little beast - SE feel with seemingly advanced cameras and features (which I don't care about). I'm just upset I lost the headphone jack!

orestis14:11:44

@U04V15CAJ it all comes down to - are you ready to lose the home button and use face ID / gestures? My wife got the iphone 11 recently for the improved battery over the iPhone SE, and the muscle memory is gone -> no button, the notch etc.

orestis14:11:09

Still 20' in Athens ☀️

😎 1
orestis14:11:49

A question - where do you guys get your music from? I recently switched from Spotify to Apple Music, but I realised Apple Music has no "free" API and I'm not paying $99/year just to hack on this. So I either have to also get Spotify again, or start to hoard DRM-free albums... but I don't really want to manage files anymore. Any alternatives?

borkdude14:11:45

@orestis I've been a Spotify subscriber for a long time, also because I theoretically want a cross-platform experience, but this is bullshit since I go with Mac most of the time anyway ;)

borkdude14:11:39

I've tried the CD and mp3 route for a while again, but convenience wins in the long run. I listen to a lot of internet radio too with my favorite genres and use Spotify to "zoom in" on music/albums I might like

orestis14:11:28

These damn subscriptions are piling up! But the truth is that 7eur / month for Spotify is very low for the value you get.

borkdude14:11:29

I have the premium individual which is 9.99

orestis14:11:14

I’m also surprised that neither Apple Music nor Spotify DRM have been cracked. That is, I wouldn’t mind keep paying a subscription but I would like to download and play files with other players too.

borkdude14:11:24

you can also share it with your family for a few euros more

borkdude14:11:13

I've watched a series about Spotify on Netflix (another subscription) recently

simongray14:11:07

My wife and I just use Spotify Duo. It is (I think) the cheapest if you’re only two. I have also had both Apple Music and Youtube Music for a while. I think Apple Music has some decent curated stuff, while Youtube Music has pretty good generated discovery. My wife prefers Spotify, so that’s why we use that.

simongray15:11:40

I think Apple Music probably has the worst UI, while Spotify is trying way too hard to promote its podcasts and Youtube Music is a weird mix of music subscription and Youtube playback.

simongray15:11:12

So they’re all flawed IMO. And obviously Spotify is lacking Neil Young and Joni Mitchell since Joe Rogan-gate.

Dimitar Uzunov15:11:17

there are so many music platforms I just do a different free trial every month

metal 2
pavlosmelissinos15:11:42

What's wrong with youtube?

simongray15:11:56

It lacks a native app for desktop (you can use a third-party web view, though) and I don’t personally like the way it mixes in Youtube content.

simongray15:11:21

but other than that, it’s fine

javahippie15:11:06

I‘m with Apple Music, because I am lazy and it works on my devices. Also I like that it is more of a library because the recommendation algorithm is so bad that it‘s non-existant 😅 the bad thing is that I was looking into building a streaming box for kids which works with NFC (are tonieboxes known outside of Germany?), and while it would be possible with Spotify, Apple makes this really hard :(

orestis15:11:35

I am currently doing an nfc project like this.

javahippie15:11:36

Do you have schematics/plans anywhere or are you building it from scratch?

orestis15:11:35

It's a v2 of an existing one I had https://github.com/orestis/fauxvinyl

👀 1
orestis15:11:12

The original one was controlling the Spotify macOS app via a Mac Mini media player. The new one is going to use moode audio on a raspberry pi, via Spotify Connect. The NFC hardware luckily stays the same.

orestis15:11:47

I can share more tomorrow, if I forget please feel free to ping me 🙂

❤️ 1
orestis19:11:03

So, a brief overview is this: • A bunch of NFC stickers I bought years ago on AliExpress, that I put on nice little cardboard squares of album art. • Each NFC tag has ~140bytes of memory, enough to store a Spotify ID in there, like <foo>, plus a header encoding the length. • I have a ACR122U NFC device over a USB, that can read/write to those tags

orestis19:11:39

A small python program reads incoming tags, and fowards the spotify ID to the spotify API, so that it plays in a Spotify Connect device.

orestis19:11:35

I used to it via a Mac Mini (macOS had native support for controlling the NFC device) using AppleScript to remotely control the Spotify App, but since moving a few times I don't want to deal with the Mac Mini anymore, so I've found moode audio that runs headless on a Raspberry Pi, and also gives me AirPlay support.

orestis21:11:28

I actually got it working just this evening, using all my old tags 🙂

Marius07:11:30

@U0N9SJHCH I’ve built a Phoniebox for my kids and my intention was to use Spotify, but the startup time was just too long (like a minute or so), so that I switched to the offline version. That was in 2020, perhaps they have fixed it.

orestis14:11:25

Spotify offers a first-class start_playback function these days that is instantaneous it seems.

Marius14:11:52

What I meant is that the whole system (Raspberry PI and Phoniebox stack) needed about a minute from power on to ready to read a NFC card. This is probably acceptable for an adult, but my kids want everything immediately and a minute is like forever. 😂 I see this as a big advantage of the commercial Toniebox.

javahippie14:11:43

Everybody in my extended family has a toniebox, but it‘s just soooo expensive and locked down… I still have ~2 years to build something, our son isn‘t old enough, yet 😅 Thanks for the links, recommendations and experience reports! I hope I can find a way to make it work with Apple Music, don‘t really need another service. I have a developer account, anyways… :thinking_face:

orestis15:11:53

Does the Toniebox use Spotify?

orestis15:11:44

Ah, don't mind me, I now saw what the Toniebox is...

orestis15:11:19

I had it in the back of my mind to build a more rugged version of this, using a much lower-level controller and NFC reader, and probably using internal storage instead of streaming from the network. But I ran out of time 🙂

orestis15:11:40

The toniebox is an inspiration, though I do hate these locked-down things.

otfrom15:11:39

dumb clojure question: how do you get the index of an item in a vector? (vector of [:a :b :c] and I want a function where calling (foo :b [:a :b :c]) returns 1

otfrom15:11:48

I'm seeing things with keep-indexed

orestis15:11:13

(defn positions
  [pred coll]
  (keep-indexed (fn [idx x]
                  (when (pred x)
                    idx))
                coll))
We have this in our util

🆒 4
vijaykiran17:11:11

Random question: do you hand roll Kubernetes YAMLs using rustic artisanal techniques , or is there any lib that can produce those by richly functional hipster clojure funcs?

robert-stuttaford17:11:50

option 3: we don't use k8s

vijaykiran17:11:31

I’d prefer that if I could change the world and print money 😛

💯 1
😅 2
vijaykiran17:11:11

Given that it’s all ReST, I thought there might be something available similar to cognitect AWS API.

otfrom17:11:11

I feel what I need to learn from the cognitect AWS API is how to turn a spec into some code w/checks really

otfrom17:11:18

I've just not gone through it

jkxyz18:11:15

There’s https://github.com/xtruder/kubenix for ultimate hipster points

mpenet18:11:35

We have a library at work to generate them from aero/edn files. I think it was meant to be open sourced at some point pt. I can ask tomorrow. It’s used for our own consumption and our managed kubernetes offering also uses it to generate customers clusters control plane manifests

❤️ 4
vijaykiran19:11:42

@U050SC7SV that sounds like a nice lib/tool

mccraigmccraig08:11:37

not clojure, but there is kustomize built in to kubectl these days : https://kustomize.io/

Dimitar Uzunov11:11:23

I can vouch for kustomize, it is easy to work with and reliable.. other than that it's just data. Generate your yaml using Clojure, no need for a special library.

vijaykiran11:11:49

the whole point of my question was how I can not write YAML 🙂 ideally something more sane language than YAML with benefits as https://github.com/dhall-lang/dhall-kubernetes - and indeed I can write maps and maps of stuff and generate yaml from that too. Which would be less wieldy I guess.

borkdude11:11:25

I do that a lot: generate config in clojure, then write yaml in the end

mpenet12:11:17

it's more about having validation & not having to write the boilerplate I suppose, otherwise going from edn->yaml is easy

vijaykiran12:11:14

Indeed. Writing yaml in yet another yaml doesn’t have any advantage for me 😅

lemontea19:11:37

yup, hand-rolling (ideally allocating a time slot without distraction or obligation). It is to practise patience and dealing with not-so-pleasant things. Something like Zen.