[Bf-blender-cvs] [5bfa43d] master: Include Python binary in system-info.txt

Campbell Barton noreply at git.blender.org
Fri Oct 30 12:55:12 CET 2015


Commit: 5bfa43d385f17fe8f57950b7b47abd38c34cfdd7
Author: Campbell Barton
Date:   Fri Oct 30 22:29:15 2015 +1100
Branches: master
https://developer.blender.org/rB5bfa43d385f17fe8f57950b7b47abd38c34cfdd7

Include Python binary in system-info.txt

===================================================================

M	release/scripts/modules/sys_info.py

===================================================================

diff --git a/release/scripts/modules/sys_info.py b/release/scripts/modules/sys_info.py
index c79865d..8f7e364 100644
--- a/release/scripts/modules/sys_info.py
+++ b/release/scripts/modules/sys_info.py
@@ -20,14 +20,15 @@
 
 # classes for extracting info from blenders internal classes
 
-import bpy
-import bgl
-
-import sys
-
 
 def write_sysinfo(op):
+    import sys
+
     import textwrap
+    import subprocess
+
+    import bpy
+    import bgl
 
     output_filename = "system-info.txt"
 
@@ -83,6 +84,18 @@ def write_sysinfo(op):
     for p in sys.path:
         output.write("\t%r\n" % p)
 
+    output.write(title("Python (External Binary)"))
+    output.write("binary path: %s\n" % prepr(bpy.app.binary_path_python))
+    try:
+        py_ver = prepr(subprocess.check_output([
+                bpy.app.binary_path_python,
+                "--version",
+                ]).strip())
+    except Exception as e:
+        py_ver = str(e)
+    output.write("version: %s\n" % py_ver)
+    del py_ver
+
     output.write(title("Directories"))
     output.write("scripts:\n")
     for p in bpy.utils.script_paths():




More information about the Bf-blender-cvs mailing list