This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-08-17
Channels
- # admin-announcements (1)
- # aleph (1)
- # architecture (1)
- # bangalore-clj (14)
- # beginners (15)
- # boot (89)
- # braveandtrue (1)
- # cider (1)
- # cljs-dev (33)
- # cljsjs (1)
- # cljsrn (147)
- # clojure (149)
- # clojure-quebec (1)
- # clojure-russia (82)
- # clojure-spec (18)
- # clojure-taiwan (2)
- # clojure-uk (15)
- # clojurescript (97)
- # cursive (11)
- # datomic (22)
- # funcool (2)
- # hoplon (53)
- # immutant (16)
- # jobs-rus (8)
- # lambdaisland (1)
- # off-topic (13)
- # om (7)
- # onyx (58)
- # parinfer (6)
- # planck (19)
- # protorepl (2)
- # re-frame (17)
- # reagent (201)
- # rum (6)
- # specter (9)
- # test-check (68)
- # untangled (47)
- # yada (94)
In my opinion, the best solution just uses reduce
. Your accumulator would be a map keyed by chat-id with values being a sorted-map
storing messages, keyed by timestamp.
Ok yes that is what I am doing as well :)
It was just out of curiosity, is it because of the oldest timestamp? In general, just for learning, can I carry a counter while I navigate the data with specter?
I can't think of a great way to do it using specter. I think specter is better for selecting from or transforming pieces of a nested data structure individually, while your task is aggregating all of your structure into something new. Maybe @nathanmarz has more insight.
@codonnell: ok thanks a lot
you're welcome
@nathanmarz: FYI this was needed for fixing my earlier issue (after upgrading to 0.12): https://github.com/binaryage/dirac/commit/45db785491751cd9e23440139f9b2554094c1759
@darwin hmm, ok
@darwin do you have a full stack trace from when the error was happening?