summaryrefslogtreecommitdiffstats
path: root/Doc/library/importlib.rst
diff options
context:
space:
mode:
authorBrett Cannon <bcannon@gmail.com>2010-06-28 04:57:24 (GMT)
committerBrett Cannon <bcannon@gmail.com>2010-06-28 04:57:24 (GMT)
commit0cf9e6a6214d4418286a30e305fefad644b29c52 (patch)
tree9d07df67286fe14593baeae5ce2d0f1bd3b555db /Doc/library/importlib.rst
parent9396483ba40888b735b3d00dc5f1d1379f939914 (diff)
downloadcpython-0cf9e6a6214d4418286a30e305fefad644b29c52.zip
cpython-0cf9e6a6214d4418286a30e305fefad644b29c52.tar.gz
cpython-0cf9e6a6214d4418286a30e305fefad644b29c52.tar.bz2
Move importlib.abc.SourceLoader to _bootstrap.
Required updating code relying on other modules to switch to _bootstrap's unique module requirements. This led to the realization that get_code was being too liberal in its exception catching when calling set_data by blindly grabbing IOError. Shifted the responsibility of safely ignoring writes to a read-only path to set_data. Importlib is still not relying on SourceLoader yet; requires creating a SourcelessLoader and updating the source finder.
Diffstat (limited to 'Doc/library/importlib.rst')
-rw-r--r--Doc/library/importlib.rst3
1 files changed, 2 insertions, 1 deletions
diff --git a/Doc/library/importlib.rst b/Doc/library/importlib.rst
index 300653a..008df09 100644
--- a/Doc/library/importlib.rst
+++ b/Doc/library/importlib.rst
@@ -248,7 +248,8 @@ are also provided to help in implementing the core ABCs.
.. method:: set_data(self, path, data)
Optional abstract method which writes the specified bytes to a file
- path.
+ path. When writing to the path fails because the path is read-only, do
+ not propagate the exception.
.. method:: get_code(self, fullname)