diff --git a/README.md b/README.md index 9b275fdd..22b2584a 100644 --- a/README.md +++ b/README.md @@ -7,9 +7,12 @@ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](LICENSE) [![Python](https://img.shields.io/badge/Python-3.10%2B-blue.svg)](https://www.python.org/) +- GitHub Repo: [https://github.com/dou-jiang/codex-console](https://github.com/dou-jiang/codex-console) + ## QQ群 -- 交流群: https://qm.qq.com/q/ZTCKxawxeo +- 交流群: [291638849(点击加群)](https://qm.qq.com/q/4TETC3mWco) +- Telegram 频道: [codex_console](https://t.me/codex_console) ## 致谢 @@ -17,9 +20,9 @@ 本仓库是在原项目思路和结构之上进行兼容性修复、流程调整和体验优化,适合作为一个“当前可用的修复维护版”继续使用。 -## 这个分支修了什么 +## 版本更新 -为适配当前注册链路,这个分支重点补了下面几个问题: +### v1.0 1. 新增 Sentinel POW 求解逻辑 OpenAI 现在会强制校验 Sentinel POW,原先直接传空值已经不行了,这里补上了实际求解流程。 @@ -38,6 +41,22 @@ 5. 优化终端和 Web UI 提示文案 保留可读性的前提下,把一些提示改得更友好一点,出错时至少不至于像在挨骂。 +### v1.1 + +1. 修复注册流程中的问题,解决 Outlook 和临时邮箱收不到邮件导致注册卡住、无法完成注册的问题。 + +2. 修复无法检查订阅状态的问题,提升订阅识别和状态检查的可用性。 + +3. 新增绑卡半自动模式,支持自动随机地址;3DS 无法跳过,需按实际流程完成验证。 + +4. 新增已订阅账号管理功能,支持查看和管理账号额度。 + +5. 新增后台日志功能,并补充数据导出与导入能力,方便排查问题和迁移数据。 + +6. 优化部分 UI 细节与交互体验,减少页面操作时的割裂感。 + +7. 补充细节稳定性处理,尽量减少注册、订阅检测和账号管理过程中出现卡住或误判的情况。 + ## 核心能力 - Web UI 管理注册任务和账号数据 @@ -218,3 +237,5 @@ dist/codex-console-windows-X64.exe 本项目仅供学习、研究和技术交流使用,请遵守相关平台和服务条款,不要用于违规、滥用或非法用途。 因使用本项目产生的任何风险和后果,由使用者自行承担。 + + diff --git a/pyproject.toml b/pyproject.toml index 06f9cec3..9f02d207 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "codex-console" -version = "1.0.4" +version = "1.1.0" description = "OpenAI account management console" requires-python = ">=3.10" dependencies = [ diff --git a/src/config/constants.py b/src/config/constants.py index 9e787a2e..0949de3e 100644 --- a/src/config/constants.py +++ b/src/config/constants.py @@ -45,7 +45,7 @@ class EmailServiceType(str, Enum): # ============================================================================ APP_NAME = "OpenAI/Codex CLI 自动注册系统" -APP_VERSION = "2.0.0" +APP_VERSION = "1.1.0" APP_DESCRIPTION = "自动注册 OpenAI/Codex CLI 账号的系统" # ============================================================================ diff --git a/src/config/project_notice.py b/src/config/project_notice.py new file mode 100644 index 00000000..5939ac17 --- /dev/null +++ b/src/config/project_notice.py @@ -0,0 +1,31 @@ +"""Shared project notice content for terminal and Web UI.""" + +PROJECT_NOTICE = { + "title": "项目声明", + "free_notice": "本项目永久免费开源,如果你是付费购买的,请立即找卖家退款。", + "disclaimer": ( + "免责声明:本工具仅供学习和研究使用,使用本工具产生的一切后果由使用者自行承担。" + "请遵守相关服务的使用条款,不要用于任何违法或不当用途。" + "如有侵权,请及时联系,会及时删除。" + ), + "github_repo_name": "dou-jiang/codex-console", + "github_repo_url": "https://github.com/dou-jiang/codex-console", + "qq_group_id": "291638849", + "qq_group_url": "https://qm.qq.com/q/4TETC3mWco", + "telegram_name": "codex_console", + "telegram_url": "https://t.me/codex_console", +} + + +def build_terminal_notice_lines() -> list[str]: + """Build terminal-friendly notice lines.""" + return [ + "=" * 72, + "项目声明", + PROJECT_NOTICE["free_notice"], + f"GitHub 仓库 {PROJECT_NOTICE['github_repo_name']}:{PROJECT_NOTICE['github_repo_url']}", + f"QQ交流群 {PROJECT_NOTICE['qq_group_id']}:{PROJECT_NOTICE['qq_group_url']}", + f"Telegram频道 {PROJECT_NOTICE['telegram_name']}:{PROJECT_NOTICE['telegram_url']}", + PROJECT_NOTICE["disclaimer"], + "=" * 72, + ] diff --git a/src/config/settings.py b/src/config/settings.py index ac4bb9ad..a929c0d8 100644 --- a/src/config/settings.py +++ b/src/config/settings.py @@ -48,7 +48,7 @@ class SettingDefinition: ), "app_version": SettingDefinition( db_key="app.version", - default_value="2.0.0", + default_value="1.1.0", category=SettingCategory.GENERAL, description="应用版本" ), @@ -592,7 +592,7 @@ class Settings(BaseModel): # 应用信息 app_name: str = "OpenAI/Codex CLI 自动注册系统" - app_version: str = "2.0.0" + app_version: str = "1.1.0" debug: bool = False # 数据库配置 diff --git a/src/services/temp_mail.py b/src/services/temp_mail.py index cbbaea85..d2605292 100644 --- a/src/services/temp_mail.py +++ b/src/services/temp_mail.py @@ -178,6 +178,7 @@ def _is_openai_otp_mail(self, sender: str, subject: str, body: str, raw: str) -> return False otp_keywords = ( + "verification", "verification code", "verify", "one-time code", diff --git a/src/services/tempmail.py b/src/services/tempmail.py index a2320593..e5d0f2b9 100644 --- a/src/services/tempmail.py +++ b/src/services/tempmail.py @@ -397,4 +397,4 @@ def wait_for_verification_code_with_callback( "email": email, "message": "等待验证码超时" }) - return None + return None \ No newline at end of file diff --git a/src/web/app.py b/src/web/app.py index 9bd6a4de..b679341d 100644 --- a/src/web/app.py +++ b/src/web/app.py @@ -18,6 +18,7 @@ from fastapi.responses import HTMLResponse, RedirectResponse from ..config.settings import get_settings +from ..config.project_notice import PROJECT_NOTICE from .routes import api_router from .routes.websocket import router as ws_router from .task_manager import task_manager @@ -91,6 +92,7 @@ def create_app() -> FastAPI: # 模板引擎 templates = Jinja2Templates(directory=str(TEMPLATES_DIR)) templates.env.globals["static_version"] = _build_static_asset_version(STATIC_DIR) + templates.env.globals["project_notice"] = PROJECT_NOTICE def _render_template( request: Request, diff --git a/static/css/style.css b/static/css/style.css index a82b48ad..f1cff73d 100644 --- a/static/css/style.css +++ b/static/css/style.css @@ -121,6 +121,67 @@ body { -moz-osx-font-smoothing: grayscale; } +.site-notice-wrapper { + padding: var(--spacing-md) 0 0; +} + +.site-notice { + display: flex; + flex-direction: column; + gap: var(--spacing-sm); + padding: 14px 18px; + border: 1px solid rgba(245, 158, 11, 0.28); + border-radius: var(--radius-lg); + background: linear-gradient(135deg, rgba(245, 158, 11, 0.14), rgba(16, 163, 127, 0.08)); + box-shadow: var(--shadow-sm); +} + +.site-notice-heading { + display: flex; + flex-wrap: wrap; + gap: 10px; + align-items: center; + color: var(--text-primary); + font-size: 0.95rem; +} + +.site-notice-heading strong { + color: #b45309; +} + +.site-notice-text { + color: var(--text-secondary); + font-size: 0.875rem; + margin: 0; +} + +.site-notice-links { + display: flex; + flex-wrap: wrap; + gap: 10px; +} + +.site-notice-links a { + display: inline-flex; + align-items: center; + min-height: 36px; + padding: 0 14px; + border-radius: var(--radius-full); + background: var(--surface); + border: 1px solid var(--border); + color: var(--primary-color); + text-decoration: none; + font-size: 0.875rem; + font-weight: 600; + transition: all var(--transition); +} + +.site-notice-links a:hover { + color: var(--primary-hover); + border-color: var(--primary-color); + transform: translateY(-1px); +} + /* ============================================ 布局 ============================================ */ @@ -1250,6 +1311,19 @@ body { } @media (max-width: 768px) { + .site-notice { + padding: 12px 14px; + } + + .site-notice-heading { + font-size: 0.9rem; + } + + .site-notice-links a { + width: 100%; + justify-content: center; + } + .container { padding: 0 var(--spacing-md); } diff --git a/templates/accounts.html b/templates/accounts.html index 0f7e1cf9..fa28f782 100644 --- a/templates/accounts.html +++ b/templates/accounts.html @@ -105,6 +105,7 @@ + {% include "partials/site_notice.html" %}