-
Notifications
You must be signed in to change notification settings - Fork 27
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
autopep8 #19
Conversation
src/rqt_graph/dotcode.py
Outdated
+ [action_prefix + ACTION_TOPICS_SUFFIX for (action_prefix, _) in action_nodes.items()] | ||
+ [image_prefix + IMAGE_TOPICS_SUFFIX for (image_prefix, _) in image_nodes.items()] | ||
+ nn_nodes if nn_nodes is not None else [], | ||
+ [action_prefix + ACTION_TOPICS_SUFFIX for (action_prefix, _) in action_nodes.items()] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This list should probably not be built inside the call to _populate_node_graph
src/rqt_graph/ros_graph.py
Outdated
@@ -331,7 +344,8 @@ def _redraw_graph_view(self): | |||
|
|||
def _load_dot(self, file_name=None): | |||
if file_name is None: | |||
file_name, _ = QFileDialog.getOpenFileName(self._widget, self.tr('Open graph from file'), None, self.tr('DOT graph (*.dot)')) | |||
file_name, _ = QFileDialog.getOpenFileName(self._widget, self.tr( | |||
'Open graph from file'), None, self.tr('DOT graph (*.dot)')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line break is confusing
src/rqt_graph/ros_graph.py
Outdated
@@ -363,7 +377,8 @@ def _fit_in_view(self): | |||
self._widget.graphics_view.fitInView(self._scene.itemsBoundingRect(), Qt.KeepAspectRatio) | |||
|
|||
def _save_dot(self): | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr('Save as DOT'), 'rosgraph.dot', self.tr('DOT graph (*.dot)')) | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr( | |||
'Save as DOT'), 'rosgraph.dot', self.tr('DOT graph (*.dot)')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line break is confusing
src/rqt_graph/ros_graph.py
Outdated
@@ -375,7 +390,8 @@ def _save_dot(self): | |||
handle.close() | |||
|
|||
def _save_svg(self): | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr('Save as SVG'), 'rosgraph.svg', self.tr('Scalable Vector Graphic (*.svg)')) | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr( | |||
'Save as SVG'), 'rosgraph.svg', self.tr('Scalable Vector Graphic (*.svg)')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bad line break
src/rqt_graph/ros_graph.py
Outdated
@@ -389,7 +405,8 @@ def _save_svg(self): | |||
painter.end() | |||
|
|||
def _save_image(self): | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr('Save as image'), 'rosgraph.png', self.tr('Image (*.bmp *.jpg *.png *.tiff)')) | |||
file_name, _ = QFileDialog.getSaveFileName(self._widget, self.tr( | |||
'Save as image'), 'rosgraph.png', self.tr('Image (*.bmp *.jpg *.png *.tiff)')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bad line break
test/dotcode_test.py
Outdated
) | ||
edges, | ||
node_connections, | ||
True, # hide_single_connection_topics, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use a named parameter
test/dotcode_test.py
Outdated
edges, | ||
node_connections, | ||
True, # hide_single_connection_topics, | ||
False # hide_dead_end_topics |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
use a named parameter instead of a comment
test/dotcode_test.py
Outdated
) | ||
edges, | ||
node_connections, | ||
False, # hide_single_connection_topics, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
named parameters
test/dotcode_test.py
Outdated
) | ||
edges, | ||
node_connections, | ||
True, # hide_single_connection_topics, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
named parameters
50bfe39
to
c71c112
Compare
@brawner all good? |
Results of running
autopep8 --max-line-length 130 --in-place $1
on each.py
file