Skip to content

Commit

Permalink
Update worker main() function docstrings (#287)
Browse files Browse the repository at this point in the history
* Update worker main() function docstrings

Remove non-informative "Set up and run the worker." line at the beginning.

* Add worker main() function docstrings
  • Loading branch information
douglatornell authored Jul 23, 2024
1 parent 30a63dd commit f0cf475
Show file tree
Hide file tree
Showing 34 changed files with 49 additions and 87 deletions.
4 changes: 4 additions & 0 deletions nowcast/workers/archive_tarball.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@


def main():
"""For command-line usage see:
:command:`python -m nowcast.workers.archive_tarball --help`
"""
worker = NowcastWorker(NAME, description=__doc__)
worker.init_cli()
worker.cli.add_argument(
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/collect_NeahBay_ssh.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.collect_NeahBay_ssh --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/collect_weather.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.collect_weather --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/download_fvcom_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.download_fvcom_results --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/download_live_ocean.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,9 +41,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.download_live_ocean -h`
"""
Expand Down
4 changes: 4 additions & 0 deletions nowcast/workers/download_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,10 @@


def main():
"""For command-line usage see:
:command:`python -m nowcast.workers.download_results --help`
"""
worker = NowcastWorker(NAME, description=__doc__)
worker.init_cli()
worker.cli.add_argument(
Expand Down
4 changes: 4 additions & 0 deletions nowcast/workers/download_wwatch3_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,10 @@


def main():
"""For command-line usage see:
:command:`python -m nowcast.workers.download_wwatch3_results --help`
"""
worker = NowcastWorker(NAME, description=__doc__)
worker.init_cli()
worker.cli.add_argument(
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/get_onc_ferry.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,9 +45,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.get_onc_ferry -h`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/launch_remote_worker.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.launch_remote_worker --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_CHS_currents_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_CHS_currents_file --help`
"""
Expand Down
4 changes: 4 additions & 0 deletions nowcast/workers/make_feeds.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@


def main():
"""For command-line usage see:
:command:`python -m nowcast.workers.make_feeds --help`
"""
worker = NowcastWorker(NAME, description=__doc__)
worker.init_cli()
worker.cli.add_argument(
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_forcing_links.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_forcing_links --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_fvcom_atmos_forcing.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_fvcom_atmos_forcing --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_fvcom_boundary.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_fvcom_boundary --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_fvcom_rivers_forcing.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_fvcom_rivers_forcing --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_runoff_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_runoff_file --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_ssh_files.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_ssh_file --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/make_turbidity_file.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,9 +37,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.make_turbidity_file --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/ping_erddap.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.ping_erddap --help`
"""
Expand Down
4 changes: 4 additions & 0 deletions nowcast/workers/rotate_hindcast_logs.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@


def main():
"""For command-line usage see:
:command:`python -m nowcast.workers.rotate_hindcast_logs --help`
"""
worker = NowcastWorker(NAME, description=__doc__)
worker.init_cli()
worker.run(rotate_hindcast_logs, success, failure)
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/run_NEMO.py
Original file line number Diff line number Diff line change
Expand Up @@ -36,9 +36,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.run_NEMO --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/run_NEMO_agrif.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.run_NEMO_agrif --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/run_NEMO_hindcast.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.run_NEMO_hindcast --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/run_fvcom.py
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.run_fvcom --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/run_ww3.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.run_ww3 --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/split_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.split_results --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/update_forecast_datasets.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.update_forecast_datasets -h`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/upload_forcing.py
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.upload_forcing --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/upload_fvcom_atmos_forcing.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.upload_fvcom_atmos_forcing --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/watch_NEMO.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.watch_NEMO --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/watch_NEMO_agrif.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.watch_NEMO_agrif --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/watch_NEMO_hindcast.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.watch_NEMO_hindcast --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/watch_fvcom.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.watch_fvcom --help`
"""
Expand Down
4 changes: 1 addition & 3 deletions nowcast/workers/watch_ww3.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,7 @@


def main():
"""Set up and run the worker.
For command-line usage see:
"""For command-line usage see:
:command:`python -m nowcast.workers.watch_ww3 --help`
"""
Expand Down

0 comments on commit f0cf475

Please sign in to comment.