added flake8/black, pre-commit integration for flake8/black, and black formatting changes
This commit is contained in:
parent
d5055f85d3
commit
1fc8d647c3
77 changed files with 4452 additions and 1964 deletions
|
@ -28,8 +28,7 @@ def example(options):
|
|||
|
||||
# create emane network node
|
||||
emane_network = session.create_emane_network(
|
||||
model=EmaneIeee80211abgModel,
|
||||
geo_reference=(47.57917, -122.13232, 2.00000)
|
||||
model=EmaneIeee80211abgModel, geo_reference=(47.57917, -122.13232, 2.00000)
|
||||
)
|
||||
emane_network.setposition(x=80, y=50)
|
||||
|
||||
|
@ -55,7 +54,10 @@ def example(options):
|
|||
def main():
|
||||
options = parser.parse_options("emane80211")
|
||||
start = datetime.datetime.now()
|
||||
print("running emane 80211 example: nodes(%s) time(%s)" % (options.nodes, options.time))
|
||||
print(
|
||||
"running emane 80211 example: nodes(%s) time(%s)"
|
||||
% (options.nodes, options.time)
|
||||
)
|
||||
example(options)
|
||||
print("elapsed time: %s" % (datetime.datetime.now() - start))
|
||||
|
||||
|
|
|
@ -7,10 +7,20 @@ DEFAULT_STEP = 1
|
|||
|
||||
def parse_options(name):
|
||||
parser = argparse.ArgumentParser(description="Run %s example" % name)
|
||||
parser.add_argument("-n", "--nodes", type=int, default=DEFAULT_NODES,
|
||||
help="number of nodes to create in this example")
|
||||
parser.add_argument("-t", "--time", type=int, default=DEFAULT_TIME,
|
||||
help="example iperf run time in seconds")
|
||||
parser.add_argument(
|
||||
"-n",
|
||||
"--nodes",
|
||||
type=int,
|
||||
default=DEFAULT_NODES,
|
||||
help="number of nodes to create in this example",
|
||||
)
|
||||
parser.add_argument(
|
||||
"-t",
|
||||
"--time",
|
||||
type=int,
|
||||
default=DEFAULT_TIME,
|
||||
help="example iperf run time in seconds",
|
||||
)
|
||||
|
||||
options = parser.parse_args()
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue