第 3 步:对比。只有 [之前是 SOLD OUT] 且 [现在是 AVAILABLE] 时,才会发送邮件。
第 4 步:更新 JSON 文件和网页。
这套流程现在已经刻在你的服务器里了。下一步:建议你在浏览器打开你的 IP 地址,亲自测试一下订阅功能是否能正常将邮箱写入 /root/subscribers.txt。
注意❗
Traceback (most recent call last):
File "/root/spartan_monitor.py", line 234, in <module>
check_stock()
File "/root/spartan_monitor.py", line 96, in check_stock
page = ChromiumPage(co)
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/DrissionPage/_pages/chromium_page.py", line 23, in __new__
browser = Chromium(addr_or_opts=addr_or_opts)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/DrissionPage/_base/chromium.py", line 41, in __new__
is_headless, browser_id, is_exists, ws_only = run_browser(opt)
^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/DrissionPage/_base/chromium.py", line 501, in run_browser
is_exists = connect_browser(chromium_options)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/usr/local/lib/python3.11/dist-packages/DrissionPage/_functions/browser.py", line 38, in connect_browser
raise BrowserConnectError(_S._lang.BROWSER_CONNECT_ERR1_, port, port, ADDRESS=address)
DrissionPage.errors.BrowserConnectError:
Browser connect failed, check whether the port 9222 is a browser and "--remote-debugging-port=9222" startup item is added.
Address: 127.0.0.1:9222
Version: 4.1.1.2
# You can find documentation for all the supported env variables at https://docs.immich.app/install/environment-variables
# The location where your uploaded files are stored UPLOAD_LOCATION=./library
# The location where your database files are stored. Network shares are not supported for the database DB_DATA_LOCATION=./postgres
# To set a timezone, uncomment the next line and change Etc/UTC to a TZ identifier from this list: https://en.wikipedia.org/wiki/List_of_tz_database_time_zones#List # TZ=Etc/UTC
# The Immich version to use. You can pin this to a specific version like "v2.1.0" IMMICH_VERSION=v2
# Connection secret for postgres. You should change it to a random password # Please use only the characters `A-Za-z0-9`, without special characters or spaces DB_PASSWORD=postgres
# The values below this line do not need to be changed ################################################################################### DB_USERNAME=postgres DB_DATABASE_NAME=immich