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

Use python3 compatible print #395

Merged
merged 1 commit into from Feb 13, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
5 changes: 3 additions & 2 deletions wand/display.py
Expand Up @@ -21,6 +21,7 @@
.. versionadded:: 0.1.9

"""
from __future__ import print_function
import ctypes
import os
import platform
Expand Down Expand Up @@ -68,11 +69,11 @@ def display(image, server_name=':0'):

if __name__ == '__main__':
if len(sys.argv) < 2:
print>>sys.stderr, 'usage: python -m wand.display FILE'
print('usage: python -m wand.display FILE', file=sys.stderr)
raise SystemExit
path = sys.argv[1]
try:
with Image(filename=path) as image:
display(image)
except BlobError:
print>>sys.stderr, 'cannot read the file', path
print('cannot read the file', path, file=sys.stderr)