[yt-svn] commit/yt: ngoldbaum: Merged in brittonsmith/yt (pull request #2126)

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Thu Apr 21 09:03:25 PDT 2016


1 new commit in yt:

https://bitbucket.org/yt_analysis/yt/commits/843a342ee510/
Changeset:   843a342ee510
Branch:      yt
User:        ngoldbaum
Date:        2016-04-21 16:03:09+00:00
Summary:     Merged in brittonsmith/yt (pull request #2126)

[BUGFIX] cannot call parallel_root_only function inside a parallel_root_only function
Affected #:  1 file

diff -r 248ccc5ef8b46d83682344d249c8de1c964759ab -r 843a342ee5101c18f9acf8a490bdea39d4ee0fc2 yt/frontends/ytdata/data_structures.py
--- a/yt/frontends/ytdata/data_structures.py
+++ b/yt/frontends/ytdata/data_structures.py
@@ -40,6 +40,8 @@
     ParticleFile
 from yt.extern.six import \
     string_types
+from yt.funcs import \
+    is_root
 from yt.geometry.grid_geometry_handler import \
     GridIndex
 from yt.geometry.particle_geometry_handler import \
@@ -657,15 +659,15 @@
         self.domain_width = self.domain_right_edge - \
           self.domain_left_edge
 
-    @parallel_root_only
     def print_key_parameters(self):
-        mylog.info("YTProfileDataset")
-        for a in ["dimensionality", "profile_dimensions"] + \
-          ["%s_%s" % (ax, attr)
-           for ax in "xyz"[:self.dimensionality]
-           for attr in ["field", "range", "log"]]:
-            v = getattr(self, a)
-            mylog.info("Parameters: %-25s = %s", a, v)
+        if is_root():
+            mylog.info("YTProfileDataset")
+            for a in ["dimensionality", "profile_dimensions"] + \
+              ["%s_%s" % (ax, attr)
+               for ax in "xyz"[:self.dimensionality]
+               for attr in ["field", "range", "log"]]:
+                v = getattr(self, a)
+                mylog.info("Parameters: %-25s = %s", a, v)
         super(YTProfileDataset, self).print_key_parameters()
 
     @classmethod

Repository URL: https://bitbucket.org/yt_analysis/yt/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.spacepope.org/pipermail/yt-svn-spacepope.org/attachments/20160421/4d081554/attachment.htm>


More information about the yt-svn mailing list