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

New capture_output parameter in python3.7 #32

Closed
grabear opened this issue Oct 14, 2018 · 3 comments
Closed

New capture_output parameter in python3.7 #32

grabear opened this issue Oct 14, 2018 · 3 comments

Comments

@grabear
Copy link
Member

grabear commented Oct 14, 2018

Tried to create an environment:

grabear@Ubuntu-Blog:~$ renv -n boobs
Traceback (most recent call last):
  File "/home/grabear/.local/bin/renv", line 11, in <module>
    sys.exit(renv())
  File "/usr/lib/python3/dist-packages/click/core.py", line 722, in __call__
    return self.main(*args, **kwargs)
  File "/usr/lib/python3/dist-packages/click/core.py", line 697, in main
    rv = self.invoke(ctx)
  File "/usr/lib/python3/dist-packages/click/core.py", line 895, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/lib/python3/dist-packages/click/core.py", line 535, in invoke
    return callback(*args, **kwargs)
  File "/home/grabear/.local/lib/python3.6/site-packages/renv/renv.py", line 47, in renv
    prompt=prompt)
  File "/home/grabear/.local/lib/python3.6/site-packages/renv/core.py", line 62, in __init__
    r_path = utils.get_r_installed_root()
  File "/home/grabear/.local/lib/python3.6/site-packages/renv/utils.py", line 23, in get_r_installed_root
    r_path = get_r_path()
  File "/home/grabear/.local/lib/python3.6/site-packages/renv/utils.py", line 11, in get_r_path
    sp_out = sp.run(["which R"], shell=True, capture_output=True, encoding="utf8")
  File "/usr/lib/python3.6/subprocess.py", line 403, in run
    with Popen(*popenargs, **kwargs) as process:
TypeError: __init__() got an unexpected keyword argument 'capture_output'

Here is a 3.6/3.7 compatible way (I think).
https://github.com/datasnakes/renv/blob/master/renv/core.py#L208-L223

@santina
Copy link
Collaborator

santina commented Oct 14, 2018

Fixed in here 9154d43

@santina santina closed this as completed Oct 14, 2018
@grabear grabear reopened this Oct 15, 2018
@grabear
Copy link
Member Author

grabear commented Oct 15, 2018

I might be mistaken, but I was having trouble with this right before the teams started presenting. I think we missed something with the merges right before this.

@grabear
Copy link
Member Author

grabear commented Oct 19, 2018

I might be mistaken, but I was having trouble with this right before the teams started presenting. I think we missed something with the merges right before this.

8ee743d Fixes this issue

@grabear grabear self-assigned this Oct 19, 2018
@grabear grabear added this to the Hackseq 2018 - Standalone CLI milestone Oct 19, 2018
@grabear grabear closed this as completed Oct 19, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants