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

Fix call to logger.info(...) #246

Merged
merged 1 commit into from
Jan 7, 2020
Merged

Fix call to logger.info(...) #246

merged 1 commit into from
Jan 7, 2020

Conversation

asottile
Copy link
Contributor

with this diff:

$ git diff
diff --git a/nodeenv.py b/nodeenv.py
index 769bae6..dbbdaf6 100755
--- a/nodeenv.py
+++ b/nodeenv.py
@@ -697,6 +697,7 @@ def install_node(env_dir, src_dir, opt):
     and install it in virtual environment.
     """
     try:
+        raise AssertionError('foo')
         install_node_wrapped(env_dir, src_dir, opt)
     except:
         # this restores the newline suppressed by continued=True

I get the following:

$ ~/opt/venv/bin/python nodeenv.py  nenv
Traceback (most recent call last):
  File "nodeenv.py", line 700, in install_node
    raise AssertionError('foo')
AssertionError: foo

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "nodeenv.py", line 1517, in <module>
    main()
  File "nodeenv.py", line 1113, in main
    create_environment(env_dir, opt)
  File "nodeenv.py", line 936, in create_environment
    install_node(env_dir, src_dir, opt)
  File "nodeenv.py", line 704, in install_node
    logger.info()
TypeError: info() missing 1 required positional argument: 'msg'

this patch fixes this

@asottile
Copy link
Contributor Author

asottile commented Jan 7, 2020

@ekalinin any chance you could take a look at this PR (and perhaps #246 -- though that one is a little more involved) -- no worries if you're busy :)

@ekalinin
Copy link
Owner

ekalinin commented Jan 7, 2020

Hi @asottile,
Sorry for delay and thanks for the patch!

@ekalinin ekalinin merged commit 5001f4e into ekalinin:master Jan 7, 2020
@asottile asottile deleted the fix_logger_info branch January 7, 2020 19:41
This pull request was closed.
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

Successfully merging this pull request may close these issues.

2 participants