Author: Armin Rigo <[email protected]>
Branch: 
Changeset: r84001:9d9245696120
Date: 2016-04-28 09:45 +0200
http://bitbucket.org/pypy/pypy/changeset/9d9245696120/

Log:    I'm really often hitting this issue where I get

         AttributeError: install_layout

        in __getattr__(). I think it might be caused by some Debian-ism but
        I'm not sure what is going on, because I keep getting it on a fresh
        install of the official pypy's. I usually fix it with this "except
        AttributeError", which I'm now checking in.

diff --git a/lib-python/2.7/distutils/cmd.py b/lib-python/2.7/distutils/cmd.py
--- a/lib-python/2.7/distutils/cmd.py
+++ b/lib-python/2.7/distutils/cmd.py
@@ -298,8 +298,11 @@
         src_cmd_obj.ensure_finalized()
         for (src_option, dst_option) in option_pairs:
             if getattr(self, dst_option) is None:
-                setattr(self, dst_option,
-                        getattr(src_cmd_obj, src_option))
+                try:
+                    setattr(self, dst_option,
+                            getattr(src_cmd_obj, src_option))
+                except AttributeError:
+                    pass
 
 
     def get_finalized_command(self, command, create=1):
_______________________________________________
pypy-commit mailing list
[email protected]
https://mail.python.org/mailman/listinfo/pypy-commit

Reply via email to