Skip to content

reliance on sys.stdin which is not always available #82

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

Closed
thehesiod opened this issue Feb 5, 2019 · 1 comment
Closed

reliance on sys.stdin which is not always available #82

thehesiod opened this issue Feb 5, 2019 · 1 comment
Labels
Milestone

Comments

@thehesiod
Copy link

We just got this exception when being used in a lambda since sys.stdin is None:

  File \"/var/task/nameparser/config/__init__.py\", line 95, in add_with_encoding
    encoding = encoding or sys.stdin.encoding or DEFAULT_ENCODING
AttributeError: 'NoneType' object has no attribute 'encoding'",

perhaps using stdout is better as it's less likely to not be available, or expanding the check for it being None

@derek73 derek73 added the bug label Feb 5, 2019
@derek73 derek73 added this to the v1.0.2 milestone Feb 5, 2019
@derek73
Copy link
Owner

derek73 commented Feb 5, 2019

Thanks for the bug report. I'll probably just check for missing stdin.

@derek73 derek73 modified the milestones: v1.0.2, v1.0.3 Apr 19, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants