{"action":"created","issue":{"url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/32","labels_url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/32/labels{/name}","comments_url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/32/comments","events_url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/32/events","html_url":"https://github.com/metasoarous/semantic-csv/pull/32","id":93845369,"number":32,"title":"Transducers","user":{"login":"mahinshaw","id":2602088,"avatar_url":"https://avatars.githubusercontent.com/u/2602088?v=3","gravatar_id":"","url":"https://api.github.com/users/mahinshaw","html_url":"https://github.com/mahinshaw","followers_url":"https://api.github.com/users/mahinshaw/followers","following_url":"https://api.github.com/users/mahinshaw/following{/other_user}","gists_url":"https://api.github.com/users/mahinshaw/gists{/gist_id}","starred_url":"https://api.github.com/users/mahinshaw/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mahinshaw/subscriptions","organizations_url":"https://api.github.com/users/mahinshaw/orgs","repos_url":"https://api.github.com/users/mahinshaw/repos","events_url":"https://api.github.com/users/mahinshaw/events{/privacy}","received_events_url":"https://api.github.com/users/mahinshaw/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":11,"created_at":"2015-07-08T17:23:35Z","updated_at":"2015-08-10T20:49:18Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/metasoarous/semantic-csv/pulls/32","html_url":"https://github.com/metasoarous/semantic-csv/pull/32","diff_url":"https://github.com/metasoarous/semantic-csv/pull/32.diff","patch_url":"https://github.com/metasoarous/semantic-csv/pull/32.patch"},"body":"Relates to Issue #30. I added transducers namespace, and a test file.  I did not however re-implement except-first macro.  I was not really sure how to do this (still fairly new to clojure).  Any ideas would be appreciated!  All the input functions are now transducers.  I pulled your doc comments from core, and modified them for the transducer versions.  I copied over the helpers for casting as well, because i figured that may decrease requiring core when it's not wanted.  Let me know what you think.  I will be happy to make any necessary changes you think are needed.  I Learned a lot doing this.\r\n\r\nAlso, I added a structify function to separate the functionality out.  I can change it to just being a mappify function if you would rather it be that way."},"comment":{"url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/comments/129602344","html_url":"https://github.com/metasoarous/semantic-csv/pull/32#issuecomment-129602344","issue_url":"https://api.github.com/repos/metasoarous/semantic-csv/issues/32","id":129602344,"user":{"login":"metasoarous","id":88556,"avatar_url":"https://avatars.githubusercontent.com/u/88556?v=3","gravatar_id":"","url":"https://api.github.com/users/metasoarous","html_url":"https://github.com/metasoarous","followers_url":"https://api.github.com/users/metasoarous/followers","following_url":"https://api.github.com/users/metasoarous/following{/other_user}","gists_url":"https://api.github.com/users/metasoarous/gists{/gist_id}","starred_url":"https://api.github.com/users/metasoarous/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/metasoarous/subscriptions","organizations_url":"https://api.github.com/users/metasoarous/orgs","repos_url":"https://api.github.com/users/metasoarous/repos","events_url":"https://api.github.com/users/metasoarous/events{/privacy}","received_events_url":"https://api.github.com/users/metasoarous/received_events","type":"User","site_admin":false},"created_at":"2015-08-10T20:49:18Z","updated_at":"2015-08-10T20:49:18Z","body":"Hi @mahinshaw \r\n\r\nSorry for the radio silence; I've been swamped lately, but should have more time to look at this in a couple of weeks.\r\n\r\nI guess my fundamental objection to doing the arity-1 overload is that, Clojure being a dynamic language, thinking about argument types too much feels a bit non-idiomatic. A particular case in point: it's totally within reason to have a map of k,v pairs and want to write them to rows of a CSV file with two columns (k,v). Checking `map?` to dispatch behaviour means you'd have to call `(seq the-map)` to achieve the desired behaviour. Obviously this isn't a huge deal, but it does smell a little because you're having to think about the types of things, not just how they behave.\r\n\r\nStill, mocking the arity dispatch of core functions like map, filter, take, etc, is awfully tempting. I'm tempted to throw out a quick survey to the Clojure mailing list to see what people think about these two options. I've gotten great feedback doing this with other projects.\r\n\r\nI think for now though, let's stick with separate namespaces. That is the least obtrusive path.\r\n\r\nA few quick notes about how I think things should be set up (for now, anyway): I don't think we should treat the transducer namespace as the complete set of implementations. And right now there is a lot of duplication of helper functions (like the parsing functions). Anything that is not explicitly working with transducers any differently than directly with collections (such as `spit-csv`) should be in some sort of `impl` namespace, and then get aliased into the two APIs separately (such that docstrings are preserved; maybe add a helper function for this...). Also, we should consider whether there is some more \"transducer-friendly\" way to do things like `spit-csv`.\r\n\r\nSome other concerns: it might be nice to shore up some of the other features I've had in mind before we merge in your work and cut a new release. My thinking there is that it would be nice if folks who are stuck with Clojure < 1.7 were able to use those features on some 0.x release, and let all the new transducer stuff fall into the > 1.x semantic-csv versions (I'd also like to take advantage of reader conditionals to make the library cljs compatible, requiring Clojure 1.7). Hopefully I'll be able to take care of some of those main things in a couple of weeks here when time opens up for me a bit. Would you be at all interested in helping with that stuff as well?\r\n\r\nOnce again; thanks so much for you work on this :-)\r\n"}}