KrzyHonk / bpmn-python

Project for creating a Python library that allows to import/export BPMN diagram (as an XML file) and provides a simple visualization capabilities
GNU General Public License v3.0
65 stars 44 forks source link

TypeError in diagram layouter #39

Open kamills1248 opened 5 years ago

kamills1248 commented 5 years ago

In function insert_into_grid(grid, row, col, node_id) in bpmn_diagram_layouter.py there's (as a result of some refactor):

grid_cell.row += consts.Consts.width

Which always causes TypeError as value of this const is:

width = "width"

and trying to add integer and string in Python doesn't end well. Probably it should be either:

grid_cell.row += consts.Consts.grid_column_width

which is equal to:

grid_column_width = 2

or:

grid_cell.row += 1

as the comment above this operation suggests:

# if cell is already occupied, insert new row