Skip to content

Commit

Permalink
fixing style #22
Browse files Browse the repository at this point in the history
  • Loading branch information
behrisch committed May 15, 2024
1 parent 07ed6b7 commit 0ee4510
Showing 1 changed file with 6 additions and 5 deletions.
11 changes: 6 additions & 5 deletions tools/distributeChargingStations.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,8 @@ def main(options):
remainingChargingPoints = chargingPointCount
for i in range(len(capacities)):
if capacities[i] >= remainingChargingPoints:
addChargingStation(
options, additionals, edge, edge2parkingArea[edge][i][0], remainingChargingPoints, "%s%d" % (options.prefix, csIndex))
addChargingStation(options, additionals, edge, edge2parkingArea[edge][i][0],
remainingChargingPoints, "%s%d" % (options.prefix, csIndex))
csIndex += 1
remainingChargingPoints = 0
edge2parkingArea[edge].remove(edge2parkingArea[edge][i])
Expand All @@ -137,9 +137,10 @@ def main(options):
capacities = [p[1] for p in edge2parkingArea[edge]]
for i in range(len(capacities)):
installChargingPoints = min(remainingChargingPoints, capacities[i])
result = addChargingStation(
options, additionals, edge, edge2parkingArea[edge][i][0], installChargingPoints, "%s%d" % (options.prefix, csIndex))
# print("added charging station with %d points on parkingArea %s %s" % (installChargingPoints, edge2parkingArea[edge][i][0].id, result))
addChargingStation(options, additionals, edge, edge2parkingArea[edge][i][0],
installChargingPoints, "%s%d" % (options.prefix, csIndex))
# print("added charging station with %d points on parkingArea %s %s" %
# (installChargingPoints, edge2parkingArea[edge][i][0].id, result))
csIndex += 1
remainingChargingPoints -= installChargingPoints
if remainingChargingPoints == 0:
Expand Down

0 comments on commit 0ee4510

Please sign in to comment.