Skip to content

ci: add pull request validation workflow#16

Open
mason0510 wants to merge 1 commit into
LainsNL:mainfrom
mason0510:ci/automatic-pr-review
Open

ci: add pull request validation workflow#16
mason0510 wants to merge 1 commit into
LainsNL:mainfrom
mason0510:ci/automatic-pr-review

Conversation

@mason0510
Copy link
Copy Markdown

Summary

  • add a GitHub Actions workflow that runs syntax validation for key Python scripts on pull requests
  • add a minimal config schema smoke check so PRs do not silently break required runtime keys
  • document the repo-level and GitHub-settings split for automatic PR review, including branch protection / rulesets and Copilot review boundaries

Test Plan

  • ruby -e 'require "yaml"; YAML.load_file(".github/workflows/pr-check.yml"); puts "workflow yaml ok"'
  • python3 -m py_compile OutlookRegister.py OutlookRegister_patchright.py get_token.py
  • python3 - <<'PY' import json from pathlib import Path required_keys = { 'browser_path','proxy','Bot_protection_wait','max_captcha_retries','concurrent_flows','max_tasks','enable_oauth2','client_id','redirect_url','Scopes' } config = json.loads(Path('config.json').read_text(encoding='utf-8')) missing = sorted(required_keys - set(config)) assert not missing, f'config.json 缺少关键字段: {missing}' print('config.json schema smoke ok') PY

@mason0510
Copy link
Copy Markdown
Author

Code review 结论:

  • 范围清晰,只涉及 workflow / ignore / 文档
  • 本地已验证 YAML 解析、py_compile、config.json 关键字段烟雾检查
  • 当前未发现阻塞合并的问题
  • 备注:真正拦截 merge 仍需仓库设置里开启 required status checks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants