installed deps, got the initial page returning

This commit is contained in:
j37hr0 2026-05-09 17:24:37 +12:00
parent df2b38dc99
commit 3f6148ef81
4 changed files with 19 additions and 2 deletions

0
.gitignore vendored Normal file → Executable file
View file

5
README.md Normal file → Executable file
View file

@ -1,2 +1,7 @@
# AkahuSync
make sure to install playwright, then run:
```
install playwright --with-deps
```
to get the correct drivers and dependencies for the host system

0
emoneyscraper/main.py Normal file → Executable file
View file

16
emoneyscraper/scraper.py Normal file → Executable file
View file

@ -1,11 +1,23 @@
from playwright.sync_api import sync_playwright, Playwright
import os
from dotenv import load_dotenv
load_dotenv()
def run(playwright: Playwright):
chromium = playwright.chromium # or "firefox" or "webkit".
browser = chromium.launch()
page = browser.new_page()
page.goto("http://example.com")
# other actions...
response = page.goto(os.getenv("URL"))
# print(response.status)
# print(response.url)
# print(response.ok)
#page.fill("input#ctl00_ContentPlaceHolder1_txtLoginID", os.getenv("USERNAME"))
#page.fill("input#ctl00_ContentPlaceHolder1_txtPassword", os.getenv("PASSWORD"))
#page.click("input#ctl00_ContentPlaceHolder1_btnLogin")
#
print(page.content())
browser.close()
with sync_playwright() as playwright: