Skip to content

Use open() instead of file()#39

Merged
jkeyes merged 1 commit intointercom:masterfrom
Tilka:file_open
Sep 22, 2014
Merged

Use open() instead of file()#39
jkeyes merged 1 commit intointercom:masterfrom
Tilka:file_open

Conversation

@Tilka
Copy link
Copy Markdown
Contributor

@Tilka Tilka commented Sep 22, 2014

From the documentation:

When opening a file, it’s preferable to use open() instead of invoking this constructor directly. file is more suited to type testing (for example, writing isinstance(f, file)).

jkeyes added a commit that referenced this pull request Sep 22, 2014
Use open() instead of file()
@jkeyes jkeyes merged commit 69c8989 into intercom:master Sep 22, 2014
@jkeyes
Copy link
Copy Markdown
Contributor

jkeyes commented Sep 22, 2014

@Tilka I've no idea why I used file. It must have been a cut'n'paste job from some setup.py file I was looking at. Thanks.

@Tilka Tilka deleted the file_open branch September 22, 2014 21:10
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