From 96b0f3bdb8afcd46eae84f238de237529e545d88 Mon Sep 17 00:00:00 2001 From: PAN Lei Date: Thu, 12 May 2022 18:58:40 +0200 Subject: [PATCH] need to test on mac os --- .gitignore | 1 + appointment.spec | 19 ++++++++++++------- requirements.txt | 4 +++- start.bat | 1 + start.sh | 2 -- workers/commandor_page.py | 2 -- 6 files changed, 17 insertions(+), 12 deletions(-) create mode 100644 start.bat delete mode 100644 start.sh diff --git a/.gitignore b/.gitignore index 458b7d8..b36ba63 100644 --- a/.gitignore +++ b/.gitignore @@ -11,3 +11,4 @@ utils/*.log out lib appointment_*.log +./build diff --git a/appointment.spec b/appointment.spec index d268acf..4673f21 100644 --- a/appointment.spec +++ b/appointment.spec @@ -24,24 +24,29 @@ pyz = PYZ(a.pure, a.zipped_data, cipher=block_cipher) exe = EXE( pyz, a.scripts, - a.binaries, - a.zipfiles, - a.datas, [], + exclude_binaries=True, name='appointment', - debug=True, + debug=False, bootloader_ignore_signals=False, strip=False, upx=True, - upx_exclude=[], - runtime_tmpdir=None, console=False, disable_windowed_traceback=False, argv_emulation=False, target_arch=None, codesign_identity=None, entitlements_file=None, - icon='C:\\Users\\landd\\IdeaProjects\\appointment_tool\\hermes-logo.ico' +) +coll = COLLECT( + exe, + a.binaries, + a.zipfiles, + a.datas, + strip=False, + upx=True, + upx_exclude=[], + name='appointment', ) import shutil shutil.copyfile('C:\\Users\\landd\\IdeaProjects\\appointment_tool\\appointment.json', '{0}/appointment.json'.format(DISTPATH)) diff --git a/requirements.txt b/requirements.txt index 88ee6bc..f1f1948 100644 --- a/requirements.txt +++ b/requirements.txt @@ -6,4 +6,6 @@ dataclasses~=0.6 oci~=2.54.1 XlsxWriter~=3.0.3 boto3~=1.21.13 -openpyxl==3.0.9 \ No newline at end of file +openpyxl==3.0.9 +google-cloud-firestore==2.4.0 +PySimpleGUI==4.60.0 \ No newline at end of file diff --git a/start.bat b/start.bat new file mode 100644 index 0000000..7feafe2 --- /dev/null +++ b/start.bat @@ -0,0 +1 @@ +.\venv\Scripts\python.exe appointment.py \ No newline at end of file diff --git a/start.sh b/start.sh deleted file mode 100644 index b1646f8..0000000 --- a/start.sh +++ /dev/null @@ -1,2 +0,0 @@ -#!/bin/zsh -/Users/panlei/Documents/worksapce/appointment_modem_pool/venv/bin/python3 /Users/panlei/Documents/worksapce/appointment_modem_pool/main.py \ No newline at end of file diff --git a/workers/commandor_page.py b/workers/commandor_page.py index 518b314..19ab0ee 100644 --- a/workers/commandor_page.py +++ b/workers/commandor_page.py @@ -151,7 +151,6 @@ class CommandorPage: message = self.page.content() if CONFIRMED_MESSAGE in message: # publish the successful message - self.logger.info("url is " + self.page.url) self.publish_message_to_queue(self.contact, PublishType.SUCCESS, self.page.url) self.getErrors() @@ -159,7 +158,6 @@ class CommandorPage: print("on_document_loaded called") def _setPhoneCountryAndStore(self): - # document.getElementById("prefer").value = \"faubourg\"; try: if self.store_type == 0: self.page.evaluate("""()=>{