Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move console IO stuff to a separate module #50

Open
harendra-kumar opened this issue May 10, 2017 · 3 comments
Open

Move console IO stuff to a separate module #50

harendra-kumar opened this issue May 10, 2017 · 3 comments

Comments

@harendra-kumar
Copy link
Contributor

harendra-kumar commented May 10, 2017

I would suggest the following:

  1. Move keep, option, input to a separate module, say Transient.ConsoleIO. We can possibly call the new module Transient.Input if there are more input methods to be covered. We can rename keep to something more appropriate like withConsole or withAsyncInput or interactive.

  2. keep' and exit can stay in Base. But we can rename keep' to something more appropriate likewait or stayput.

@agocorona
Copy link
Collaborator

Yep I agree. Definitively the creation of Transient.ConsoleIO is necessary and later think about renaming. since I have a conference in which I present Transient at Lambda Conf at the end of this month it is better no to rename primitives.

Transient.Input is not as good as Trasient.ConsoleIO IMO, since there are other forms of input using widgets in axiom, for example.

@rahulmutt
Copy link
Contributor

I would go as far as to keep a separate package. I'm thinking along the lines of having transient-base be the core TransientIO monad definition and implementation with all the building-block APIs async, parallel, etc. and backtracking/exception handling. Anything outside of the domain of core asynchronous primitives should be in the main transient package like console I/O, etc and the transient package can re-export all the main APIs from transient-base. How does that sound?

The reason why I suggest this is that you won't need to worry about the console when you build concurrent/distributed backends - the most common use case of transient besides using with axiom which also probably doesn't require console I/O for non-trivial applications?

@agocorona
Copy link
Collaborator

agocorona commented Jun 20, 2017

It sounds well. That's how things should be. I have to change the git repo and create a mega-repo. Now the impedance on creating more packages and make builds works and synchronise in travis, hackage and stackage and maybe in docker is a big barrier for creating more packages. I want to create at least another additional module for parsing, including code that I have scattered in transient-Move and Axiom.

First the law of least effort recommend to separate it in a different modules as a first step. Also the console code should be rewritten to eliminate STM since it is not justified for the work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants