Skip to content

BUG: Allow IOErrors when attempting to retrieve default client encoding. #21531

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

Merged
merged 23 commits into from
Sep 19, 2018
Merged
Changes from 1 commit
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
6c2987d
BUG: Except IOErrors when attempting to retrieve default client encod…
Jun 18, 2018
c31b914
BUG: Allow IOErrors when attempting to retrieve client encoding. (#21…
JayOfferdahl Jun 20, 2018
510f4b1
Merge branch 'pending-branch' into get-client-encoding-on-mod-wsgi
JayOfferdahl Jun 20, 2018
1afda5f
Merge branch 'master' into get-client-encoding-on-mod-wsgi
JayOfferdahl Jun 20, 2018
b37cb75
Fixup tests to add more scenarios. Code review changes.
JayOfferdahl Jun 20, 2018
0b1ca1d
Merge branch 'get-client-encoding-on-mod-wsgi' of https://github.com/…
JayOfferdahl Jun 20, 2018
bf26adb
PEP8 changes.
JayOfferdahl Jun 20, 2018
77a95d2
Mock out stdout/stdin instead of trying to access their properties.
JayOfferdahl Jun 26, 2018
2598595
Merge branch 'master' into get-client-encoding-on-mod-wsgi
JayOfferdahl Jun 26, 2018
59e0993
Use context manager when monkeypatching standard library items.
JayOfferdahl Jul 13, 2018
8b51b34
Merge branch 'get-client-encoding-on-mod-wsgi' of https://github.com/…
JayOfferdahl Jul 13, 2018
984da5c
Merge branch 'master' into get-client-encoding-on-mod-wsgi
JayOfferdahl Jul 13, 2018
4790e10
Fix linter erros/code review changes.
JayOfferdahl Jul 14, 2018
6156825
Move fix to 0.24.0 release; simplify tests.
JayOfferdahl Jul 16, 2018
fb1dc2e
Attempt at trying to get side_effects right without using mock.
JayOfferdahl Jul 24, 2018
7cedfdc
Add TODO(py27) to test helper.
JayOfferdahl Jul 25, 2018
35c0b3b
Fix pylint error.
JayOfferdahl Jul 25, 2018
49ee7b5
Fix silly linting errors. Use pep8.
JayOfferdahl Jul 26, 2018
40b3588
Move raise_or_return to MockEncoding; clean up parameters.
JayOfferdahl Aug 4, 2018
5e3c8af
Merge branch 'master' into get-client-encoding-on-mod-wsgi
JayOfferdahl Aug 16, 2018
f485223
Merge branch 'master' into get-client-encoding-on-mod-wsgi
JayOfferdahl Aug 23, 2018
ab67024
Merge remote-tracking branch 'upstream/master' into get-client-encodi…
JayOfferdahl Sep 18, 2018
81547da
Merge branch 'get-client-encoding-on-mod-wsgi' of https://github.com/…
JayOfferdahl Sep 18, 2018
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pandas/io/formats/console.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def detect_console_encoding():
encoding = None
try:
encoding = sys.stdout.encoding or sys.stdin.encoding
except AttributeError:
except Exception:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why can't we just except both on AttributeError and IOError ? I generally try to avoid using the broad Exception unless we have good reason to.

pass

# try again for something better
Expand Down