diff --git a/Pipfile b/Pipfile index 710710d..167040c 100644 --- a/Pipfile +++ b/Pipfile @@ -8,7 +8,7 @@ verify_ssl = true [packages] apscheduler = "*" dba-metrics = {editable = true,path = "."} -nerium = {editable = true,git = "https://github.com/tym-xqo/nerium",ref = "b4d99a3"} +nerium = {editable = true,git = "https://github.com/tym-xqo/nerium",ref = "e600c93"} # nerium = {editable = true, path = "../nerium"} pg8000 = "*" slackclient = "*" diff --git a/Pipfile.lock b/Pipfile.lock index e2901a6..efc475a 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -1,7 +1,7 @@ { "_meta": { "hash": { - "sha256": "3b1db4ea5e8da934b3861c5cd197f146a64c8c652848f1944e5815c08f90fa63" + "sha256": "2c034721bdf4a9815d4ff1cd703999736669651034a5994bb406a94490ebaaae" }, "pipfile-spec": 6, "requires": {}, @@ -79,10 +79,10 @@ }, "certifi": { "hashes": [ - "sha256:59b7658e26ca9c7339e00f8f4636cdfe59d34fa37b9b04f6f9e9926b3cece1a5", - "sha256:b26104d6835d1f5e49452a26eb2ff87fe7090b89dfcaee5ea2212697e1e1d7ae" + "sha256:046832c04d4e752f37383b628bc601a7ea7211496b4638f6514d0e5b9acc4939", + "sha256:945e3ba63a0b9f577b1395204e13c3a231f9bc0223888be653286534e5873695" ], - "version": "==2019.3.9" + "version": "==2019.6.16" }, "cffi": { "hashes": [ @@ -124,6 +124,13 @@ ], "version": "==3.0.4" }, + "click": { + "hashes": [ + "sha256:2335065e6395b9e67ca716de5f7526736bfa6ceead690adf616d925bdc622b13", + "sha256:5b94b49521f6456670fdb30cd82a4eca9412788a93fa6dd6df72c94d5a8ff2d7" + ], + "version": "==7.0" + }, "dba-metrics": { "editable": true, "path": "." @@ -147,6 +154,13 @@ ], "version": "==1.0.1" }, + "flask": { + "hashes": [ + "sha256:ad7c6d841e64296b962296c2c2dabc6543752985727af86a975072dea984b6f3", + "sha256:e7d32475d1de5facaa55e3958bc4ec66d3762076b074296aa50ef8fdc5b9df61" + ], + "version": "==1.0.3" + }, "idna": { "hashes": [ "sha256:c357b3f628cf53ae2c4c05627ecc484553142ca23264e593d327bcde5e9c3407", @@ -154,6 +168,13 @@ ], "version": "==2.8" }, + "itsdangerous": { + "hashes": [ + "sha256:321b033d07f2a4136d3ec762eac9f16a10ccd60f53c0c91af90217ace7ba1f19", + "sha256:b12271b2047cb23eeb98c8b5622e2e5c5e9abd9784a153e9d8ef9cb4dd09d749" + ], + "version": "==1.1.0" + }, "jdcal": { "hashes": [ "sha256:1abf1305fce18b4e8aa248cf8fe0c56ce2032392bc64bbd61b5dff2a19ec8bba", @@ -203,10 +224,10 @@ }, "marshmallow": { "hashes": [ - "sha256:0e497a6447ffaad55578138ca512752de7a48d12f444996ededc3d6bf8a09ca2", - "sha256:e21a4dea20deb167c723e0ffb13f4cf33bcbbeb8a334e92406a3308cedea2826" + "sha256:9cedfc5b6f568d57e8a2cf3d293fbd81b05e5ef557854008d03e25660a39ccfd", + "sha256:a4d99922116a76e5abd8f997ec0519086e24814b7e1e1344bebe2a312ba50235" ], - "version": "==2.19.2" + "version": "==2.19.5" }, "multidict": { "hashes": [ @@ -245,7 +266,7 @@ "nerium": { "editable": true, "git": "https://github.com/tym-xqo/nerium", - "ref": "b4d99a3f52ad14a562811aa1c081d1a6c44679a6" + "ref": "e600c93ec68d5bea97eb06944bbb101a3d9c4d3a" }, "odfpy": { "hashes": [ @@ -366,10 +387,10 @@ }, "sqlalchemy": { "hashes": [ - "sha256:c7fef198b43ef31dfd783d094fd5ee435ce8717592e6784c45ba337254998017" + "sha256:c30925d60af95443458ebd7525daf791f55762b106049ae71e18f8dd58084c2f" ], "markers": "python_version >= '3.0'", - "version": "==1.3.4" + "version": "==1.3.5" }, "sqlparse": { "hashes": [ @@ -398,6 +419,13 @@ ], "version": "==1.25.3" }, + "werkzeug": { + "hashes": [ + "sha256:865856ebb55c4dcd0630cdd8f3331a1847a819dda7e8c750d3db6f2aa6c0209c", + "sha256:a0b915f0815982fb2a09161cb8f31708052d0951c3ba433ccc5e1aa276507ca6" + ], + "version": "==0.15.4" + }, "xlrd": { "hashes": [ "sha256:546eb36cee8db40c3eaa46c351e67ffee6eeb5fa2650b71bc4c758a29a1b29b2", diff --git a/dba_metrics/__main__.py b/dba_metrics/__main__.py index 5e01d9a..7dd3855 100644 --- a/dba_metrics/__main__.py +++ b/dba_metrics/__main__.py @@ -105,7 +105,7 @@ def create_table(): store_db.query(sql) -if __name__ == "__main__": +def main(): parser = argparse.ArgumentParser() parser.add_argument("name", nargs="?", default="all") parser.add_argument("-s", "--store", action="store_true", default=False) @@ -120,4 +120,8 @@ def create_table(): if args.schedule: schedule(output_function, args.name) else: - results = output_all(output_function, args.name) + output_all(output_function, args.name) + + +if __name__ == "__main__": + main() diff --git a/setup.py b/setup.py index 8a7683b..3530c79 100644 --- a/setup.py +++ b/setup.py @@ -8,8 +8,8 @@ description="Script to run check queries on postgres", author="Thomas Yager-Madden", author_email="tym@benchprep.com", - install_requires=["apscheduler", "nerium", "pg8000", "slackclient"], - entry_points={"console_scripts": ["dba_metrics = dba_metrics.__main__:main"]}, + install_requires=["apscheduler", "nerium", "pg8000", "records", "slackclient"], + entry_points={"console_scripts": ["dbamtx = dba_metrics.__main__:main"]}, classifiers=[ "Development Status :: 3 - Alpha", "Environment :: Console",