summaryrefslogtreecommitdiff
path: root/grc/core
diff options
context:
space:
mode:
Diffstat (limited to 'grc/core')
-rw-r--r--grc/core/Block.py2
-rw-r--r--grc/core/ParseXML.py2
-rw-r--r--grc/core/utils/expr_utils.py3
3 files changed, 3 insertions, 4 deletions
diff --git a/grc/core/Block.py b/grc/core/Block.py
index 8350828092..087815b941 100644
--- a/grc/core/Block.py
+++ b/grc/core/Block.py
@@ -403,7 +403,7 @@ class Block(Element):
return itertools.chain(self.active_sources, self.active_sinks)
def get_children(self):
- return self.get_ports() + self.params.values()
+ return self.get_ports() + list(self.params.values())
def get_children_gui(self):
return self.get_ports_gui() + self.params.values()
diff --git a/grc/core/ParseXML.py b/grc/core/ParseXML.py
index 163289ba06..430ba5b474 100644
--- a/grc/core/ParseXML.py
+++ b/grc/core/ParseXML.py
@@ -156,7 +156,7 @@ def to_file(nested_data, xml_file):
), xml_declaration=True, pretty_print=True, encoding='utf-8')
xml_data += etree.tostring(_to_file(nested_data)[0],
pretty_print=True, encoding='utf-8')
- with open(xml_file, 'w') as fp:
+ with open(xml_file, 'wb') as fp:
fp.write(xml_data)
diff --git a/grc/core/utils/expr_utils.py b/grc/core/utils/expr_utils.py
index 555bd709b1..cc03e9cb1c 100644
--- a/grc/core/utils/expr_utils.py
+++ b/grc/core/utils/expr_utils.py
@@ -23,7 +23,7 @@ import string
import six
-VAR_CHARS = string.letters + string.digits + '_'
+VAR_CHARS = string.ascii_letters + string.digits + '_'
class graph(object):
@@ -194,4 +194,3 @@ def sort_objects(objects, get_id, get_expr):
sorted_ids = sort_variables(id2expr)
# Return list of sorted objects
return [id2obj[id] for id in sorted_ids]
-