[llvm-commits] [zorg] r141725 - /zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py

Galina Kistanova gkistanova at gmail.com
Tue Oct 11 15:33:59 PDT 2011


Author: gkistanova
Date: Tue Oct 11 17:33:59 2011
New Revision: 141725

URL: http://llvm.org/viewvc/llvm-project?rev=141725&view=rev
Log:
It is better to access properties directly and not through args.

Modified:
    zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py

Modified: zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py
URL: http://llvm.org/viewvc/llvm-project/zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py?rev=141725&r1=141724&r2=141725&view=diff
==============================================================================
--- zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py (original)
+++ zorg/trunk/zorg/buildbot/builders/ScriptedBuilder.py Tue Oct 11 17:33:59 2011
@@ -36,9 +36,13 @@
     for checkout in source_code:
       # Store the list of source code directories in the original order for later use.
       # Note: We require all spaces and special characters already escaped.
-      src_dir = checkout.args.get('workdir', None)
-      if src_dir:
-        scripted_step_common_args.append(WithProperties(src_dir))
+      try:
+        src_dir = checkout.workdir
+        if src_dir:
+          scripted_step_common_args.append(WithProperties(src_dir))
+      except AttributeError:
+        # workdir property is missing. Skip it.
+        pass
 
       # Get the source code from version control system
       f.addStep(checkout)





More information about the llvm-commits mailing list