From 9c2946718f821283b2b576c5510d593427540acf Mon Sep 17 00:00:00 2001 From: Arthur Lu Date: Sat, 30 Oct 2021 03:51:03 +0000 Subject: [PATCH] removed testing notebook, anticipated removal of pandas requirement, added pandas and matplotlib to pyinstaller exclusion, removed unessasary option in build scripts Former-commit-id: 0fd24d42e12a16fc929945cc5cdd6745ce023171 --- build/build-CLI.bat | 2 +- build/build-CLI.sh | 2 +- src/cli/data.py | 1 - src/cli/superscript.spec | 5 +- src/cli/testing.ipynb | 116 --------------------------------------- src/requirements.txt | 2 - 6 files changed, 6 insertions(+), 122 deletions(-) delete mode 100644 src/cli/testing.ipynb diff --git a/build/build-CLI.bat b/build/build-CLI.bat index 22dd93c..29199e2 100644 --- a/build/build-CLI.bat +++ b/build/build-CLI.bat @@ -2,4 +2,4 @@ set pathtospec="../src/cli/superscript.spec" set pathtodist="../dist/" set pathtowork="temp/" -pyinstaller --onefile --clean --distpath %pathtodist% --workpath %pathtowork% %pathtospec% \ No newline at end of file +pyinstaller --clean --distpath %pathtodist% --workpath %pathtowork% %pathtospec% \ No newline at end of file diff --git a/build/build-CLI.sh b/build/build-CLI.sh index 302265b..e328718 100644 --- a/build/build-CLI.sh +++ b/build/build-CLI.sh @@ -2,4 +2,4 @@ pathtospec="../src/cli/superscript.spec" pathtodist="../dist/" pathtowork="temp/" -pyinstaller --onefile --clean --distpath ${pathtodist} --workpath ${pathtowork} ${pathtospec} \ No newline at end of file +pyinstaller --clean --distpath ${pathtodist} --workpath ${pathtowork} ${pathtospec} \ No newline at end of file diff --git a/src/cli/data.py b/src/cli/data.py index c46e726..1d9c056 100644 --- a/src/cli/data.py +++ b/src/cli/data.py @@ -1,5 +1,4 @@ import requests -import pandas as pd def pull_new_tba_matches(apikey, competition, cutoff): api_key= apikey diff --git a/src/cli/superscript.spec b/src/cli/superscript.spec index 04cafa7..5d09620 100644 --- a/src/cli/superscript.spec +++ b/src/cli/superscript.spec @@ -13,7 +13,10 @@ a = Analysis(['superscript.py'], ], hookspath=[], runtime_hooks=[], - excludes=[], + excludes=[ + "matplotlib", + "pandas" + ], win_no_prefer_redirects=False, win_private_assemblies=False, cipher=block_cipher, diff --git a/src/cli/testing.ipynb b/src/cli/testing.ipynb deleted file mode 100644 index 904b8ac..0000000 --- a/src/cli/testing.ipynb +++ /dev/null @@ -1,116 +0,0 @@ -{ - "cells": [ - { - "cell_type": "code", - "execution_count": 1, - "metadata": {}, - "outputs": [], - "source": [ - "class C1:\n", - "\tval = 0\n", - "\tdef __init__(self, i):\n", - "\t\tself.val = i\n", - "\n", - "class C2:\n", - "\tval = 0\n", - "\tdef __init__(self, i):\n", - "\t\tself.val = 2*i\n", - "\n", - "class C3:\n", - "\tval = 0\n", - "\tdef __init__(self, i):\n", - "\t\tself.val = 3*i" - ] - }, - { - "cell_type": "code", - "execution_count": 3, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "[<__main__.C1 at 0x7fa84827afd0>,\n", - " <__main__.C2 at 0x7fa84827ae80>,\n", - " <__main__.C3 at 0x7fa8482020d0>]" - ] - }, - "execution_count": 3, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "classes = [C1, C2, C3]\n", - "initialized = []\n", - "for c in classes:\n", - "\tinitialized.append(c(10))\n", - "initialized" - ] - }, - { - "cell_type": "code", - "execution_count": 3, - "metadata": {}, - "outputs": [], - "source": [ - "import module\n", - "module_references = {\"match\": module.Match}\n", - "module_initialized = []\n", - "for m in [\"match\"]:\n", - "\tmodule_initialized.append(module_references[m](\"\", \"\", \"\", 0, []))" - ] - }, - { - "cell_type": "code", - "execution_count": 4, - "metadata": {}, - "outputs": [ - { - "data": { - "text/plain": [ - "[]" - ] - }, - "execution_count": 4, - "metadata": {}, - "output_type": "execute_result" - } - ], - "source": [ - "module_initialized" - ] - }, - { - "cell_type": "code", - "execution_count": null, - "metadata": {}, - "outputs": [], - "source": [] - } - ], - "metadata": { - "interpreter": { - "hash": "e7370f93d1d0cde622a1f8e1c04877d8463912d04d973331ad4851f04de6915a" - }, - "kernelspec": { - "display_name": "Python 3.8.5 64-bit", - "name": "python3" - }, - "language_info": { - "codemirror_mode": { - "name": "ipython", - "version": 3 - }, - "file_extension": ".py", - "mimetype": "text/x-python", - "name": "python", - "nbconvert_exporter": "python", - "pygments_lexer": "ipython3", - "version": "3.8.5" - }, - "orig_nbformat": 4 - }, - "nbformat": 4, - "nbformat_minor": 2 -} diff --git a/src/requirements.txt b/src/requirements.txt index 88cc58b..52854df 100644 --- a/src/requirements.txt +++ b/src/requirements.txt @@ -1,6 +1,5 @@ requests pymongo -pandas tra-analysis dnspython @@ -11,7 +10,6 @@ scipy scikit-learn six pyparsing -pandas kivy==2.0.0rc2