zhou12189108 commited on
Commit
815e07c
1 Parent(s): 35b5d0f

Update hcaptcha_solver.py

Browse files
Files changed (1) hide show
  1. hcaptcha_solver.py +2 -2
hcaptcha_solver.py CHANGED
@@ -7,7 +7,7 @@ import hcaptcha_challenger as solver
7
  from hcaptcha_challenger.agents import AgentT, Malenia
8
 
9
  # Init local-side of the ModelHub
10
- solver.install(upgrade=True, clip=False)
11
 
12
  # Save dataset to current working directory
13
  tmp_dir = Path(__file__).parent.joinpath("tmp_dir")
@@ -17,7 +17,7 @@ tmp_dir = Path(__file__).parent.joinpath("tmp_dir")
17
  async def hit_challenge(context: ASyncContext, host, sitekey, user_data_dir, times: int = 8):
18
  await context.route('**/*', lambda route, request: route_continuation(route, request, host, sitekey))
19
  page = context.pages[0]
20
- agent = AgentT.from_page(page=page, tmp_dir=tmp_dir, self_supervised=False)
21
  await page.goto(f"https://{host}")
22
 
23
  await agent.handle_checkbox()
 
7
  from hcaptcha_challenger.agents import AgentT, Malenia
8
 
9
  # Init local-side of the ModelHub
10
+ solver.install(upgrade=True, clip=True)
11
 
12
  # Save dataset to current working directory
13
  tmp_dir = Path(__file__).parent.joinpath("tmp_dir")
 
17
  async def hit_challenge(context: ASyncContext, host, sitekey, user_data_dir, times: int = 8):
18
  await context.route('**/*', lambda route, request: route_continuation(route, request, host, sitekey))
19
  page = context.pages[0]
20
+ agent = AgentT.from_page(page=page, tmp_dir=tmp_dir, self_supervised=True)
21
  await page.goto(f"https://{host}")
22
 
23
  await agent.handle_checkbox()