Skip to content

Commit

Permalink
lint code
Browse files Browse the repository at this point in the history
Signed-off-by: Nischay Ram Mamidi <NischayPro@gmail.com>
  • Loading branch information
Nischay-Pro committed Aug 3, 2023
1 parent adc291b commit c0b6d54
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions ci/benchmark.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@


def main():
commands = ["flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M1D",
"flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M30D",
"flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M60D"]
commands = [
"flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M1D",
"flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M30D",
"flexmeasures show beliefs --sensor-id 6 --sensor-id 16 --sensor-id 15 --sensor-id 8 --sensor-id 5 --sensor-id 4 --start 2023-01-01T05:00:00.000Z --duration P0Y0M60D",
]

timings = {}
max_iterations = 10
Expand All @@ -35,10 +37,10 @@ def run_command(command):
# Run command using subprocess and check for errors but don't print output
try:
subprocess.run(command, shell=True, check=True, stdout=subprocess.DEVNULL)
except subprocess.CalledProcessError as e:
print(e)
except subprocess.CalledProcessError as process_error:
print(process_error)
exit(1)


if __name__ == "__main__":
main()
main()

0 comments on commit c0b6d54

Please sign in to comment.