Since this thing is on the innerwebs I suppose it should have a
authorScott Gasch <[email protected]>
Fri, 25 Mar 2022 16:41:31 +0000 (09:41 -0700)
committerScott Gasch <[email protected]>
Fri, 25 Mar 2022 16:41:31 +0000 (09:41 -0700)
copyright...

87 files changed:
acl.py
ansi.py
argparse_utils.py
arper.py
base_presence.py
bootstrap.py
cached/weather_data.py
cached/weather_forecast.py
camera_utils.py
collect/bidict.py
collect/bst.py
collect/shared_dict.py
collect/trie.py
config.py
constants.py
conversion_utils.py
dateparse/dateparse_utils.py
datetime_utils.py
decorator_utils.py
deferred_operand.py
dict_utils.py
directory_filter.py
exceptions.py
exec_utils.py
executors.py
file_utils.py
function_utils.py
google_assistant.py
histogram.py
id_generator.py
input_utils.py
letter_compress.py
list_utils.py
lockfile.py
logging_utils.py
logical_search.py
math_utils.py
misc_utils.py
ml/model_trainer.py
ml/quick_label.py
orb_utils.py
parallelize.py
persistent.py
profanity_filter.py
remote_worker.py
site_config.py
smart_future.py
smart_home/cameras.py
smart_home/chromecasts.py
smart_home/device.py
smart_home/device_utils.py
smart_home/lights.py
smart_home/outlets.py
smart_home/registry.py
smart_home/thermometers.py
smart_home/tplink_utils.py
state_tracker.py
stopwatch.py
tests/acl_test.py
tests/centcount_test.py
tests/dateparse_utils_test.py
tests/decorator_utils_test.py
tests/dict_utils_test.py
tests/exec_utils_test.py
tests/google_assistant_test.py
tests/letter_compress_test.py
tests/logging_utils_test.py
tests/money_test.py
tests/parallelize_itest.py
tests/profanity_filter_test.py
tests/rate_test.py
tests/run_some_dependencies_test.py
tests/shared_dict_test.py
tests/string_utils_test.py
tests/thread_utils_test.py
tests/waitable_presence_test.py
text_utils.py
thread_utils.py
type/centcount.py
type/locations.py
type/money.py
type/people.py
type/rate.py
type_utils.py
unittest_utils.py
unscrambler.py
waitable_presence.py

diff --git a/acl.py b/acl.py
index cf59d6a87d8266fe55259e9584c403346d6404f7..de516e4fc894208fe582c6f24bffc772bf75a36d 100644 (file)
--- a/acl.py
+++ b/acl.py
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This module defines various flavors of Access Control Lists."""
 
 import enum
diff --git a/ansi.py b/ansi.py
index a49760037e31c6c01e84a225e7147d588f8f5934..dee52424fefa6bd80daccc3d8830c0a707e12b6a 100755 (executable)
--- a/ansi.py
+++ b/ansi.py
@@ -1,8 +1,12 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A bunch of color names mapped into RGB tuples and some methods for
 setting the text color, background, etc... using ANSI escape
-sequences."""
+sequences.
+
+"""
 
 import contextlib
 import difflib
index 045d882a2b6c4b18f4a27fd0267a65dd2b4444e4..83a3aa47be1cd4f632c8960beeb4aefb0d4fc840 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Helpers for commandline argument parsing."""
 
 import argparse
@@ -32,6 +34,7 @@ class ActionNoYes(argparse.Action):
         --no_enable_the_thing
 
     """
+
     def __init__(self, option_strings, dest, default=None, required=False, help=None):
         if default is None:
             msg = 'You must provide a default with Yes/No action'
index 4f362f4157369415511f8a648f6105f1de26498a..b4c079edcc750307356b60fdba39ca5b43f5c38a 100644 (file)
--- a/arper.py
+++ b/arper.py
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A caching layer around the kernel's network mapping between IPs and MACs"""
 
 
index 8be4d936d7a5e1e9be2027e8b3ad5b7ea47b98de..f996d548cc354d65f8a0e5d94c6a3b0e6486d89a 100755 (executable)
@@ -1,9 +1,13 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a module dealing with trying to guess a person's location
 based on the location of certain devices (e.g. phones, laptops)
 belonging to that person.  It works with networks I run that log
-device MAC addresses active."""
+device MAC addresses active.
+
+"""
 
 import datetime
 import logging
index 52359f11ab77b64e4fd604528e8cdad54e557a33..117468623b94e578894561d0ff6fede8a9a33135 100644 (file)
@@ -1,10 +1,14 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a module for wrapping around python programs and doing some
 minor setup and tear down work for them.  With it, you can break into
 pdb on unhandled top level exceptions, profile your code by passing a
 commandline argument in, audit module import events, examine where
-memory is being used in your program, and so on."""
+memory is being used in your program, and so on.
+
+"""
 
 import functools
 import importlib
index 1b0bef429d4dfcc751e9bf52060c1371080f71d4..29a1d544b042101042eeb9d0a1eb781de094e427 100644 (file)
@@ -1,6 +1,10 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""How's the weather?"""
+
 import datetime
 import json
 import logging
index 807f36d2bcd9c5770d6fa5e5bc897dcc791f8ca1..b8a20ed8caa04553f01225a5a2f8f57866858ea7 100644 (file)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""How's the weather going to be tomorrow?"""
+
 import datetime
 import logging
 import os
index 378d286631fa621a03df3844a725b03dd18ab3df..bfa23abdaa86c120deb15df6e870e3397b17e266 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with webcam images."""
 
 import logging
index d28817453775e6f4dc35804a445dc2f6a9915bc4..375721e4a2652564ddfe42c6dc61925f8c7b4a76 100644 (file)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""Bidirectional Dictionary."""
+
 
 class BiDict(dict):
     def __init__(self, *args, **kwargs):
index 712683eb59ea3c38939ebf4f5a4cb31c191199f8..d39419494d3f482712f17e13a5ff6ce1e7c2ebcf 100644 (file)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""Binary search tree."""
+
 from typing import Any, Generator, List, Optional
 
 
index f4ec9143ab80b08b0ca819c4bca62cf20362fb66..3207927ed2f550b6516bce0c1b72fd96d7581ba4 100644 (file)
@@ -4,7 +4,7 @@
 The MIT License (MIT)
 
 Copyright (c) 2020 LuizaLabs
-Additions Copyright (c) 2022 Scott Gasch
+Additions/Modifications Copyright (c) 2022 Scott Gasch
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
@@ -29,7 +29,6 @@ This class is based on https://github.com/luizalabs/shared-memory-dict
 
 import pickle
 from contextlib import contextmanager
-from functools import wraps
 from multiprocessing import RLock, shared_memory
 from typing import (
     Any,
@@ -42,8 +41,6 @@ from typing import (
     ValuesView,
 )
 
-from decorator_utils import synchronized
-
 
 class PickleSerializer:
     def dumps(self, obj: dict) -> bytes:
index fef28cb40ddfbad3ea1c4d45f341f8e5c7407127..547d67a4124abc07f425ecf21616bf2c509beb4e 100644 (file)
@@ -1,9 +1,13 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a Trie class, see: https://en.wikipedia.org/wiki/Trie.
 
-   It attempts to follow Pythonic container patterns.  See doctests
-   for examples."""
+It attempts to follow Pythonic container patterns.  See doctests
+for examples.
+
+"""
 
 from typing import Any, Generator, Sequence
 
index 57593c3a33c01505bd87918be3591459b508743f..bea701837c520ca86d584f9b48cead98ab06e838 100644 (file)
--- a/config.py
+++ b/config.py
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Global configuration driven by commandline arguments, environment variables
 and saved configuration files.  This works across several modules.
 
index 934edb292ce6c7f21c1ded775091a82f902c9538..1a615815d342ff5cf974b8c0a3583a4f43af42d1 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Universal constants."""
 
 from typing import Final
index cf4fcaab93f75291d7e24bf54d55f672eace1578..68292caccbc692570010ab5ed98c10cbcc05d9c7 100644 (file)
@@ -1,6 +1,8 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities involving converting between different units."""
 
 from typing import Callable, SupportsFloat
index d0d1eca8e4c564d2fec240b95576e8eac4d80596..bd0d491f17e55fc4eef1894cfbe8a544b88787f2 100755 (executable)
@@ -3,6 +3,8 @@
 # pylint: disable=W0201
 # pylint: disable=R0904
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Parse dates in a variety of formats."""
 
 import datetime
index cbebf4dffada4955703859186d3b4d2d411dec53..b05097a909a53a1a39836dffbd91e02887b8aabd 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities related to dates and times and datetimes."""
 
 import datetime
index 5d1e779deeeaa3df34547f853ce5e4fc0cdcb87b..084e260bab370d9bbb93a1256ff84e98f96055bd 100644 (file)
@@ -1,5 +1,8 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+# Portions (marked) below retain the original author's copyright.
+
 """Decorators."""
 
 import enum
index 1de2bfb0931ffa8b9bfdd754e7ac00ad3551af90..df762376c1b16374440c2a5ea7cda8d568bd5e58 100644 (file)
@@ -1,8 +1,12 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a helper class that tries to define every __dunder__ method
 so as to defer that evaluation of an object as long as possible.  It
-is used by smart_future.py as a base class."""
+is used by smart_future.py as a base class.
+
+"""
 
 from abc import ABC, abstractmethod
 from typing import Any, Generic, TypeVar
index ecd23fda0fe0f4624a27ca6a8971dd068ce2958e..6f0f572e988cd5fdfea2e52c1fe1da8e50a80188 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Helper functions for dealing with dictionaries."""
 
 from itertools import islice
index 6985831fc3a6e3d8fe24550c831293e40383b9a6..69e5547255e20ac66cfea81658867c8697501126 100644 (file)
@@ -1,10 +1,14 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Two predicates that can help avoid unnecessary disk I/O by
 detecting if a particular file is identical to the contents about to
 be written or if a particular directory already contains a file that
 is identical to the one to be written.  See class docs below for
-examples."""
+examples.
+
+"""
 
 import hashlib
 import logging
index aa0aecbef67abd8320db01c71446cc7ca5a24617..bd499886221ba55e044a739e835fdc4af8c98c6e 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Some exceptions used elsewhere."""
 
 # This module is commonly used by others in here and should avoid
index a440de5375c1546d0bf46835bc00ecada06b7d9d..ae406ef41e925ddbd9ba5483ca1312b5686449e3 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Helper methods concerned with executing subprocesses."""
 
 import atexit
index fcdd3e7b63e379d8c65bb0925b8bffaea2b725fa..e07933f454909d5a543e340320a578aab528d9ad 100644 (file)
@@ -1,6 +1,8 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Defines three executors: a thread executor for doing work using a
 threadpool, a process executor for doing work in other processes on
 the same machine and a remote executor for farming out work to other
index 98e8c2670fd173fb11be51327fb6925a2b47f1eb..91aeea072b03d94d670a13ca1a348b407d5734b8 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for working with files."""
 
 import contextlib
index f10776211df3ef8347d48486671577bc18d044bc..f74a852d7d8834ccc38bda39f21c6d381339a7f1 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Helper methods dealing with functions."""
 
 from typing import Callable
index adfdca49afb99bc3862611649ad5661ab558249c..b767df75f4a56f4b4ec84be3abedd16b2e8a591b 100644 (file)
@@ -1,7 +1,11 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A module to serve as a local client library around HTTP calls to
-the Google Assistant via a local gateway."""
+the Google Assistant via a local gateway.
+
+"""
 
 import logging
 import warnings
index 3796470d211ba27e1ce36cfbb6ea18957a9a892f..52a0d1fad558a493c6e303abdd07a6933053a045 100644 (file)
@@ -1,6 +1,8 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A text-based simple histogram helper class."""
 
 import math
index dc2ac9cc810a4e1d588d60231371e873d9d31966..f15efa360e46a07e59d21fe4b85e950f4fcf05a0 100644 (file)
@@ -1,7 +1,11 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A helper class for generating thread safe monotonically increasing
-id numbers."""
+id numbers.
+
+"""
 
 import itertools
 import logging
index 7d5e18089331a96bc32172b90e916a37c0695d49..77094daaa7a70cd83ebf0e2b5ba0adac311d2b01 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities related to user input."""
 
 import logging
index 42f06dae79a8357bcffd0730194d5c2d1d352f11..6cb6b74e87c54928a5aeb7e184114e81ff877b02 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A simple compression helper for lowercase ascii text."""
 
 import bitstring
index 7f28ade922a4b733ee29ea0c68bc957ff587c51b..5c70df3476c6dbafe3c252788e88ee6b16c5c301 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Some useful(?) utilities for dealing with Lists."""
 
 import random
index f64a2c3aeba2eec62ea09246db2af44409a67d69..ae48e576ccbcfb123ddfcde6ab32c71dfc381ad0 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """File-based locking helper."""
 
 from __future__ import annotations
index 7b70d759879e5f537f0a60d60d4692c2bd1536be..6ceba65f7b8ee2413ae8e1595bf653d169856e95 100644 (file)
@@ -1,6 +1,8 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities related to logging."""
 
 import collections
index ef55a2bbdcbb5baafa5c29a53fc404fcfb4701bb..b6d7479879010d6ea40ef813d03e84574ead7e55 100644 (file)
@@ -1,8 +1,12 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a module concerned with the creation of and searching of a
 corpus of documents.  The corpus is held in memory for fast
-searching."""
+searching.
+
+"""
 
 from __future__ import annotations
 import enum
index 49ad407a58330144116c7d07976462a521f46d46..dec34f049aa0382823768c53efc2060ae8c69409 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Mathematical helpers."""
 
 import collections
index a73728a28031d48703187ff3a86274ec05ab2950..f844f721bdacd5741719c1719593e09fd2d69036 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Miscellaneous utilities."""
 
 import os
index 15095770cf71f1c7b4fd05e5d3c10a7488775792..e3d89c20421619533da6c8fdcddee739ed33ddff 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a blueprint for training sklearn ML models."""
 
 from __future__ import annotations
index da9a1d2e00d15e32cce697e3782a5cfce87ea584..15256a30da2e8847f15bf114dc23eb7ff755c930 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A helper to facilitate quick manual labeling of ML training data."""
 
 import glob
index 6a12b6f7b1970e92d0697b3633ac35db72895555..f1d0ee0d9c781cc418231d39b49e8b9320a2ed7a 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities related to changing the orb's color."""
 
 import os
index b2a1cedb988d98d78cf7654e3f65d4dfaa8beff6..77d7649fe956a1542c1a60ce99ca96365ef59ce0 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A decorator to help with dead simple parallelization."""
 
 
index c902313eb4a28cb4635779f584f8775a2b646d35..27aa4b32aed2fdb299e2c1031a041a19b3c385a5 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A Persistent is just a class with a load and save method.  This
 module defines the Persistent base and a decorator that can be used to
 create a persistent singleton that autoloads and autosaves."""
index c1767bf16370bae17b63b56d426c7fc2e9e49519..a1f0c0b9adaa8971dfd243694cd096a2e84a077d 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A helper to identify and optionally obscure some bad words."""
 
 import logging
index 75dfe8e46cb3d34e28f44267129ff38020d23a7a..8aef1dee1bc94a1bb85a378adab7169810b585ce 100755 (executable)
@@ -1,7 +1,10 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A simple utility to unpickle some code, run it, and pickle the
 results.
+
 """
 
 import logging
index 5a4eeffbafd5c2f32ddd412f41986ec92f481985..5604de676c0ded41ce5edcc051809ac7968c6286 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Location/site dependent data."""
 
 import logging
index a1f6d97741db715871d404d5a126d87a5601b503..7aac8ebb68eb3bb3af6da50b127cfb344ff925e3 100644 (file)
@@ -1,9 +1,13 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A future that can be treated like the result that it contains and
 will not block until it is used.  At that point, if the underlying
 value is not yet available, it will block until it becomes
-available."""
+available.
+
+"""
 
 from __future__ import annotations
 import concurrent
index f77ddc6a7ff22bac1fe1a63a6d09fb40e2dbc129..e7705b29ab9d5b1ced6723bb94418e0062c259c5 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with the webcams."""
 
 import logging
index dd6d217e3d4ce3d9a79cf4b42f930ab5e993e0e8..408ccf0e12ff3b1702ef7cd4b63d42c357fac7db 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with the webcams."""
 
 import atexit
index 82f1fa6eb89943d03a4f348621767a857d944418..64302ad791b35131e597472547e81027c6ec4451 100644 (file)
@@ -1,8 +1,12 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Most basic definition of a smart device: it must have a name and a
 MAC address and may have some optional keywords.  All devices have
-these whether they are lights, outlets, thermostats, etc..."""
+these whether they are lights, outlets, thermostats, etc...
+
+"""
 
 import re
 from typing import List, Optional
index 40a7b70ed3d357797fa979bd1d0f8554abc0d789..0c0ca989b80898735a675ddb662f2a372dd28245 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """General utility functions involving smart home devices."""
 
 import logging
index 2a0b1cd802f500eae7caa94d82d32dd283904403..ee23fb08f4e60ef4664338cde7e53bdefd340544 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with the smart lights."""
 
 import datetime
index 37655673550364f77c0e97c693058575bb4a9821..fcc3c4eb8f7fa74d428d31c7ebe4814c5cb11cbd 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with the smart outlets."""
 
 import asyncio
index f79ae90c15f5f7c881ae1acecaee434681aaf2aa..d63474da56f98bc44d78a221f47c3f4fd7d04971 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A searchable registry of known smart home devices and a factory for
 constructing our wrappers around them."""
 
index 90199b9cdaa3dd0e2f09c9a7a521b0b03c8b7e5b..73117bc1a3cccddf0c22be8ab8cb10572b3b41f8 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Code involving querying various smart home thermometers."""
 
 import logging
index 30d3bd83e7a40d7cd1878b0ed0a2121b62fdfc97..abf4970c3c9593f76b641114716fcff88a782627 100644 (file)
@@ -10,7 +10,7 @@ You may obtain a copy of the License at
 
      http://www.apache.org/licenses/LICENSE-2.0
 
-Modifications by Scott Gasch Copyright 2020-2022 also released under
+Modifications by Scott Gasch Copyright © 2020-2022 also released under
 the Apache 2.0 license as required by the license (see above).
 
 Unless required by applicable law or agreed to in writing, software
index 1cf62af6ea8000e5d1ed32646ec0a212a0b55faf..62eb183dba7bfc90a4bbbff73b4401f2d747231b 100644 (file)
@@ -1,9 +1,13 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Several helpers to keep track of internal state via periodic
 polling.  StateTracker expects to be invoked periodically to maintain
 state whereas the others automatically update themselves and,
-optionally, expose an event for client code to wait on state changes."""
+optionally, expose an event for client code to wait on state changes.
+
+"""
 
 import datetime
 import logging
index ae8e01aa18452ed932ef589b9047c7f0c68ab58a..4e69b6992b278df8eb8e725954d9c610468318aa 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A simple stopwatch decorator / context for timing things."""
 
 import contextlib
index a1d827e4906d36a5dc566f4b9aeedf27699fce58..400961728b28039d95b20b23f73b10d37c7fd399 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""acl unittest."""
+
 import re
 import unittest
 
index c4b3b0c5bd22654aa63d2890b89e86c779ca61b6..53204c9fdb8fcbf3f64db5d68523b310480c0d5b 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""centcount unittest."""
+
 import unittest
 
 import unittest_utils as uu
index 42df954c7749ed0f45e5b0ea3d17379e9ff29cf4..6e539ff8ccce9592e09dd48a94b0d6b13bf0703f 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""dateparse_utils unittest."""
+
 import datetime
 import random
 import re
index 2cc2b5f71d14d7295e4610ffccf16f543c766478..68f1389cfa4895545cf0b7c7d25346807ae8c905 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""decorator_utils unittest such as it is."""
+
 import unittest
 
 import decorator_utils as du
index a8f627344256d396fe21f6e72a0ef263fd25bc8a..8964f91701e9cab3af4c7e9b5736fbc09263e7e3 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""dict_utils unittest."""
+
 import unittest
 
 import dict_utils as du
index eb179da7a200e11c7a2d078e85bcc0b8558c2964..4c003aa4f045d46d939ade972f47027a8b4ae4bd 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""exec_utils unittest."""
+
 import unittest
 
 import exec_utils
index 857c1e4d332875dfd294ab397308e4b6e690b941..a16259455a8be80840a346626f09932728eb16c5 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""google_assistant unittest."""
+
 import unittest
 from unittest.mock import MagicMock, patch
 
index e67838a3d32dd6e7c6415ba7edbb73b81c6ad717..1a47ba4f9c43e3104673ba70b916196eefdc1999 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""letter_compress unittest."""
+
 import math
 import random
 import unittest
index a9625d621b26278567adac68a84520f618a08238..99ceeaedada958c9912a1d8e15fc2ee8d4640956 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""logging_utils unittest."""
+
 import os
 import sys
 import tempfile
index f9815322817aea4e2657abf437a019d6b22995a1..bbca499e78a31fedb878b95005c9c993f9cb0d65 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""money unittest."""
+
 import unittest
 
 import unittest_utils as uu
index 409b8dc174078b1c5810098e290c042a1e9f38c3..ef154a70d92eb4a32339bc4eb5a121561878aa50 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""parallelize unittest."""
+
 import logging
 import sys
 
index e452d6ac072cc0b2f7a7935262727245b43a53d3..94b2725bf93abdc45fc6866974687908846b27b3 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""profanity_filter unittest, you fucker."""
+
 import unittest
 
 import profanity_filter as pf
index e75011921c2fa1432a7824a1e0c91e41dc1585a4..df4ccae50112551fab8c216c8545a23d631fc68a 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""rate unittest."""
+
 import unittest
 
 import unittest_utils as uu
index fcc9e7a29341ca5db4e859cba6ec875ce600feb3..c9f48a51a77d1b7c35bb1925e434198885d886ea 100755 (executable)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """This is a "test" that just runs a few system utilities that have
 dependencies on this library in "do nothing" mode and makes sure they
 exit cleanly.
index 0b73a45bdabbb663873c9ac883e045a642fd3cc3..230bdb989c4c5e74c6d31cecebee3ea468b277c8 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""shared_dict unittest."""
+
 import unittest
 
 import parallelize as p
index 51848946b68c3b661cb21d6b7d38c3eaad15e5ef..c111b64f9bbb934a1fcb4ae2b8133a085ad62edd 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""string_utils unittest."""
+
 import unittest
 
 import bootstrap
index 7fcdca8f74fe04f890b68bea68a696fcfe61dab2..40ecfac80b403ce81ea9b90af0addf8ec9dce263 100755 (executable)
@@ -1,5 +1,9 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
+"""thread_utils unittest."""
+
 import threading
 import time
 import unittest
index ff4225c9798ec93a7ad008b60aeabfed033af56f..f9e95e96a2b25f9b97d0d3d2204c7b0935dd739e 100755 (executable)
@@ -1,6 +1,9 @@
 #!/usr/bin/env python3
 
-import re
+# © Copyright 2021-2022, Scott Gasch
+
+"""waitable_presence unittest."""
+
 import unittest
 from unittest.mock import MagicMock
 
index a6337d6c5382b80ee75a7c199849123a7e97cea8..f04c61813ef227c4bfe356f42d08c59f2234132c 100644 (file)
@@ -1,6 +1,8 @@
 #!/usr/bin/env python3
 # -*- coding: utf-8 -*-
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with "text"."""
 
 import contextlib
index 2375f3df3938b6a5562911af28202a909b0a0cd7..01755deafc1e7af9189026c2ae233c6146c7d494 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utilities for dealing with threads + threading."""
 
 import functools
index 4529695cd92174fe7e6aaff60df63dcad999d296..e78d068910e8281cbf28ee8674e7b6cff44f89fd 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """An amount of money (USD) represented as an integral count of
 cents."""
 
index e02b8ab8e5652c088a94f5b6d30acc3f399b9caf..b311064a680bf87350949c419e36bd9a474816ae 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """An enum to represent locations."""
 
 import enum
index b84652b75b1f594c98566ff54fe0105a5b1fa810..99637d1f23bd607c8856f4fada204b1859c51f3d 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A class to represent money.  See also centcount.py"""
 
 import re
index d942ebb9ce8c3e4417d67f13d2fa23bf90d10a45..521c63babc6afb8d257fd3de4f53aa8a04972aff 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """An enum to represent people."""
 
 import enum
index c365848fa0bd2eb1a34916ec5e8071348e0dffdc..58489061570ab3a1a6f96728c04361ad760e21d1 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A class to represent a rate of change."""
 
 from typing import Optional
index c2f432a2306fee2a828eaf8b9d0de41c224d3380..5e4187ec03658de957983a705349dda80876cd6d 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Utility functions for dealing with typing."""
 
 import logging
index 88e41954811de26629b405cb4ee7255d8bbebc62..28b577e2086af4ff20647d05cd9be24761839d6d 100644 (file)
@@ -1,10 +1,12 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """Helpers for unittests.  Note that when you import this we
-   automatically wrap unittest.main() with a call to
-   bootstrap.initialize so that we getLogger config, commandline args,
-   logging control, etc... this works fine but it's a little hacky so
-   caveat emptor.
+automatically wrap unittest.main() with a call to bootstrap.initialize
+so that we getLogger config, commandline args, logging control,
+etc... this works fine but it's a little hacky so caveat emptor.
+
 """
 
 import contextlib
index 1b242309b649eaa036277fdb22fc6f9c7705f0c8..a40213e2a7fcdb7663b7479ac3979c1ccb485938 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A fast word unscrambler library."""
 
 import logging
index 9247a67891307fb9b93e5695df68347577f86c9b..6473add5b2f7f4fb023e03a71342c93a4b2aacd5 100644 (file)
@@ -1,5 +1,7 @@
 #!/usr/bin/env python3
 
+# © Copyright 2021-2022, Scott Gasch
+
 """A PresenceDetector that is waitable.  This is not part of
 base_presence.py because I do not want to bring these dependencies
 into that lower-level module (especially state_tracker).