Permalink
Browse files

Clean up docs for new version of 'open' method.

  • Loading branch information...
1 parent 021604d commit 93b0e2d8d79ea4449ae8a002b03bde1a2b08725f @chrisrossi chrisrossi committed Oct 23, 2012
Showing with 11 additions and 6 deletions.
  1. +11 −6 acidfs/__init__.py
View
@@ -166,12 +166,17 @@ def open(self, path, mode='r', buffering=-1, encoding=None, errors=None,
"""
Open a file for reading or writing.
- Implements the semantics of the `open` builtin in Python 3, so opening
- in text mode will return a file-like object which reads or writes
- unicode strings, and opening in binary mode reads or writes raw bytes.
- It does the right thing whether you're using Python 2 or 3.
-
- Random access and seeking are not supported.
+ Implements the semantics of the `open` function in Python's `io module
+ <http://docs.python.org/library/io.html#io.open>`_, which is the
+ default implementation `in Python 3
+ <http://docs.python.org/py3k/library/functions.html#open>`_. Opening a
+ file in text mode will return a file-like object which reads or writes
+ unicode strings, while opening a file in binary mode will return a
+ file-like object which reads or writes raw bytes.
+
+ Because the underlying implementation uses a pipe to a `Git` plumbing
+ command, opening for update (read and write) is not supported, nor is
+ seeking.
"""
session = self._session()
parsed = self._mkpath(path)

0 comments on commit 93b0e2d

Please sign in to comment.