[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Commit-gnuradio] [gnuradio] 04/09: grc: run flowgraphs even if bypassed
From: |
git |
Subject: |
[Commit-gnuradio] [gnuradio] 04/09: grc: run flowgraphs even if bypassed blocks contain errors |
Date: |
Wed, 9 Mar 2016 15:50:52 +0000 (UTC) |
This is an automated email from the git hooks/post-receive script.
jcorgan pushed a commit to branch maint
in repository gnuradio.
commit 507dc4ab774a4baefe67ed6e5e1c97c6fc696b84
Author: Glenn Richardson <address@hidden>
Date: Wed Mar 2 21:00:50 2016 -0500
grc: run flowgraphs even if bypassed blocks contain errors
---
grc/base/Element.py | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/grc/base/Element.py b/grc/base/Element.py
index 04a3690..b0f94d0 100644
--- a/grc/base/Element.py
+++ b/grc/base/Element.py
@@ -39,9 +39,9 @@ class Element(object):
Is this element valid?
Returns:
- true when the element is enabled and has no error messages
+ true when the element is enabled and has no error messages or is
bypassed
"""
- return not self.get_error_messages() or not self.get_enabled()
+ return (not self.get_error_messages() or not self.get_enabled()) or
self.get_bypassed()
def add_error_message(self, msg):
"""
@@ -55,14 +55,14 @@ class Element(object):
def get_error_messages(self):
"""
Get the list of error messages from this element and all of its
children.
- Do not include the error messages from disabled children.
+ Do not include the error messages from disabled or bypassed children.
Cleverly indent the children error messages for printing purposes.
Returns:
a list of error message strings
"""
error_messages = list(self._error_messages) #make a copy
- for child in filter(lambda c: c.get_enabled(), self.get_children()):
+ for child in filter(lambda c: c.get_enabled() and not
c.get_bypassed(), self.get_children()):
for msg in child.get_error_messages():
error_messages.append("%s:\n\t%s"%(child, msg.replace("\n",
"\n\t")))
return error_messages
@@ -75,6 +75,7 @@ class Element(object):
for child in self.get_children(): child.rewrite()
def get_enabled(self): return True
+ def get_bypassed(self): return False
##############################################
## Tree-like API
- [Commit-gnuradio] [gnuradio] branch maint updated (cf5ebff -> 0a1a76d), git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 08/09: Merge remote-tracking branch 'nwest/filter-docs' into maint, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 07/09: CMake: Fix dummy command in UseSWIG.cmake, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 03/09: docs: change firdes::low_pass2 docs to match implementation comments, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 05/09: fft: replace fftwf_malloc with volk_malloc, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 04/09: grc: run flowgraphs even if bypassed blocks contain errors,
git <=
- [Commit-gnuradio] [gnuradio] 09/09: Merge remote-tracking branch 'nwest/fft-avx-alignment' into maint, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 06/09: fft: explicitly link to volk, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 01/09: filter docs: add bt parameter to docs for gaussian filter, git, 2016/03/09
- [Commit-gnuradio] [gnuradio] 02/09: docs: reformat firdes docs to render nicely in doxygen, git, 2016/03/09