foxfetch 0.1.5__tar.gz → 0.1.7__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {foxfetch-0.1.5 → foxfetch-0.1.7}/PKG-INFO +27 -50
- {foxfetch-0.1.5 → foxfetch-0.1.7}/README.md +26 -49
- {foxfetch-0.1.5 → foxfetch-0.1.7}/README.zh.md +23 -48
- {foxfetch-0.1.5 → foxfetch-0.1.7}/pyproject.toml +1 -1
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/__init__.py +1 -1
- {foxfetch-0.1.5 → foxfetch-0.1.7}/.gitignore +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/INSTALL.md +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/LICENSE +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/dsh/README.md +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/__main__.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/cli.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/config.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/contexts.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/doctor.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/engine.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/probe.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/server.py +0 -0
- {foxfetch-0.1.5 → foxfetch-0.1.7}/src/foxfetch/shapes.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: foxfetch
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.7
|
|
4
4
|
Summary: Fetch pages through a real Firefox engine (ruyijs) for AI agents: pass bot checks, run the page's own JavaScript, then hand the identity to Chromium when a screenshot is needed.
|
|
5
5
|
Project-URL: Homepage, https://github.com/zhuchongba-01/foxfetch
|
|
6
6
|
Project-URL: Repository, https://github.com/zhuchongba-01/foxfetch
|
|
@@ -58,82 +58,59 @@ Description-Content-Type: text/markdown
|
|
|
58
58
|
[](https://www.npmjs.com/package/dsh-foxfetch)
|
|
59
59
|
[](LICENSE)
|
|
60
60
|
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
check, and read what only a browser can see. When a screenshot is needed, it hands the identity
|
|
64
|
-
it earned to Chromium.
|
|
61
|
+
Runs a page in a real Firefox engine to get past bot checks, then hands the identity to Chromium
|
|
62
|
+
when a screenshot is needed.
|
|
65
63
|
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
## Install in 30 seconds
|
|
69
|
-
|
|
70
|
-
**1. Install the service** (once per machine — **every host needs this, DSH included**):
|
|
64
|
+
## Install
|
|
71
65
|
|
|
72
66
|
```bash
|
|
73
67
|
pip install foxfetch
|
|
74
68
|
```
|
|
75
69
|
|
|
76
|
-
**
|
|
77
|
-
|
|
78
|
-
```bash
|
|
79
|
-
python -m foxfetch doctor
|
|
80
|
-
```
|
|
81
|
-
|
|
82
|
-
**3. Install for your agent** — there are only two cases:
|
|
83
|
-
|
|
84
|
-
### If you use DeepSeek Harness (DSH)
|
|
85
|
-
|
|
86
|
-
Install command, run in this order:
|
|
70
|
+
**DSH (DeepSeek Harness) install command:**
|
|
87
71
|
|
|
88
72
|
```powershell
|
|
89
|
-
pip install foxfetch
|
|
90
73
|
cd "$env:USERPROFILE\.dsh\profiles\desktop"
|
|
91
74
|
pnpm add dsh-foxfetch
|
|
92
75
|
```
|
|
93
76
|
|
|
94
|
-
Then add `"dsh-foxfetch"` to `dsh.profile.bundles` in that `package.json` and restart
|
|
95
|
-
|
|
77
|
+
Then add `"dsh-foxfetch"` to `dsh.profile.bundles` in that folder's `package.json` and restart
|
|
78
|
+
DSH.
|
|
96
79
|
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
Install command — the service only, there is nothing to add per client:
|
|
80
|
+
**Everything else install command:**
|
|
100
81
|
|
|
101
82
|
```bash
|
|
102
|
-
|
|
83
|
+
pi mcp add foxfetch -- python -m foxfetch serve # Pi
|
|
84
|
+
claude mcp add foxfetch -- python -m foxfetch serve # Claude Code
|
|
103
85
|
```
|
|
104
86
|
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
| Client | What to do |
|
|
108
|
-
|---|---|
|
|
109
|
-
| **Pi** | `pi mcp add foxfetch -- python -m foxfetch serve` |
|
|
110
|
-
| **Claude Code** | `claude mcp add foxfetch -- python -m foxfetch serve` |
|
|
111
|
-
| **Codex** | add the `[mcp_servers.foxfetch]` table to `~/.codex/config.toml` → [steps](#codex) |
|
|
112
|
-
| **Any other MCP client** | `command: python`, `args: ["-m", "foxfetch", "serve"]` |
|
|
113
|
-
|
|
114
|
-
### Why the two differ
|
|
87
|
+
Codex and other MCP clients need config only, no package — see [below](#detailed-install).
|
|
115
88
|
|
|
116
|
-
|
|
117
|
-
|---|---|---|
|
|
118
|
-
| Mechanism | native plugin, loaded by DSH | MCP config entry, read by the client |
|
|
119
|
-
| Package to install | `pip` **and** npm | `pip` only |
|
|
120
|
-
| Without it | plugin fails: `cannot start the Python service` | client sees no tools |
|
|
89
|
+
## Verify
|
|
121
90
|
|
|
122
|
-
|
|
91
|
+
```bash
|
|
92
|
+
python -m foxfetch doctor # expect "ok": true
|
|
93
|
+
```
|
|
123
94
|
|
|
124
|
-
|
|
95
|
+
Then ask your agent:
|
|
125
96
|
|
|
126
97
|
```
|
|
127
98
|
foxfetch_run(js="navigator.userAgent", url="https://example.com")
|
|
128
99
|
```
|
|
129
100
|
|
|
130
|
-
|
|
131
|
-
|
|
101
|
+
It must answer with `Firefox/160.0`. If it says `Python-urllib` or `HeadlessChrome`, the agent is
|
|
102
|
+
not reaching the engine — nothing else will work until that is fixed.
|
|
132
103
|
|
|
133
|
-
> **One entry per host.** Never add both an MCP entry and the DSH plugin to the same agent:
|
|
134
|
-
>
|
|
104
|
+
> **One entry per host.** Never add both an MCP entry and the DSH plugin to the same agent: you
|
|
105
|
+
> would get the same seven tools twice (`foxfetch_run` and `mcp__foxfetch__run`).
|
|
135
106
|
|
|
136
|
-
|
|
107
|
+
## Why this exists
|
|
108
|
+
|
|
109
|
+
`curl` gets a 403. Headless Chrome gets fingerprinted. foxfetch runs the site's own JavaScript in
|
|
110
|
+
a real Firefox engine (SpiderMonkey + Necko, no window, no renderer), so the TLS handshake and
|
|
111
|
+
the JS environment are those of a real browser — and it keeps that world alive between calls.
|
|
112
|
+
When a screenshot or a click is needed, `handoff` exports the identity it earned so Chromium can
|
|
113
|
+
finish the job.
|
|
137
114
|
|
|
138
115
|
## Detailed install
|
|
139
116
|
|
|
@@ -9,82 +9,59 @@
|
|
|
9
9
|
[](https://www.npmjs.com/package/dsh-foxfetch)
|
|
10
10
|
[](LICENSE)
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
check, and read what only a browser can see. When a screenshot is needed, it hands the identity
|
|
15
|
-
it earned to Chromium.
|
|
12
|
+
Runs a page in a real Firefox engine to get past bot checks, then hands the identity to Chromium
|
|
13
|
+
when a screenshot is needed.
|
|
16
14
|
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
## Install in 30 seconds
|
|
20
|
-
|
|
21
|
-
**1. Install the service** (once per machine — **every host needs this, DSH included**):
|
|
15
|
+
## Install
|
|
22
16
|
|
|
23
17
|
```bash
|
|
24
18
|
pip install foxfetch
|
|
25
19
|
```
|
|
26
20
|
|
|
27
|
-
**
|
|
28
|
-
|
|
29
|
-
```bash
|
|
30
|
-
python -m foxfetch doctor
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
**3. Install for your agent** — there are only two cases:
|
|
34
|
-
|
|
35
|
-
### If you use DeepSeek Harness (DSH)
|
|
36
|
-
|
|
37
|
-
Install command, run in this order:
|
|
21
|
+
**DSH (DeepSeek Harness) install command:**
|
|
38
22
|
|
|
39
23
|
```powershell
|
|
40
|
-
pip install foxfetch
|
|
41
24
|
cd "$env:USERPROFILE\.dsh\profiles\desktop"
|
|
42
25
|
pnpm add dsh-foxfetch
|
|
43
26
|
```
|
|
44
27
|
|
|
45
|
-
Then add `"dsh-foxfetch"` to `dsh.profile.bundles` in that `package.json` and restart
|
|
46
|
-
|
|
28
|
+
Then add `"dsh-foxfetch"` to `dsh.profile.bundles` in that folder's `package.json` and restart
|
|
29
|
+
DSH.
|
|
47
30
|
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
Install command — the service only, there is nothing to add per client:
|
|
31
|
+
**Everything else install command:**
|
|
51
32
|
|
|
52
33
|
```bash
|
|
53
|
-
|
|
34
|
+
pi mcp add foxfetch -- python -m foxfetch serve # Pi
|
|
35
|
+
claude mcp add foxfetch -- python -m foxfetch serve # Claude Code
|
|
54
36
|
```
|
|
55
37
|
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
| Client | What to do |
|
|
59
|
-
|---|---|
|
|
60
|
-
| **Pi** | `pi mcp add foxfetch -- python -m foxfetch serve` |
|
|
61
|
-
| **Claude Code** | `claude mcp add foxfetch -- python -m foxfetch serve` |
|
|
62
|
-
| **Codex** | add the `[mcp_servers.foxfetch]` table to `~/.codex/config.toml` → [steps](#codex) |
|
|
63
|
-
| **Any other MCP client** | `command: python`, `args: ["-m", "foxfetch", "serve"]` |
|
|
64
|
-
|
|
65
|
-
### Why the two differ
|
|
38
|
+
Codex and other MCP clients need config only, no package — see [below](#detailed-install).
|
|
66
39
|
|
|
67
|
-
|
|
68
|
-
|---|---|---|
|
|
69
|
-
| Mechanism | native plugin, loaded by DSH | MCP config entry, read by the client |
|
|
70
|
-
| Package to install | `pip` **and** npm | `pip` only |
|
|
71
|
-
| Without it | plugin fails: `cannot start the Python service` | client sees no tools |
|
|
40
|
+
## Verify
|
|
72
41
|
|
|
73
|
-
|
|
42
|
+
```bash
|
|
43
|
+
python -m foxfetch doctor # expect "ok": true
|
|
44
|
+
```
|
|
74
45
|
|
|
75
|
-
|
|
46
|
+
Then ask your agent:
|
|
76
47
|
|
|
77
48
|
```
|
|
78
49
|
foxfetch_run(js="navigator.userAgent", url="https://example.com")
|
|
79
50
|
```
|
|
80
51
|
|
|
81
|
-
|
|
82
|
-
|
|
52
|
+
It must answer with `Firefox/160.0`. If it says `Python-urllib` or `HeadlessChrome`, the agent is
|
|
53
|
+
not reaching the engine — nothing else will work until that is fixed.
|
|
83
54
|
|
|
84
|
-
> **One entry per host.** Never add both an MCP entry and the DSH plugin to the same agent:
|
|
85
|
-
>
|
|
55
|
+
> **One entry per host.** Never add both an MCP entry and the DSH plugin to the same agent: you
|
|
56
|
+
> would get the same seven tools twice (`foxfetch_run` and `mcp__foxfetch__run`).
|
|
86
57
|
|
|
87
|
-
|
|
58
|
+
## Why this exists
|
|
59
|
+
|
|
60
|
+
`curl` gets a 403. Headless Chrome gets fingerprinted. foxfetch runs the site's own JavaScript in
|
|
61
|
+
a real Firefox engine (SpiderMonkey + Necko, no window, no renderer), so the TLS handshake and
|
|
62
|
+
the JS environment are those of a real browser — and it keeps that world alive between calls.
|
|
63
|
+
When a screenshot or a click is needed, `handoff` exports the identity it earned so Chromium can
|
|
64
|
+
finish the job.
|
|
88
65
|
|
|
89
66
|
## Detailed install
|
|
90
67
|
|
|
@@ -9,81 +9,56 @@
|
|
|
9
9
|
[](https://www.npmjs.com/package/dsh-foxfetch)
|
|
10
10
|
[](LICENSE)
|
|
11
11
|
|
|
12
|
-
|
|
13
|
-
+ Necko,无窗口、不渲染)执行站点自己的 JavaScript,过掉风控,读出只有浏览器才能看到的东西。
|
|
14
|
-
需要截图时,把它挣到的身份交给 Chromium。
|
|
12
|
+
在真 Firefox 引擎里跑页面,用来过风控;需要截图时把身份交给 Chromium。
|
|
15
13
|
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
## 30 秒装好
|
|
19
|
-
|
|
20
|
-
**第 1 步:装服务**(每台机器装一次 —— **所有宿主都要,DSH 也不例外**)
|
|
14
|
+
## 安装
|
|
21
15
|
|
|
22
16
|
```bash
|
|
23
17
|
pip install foxfetch
|
|
24
18
|
```
|
|
25
19
|
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
```bash
|
|
29
|
-
python -m foxfetch doctor
|
|
30
|
-
```
|
|
31
|
-
|
|
32
|
-
**第 3 步:按你的软件装** —— 只有两种情况:
|
|
33
|
-
|
|
34
|
-
### 用 DeepSeek Harness(DSH,全称 DeepSeek Harness)的
|
|
35
|
-
|
|
36
|
-
安装指令,按顺序执行:
|
|
20
|
+
**DSH(DeepSeek Harness)安装指令:**
|
|
37
21
|
|
|
38
22
|
```powershell
|
|
39
|
-
pip install foxfetch
|
|
40
23
|
cd "$env:USERPROFILE\.dsh\profiles\desktop"
|
|
41
24
|
pnpm add dsh-foxfetch
|
|
42
25
|
```
|
|
43
26
|
|
|
44
|
-
|
|
45
|
-
带完整文件内容的步骤:[DSH 详细安装](#deepseek-harness)。
|
|
27
|
+
再把 `"dsh-foxfetch"` 加进该目录 `package.json` 的 `dsh.profile.bundles`,重启 DSH。
|
|
46
28
|
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
安装指令 —— **只装服务,客户端那边不用装任何包**:
|
|
29
|
+
**其余软件安装指令:**
|
|
50
30
|
|
|
51
31
|
```bash
|
|
52
|
-
|
|
32
|
+
pi mcp add foxfetch -- python -m foxfetch serve # Pi
|
|
33
|
+
claude mcp add foxfetch -- python -m foxfetch serve # Claude Code
|
|
53
34
|
```
|
|
54
35
|
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
| 软件 | 要做什么 |
|
|
58
|
-
|---|---|
|
|
59
|
-
| **Pi** | `pi mcp add foxfetch -- python -m foxfetch serve` |
|
|
60
|
-
| **Claude Code** | `claude mcp add foxfetch -- python -m foxfetch serve` |
|
|
61
|
-
| **Codex** | 在 `~/.codex/config.toml` 加 `[mcp_servers.foxfetch]` 表 → [步骤](#codex) |
|
|
62
|
-
| **其它 MCP 客户端** | `command: python`,`args: ["-m", "foxfetch", "serve"]` |
|
|
63
|
-
|
|
64
|
-
### 为什么两边不一样
|
|
36
|
+
Codex 和其它 MCP 客户端只写配置、不装包,见[下文](#详细安装)。
|
|
65
37
|
|
|
66
|
-
|
|
67
|
-
|---|---|---|
|
|
68
|
-
| 靠什么加载 | 原生插件,DSH 自己加载 | MCP 配置,客户端自己读 |
|
|
69
|
-
| 要装什么包 | `pip` **和** npm | **只要** `pip` |
|
|
70
|
-
| 少装的后果 | 插件报 `cannot start the Python service` | 客户端看不到任何工具 |
|
|
38
|
+
## 验证
|
|
71
39
|
|
|
72
|
-
|
|
40
|
+
```bash
|
|
41
|
+
python -m foxfetch doctor # 应输出 "ok": true
|
|
42
|
+
```
|
|
73
43
|
|
|
74
|
-
|
|
44
|
+
然后让你的 agent 调用:
|
|
75
45
|
|
|
76
46
|
```
|
|
77
47
|
foxfetch_run(js="navigator.userAgent", url="https://example.com")
|
|
78
48
|
```
|
|
79
49
|
|
|
80
|
-
答案里必须出现 `Firefox/160.0`。如果出现 `Python-urllib` 或 `HeadlessChrome`,说明 agent
|
|
81
|
-
|
|
50
|
+
答案里必须出现 `Firefox/160.0`。如果出现 `Python-urllib` 或 `HeadlessChrome`,说明 agent 没连上
|
|
51
|
+
引擎 —— 这个问题不解决,后面全是假的。
|
|
82
52
|
|
|
83
|
-
> **一个宿主只装一个入口。** 同一个 agent 里不要既加 MCP 条目又装 DSH
|
|
84
|
-
>
|
|
53
|
+
> **一个宿主只装一个入口。** 同一个 agent 里不要既加 MCP 条目又装 DSH 插件,否则会出现两套
|
|
54
|
+
> 同样的 7 个工具(`foxfetch_run` 和 `mcp__foxfetch__run`)。
|
|
85
55
|
|
|
86
|
-
|
|
56
|
+
## 为什么需要它
|
|
57
|
+
|
|
58
|
+
`curl` 拿回来 403,无头 Chrome 被指纹识别拦掉。foxfetch 在**真 Firefox 引擎**(SpiderMonkey +
|
|
59
|
+
Necko,无窗口、不渲染)里执行站点自己的 JavaScript,所以 TLS 握手和 JS 环境都是真浏览器的,
|
|
60
|
+
而且这个环境在调用之间保持存活。需要截图或点击时,`handoff` 把挣到的身份导出来,交给 Chromium
|
|
61
|
+
完成剩下的活。
|
|
87
62
|
|
|
88
63
|
## 详细安装
|
|
89
64
|
|
|
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "foxfetch"
|
|
7
|
-
version = "0.1.
|
|
7
|
+
version = "0.1.7"
|
|
8
8
|
description = "Fetch pages through a real Firefox engine (ruyijs) for AI agents: pass bot checks, run the page's own JavaScript, then hand the identity to Chromium when a screenshot is needed."
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.10"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|