Skip to content

fix: use reliable complete ETF history source#21

Merged
Pigbibi merged 8 commits into
mainfrom
codex/yahoo-etf-history-20260711
Jul 11, 2026
Merged

fix: use reliable complete ETF history source#21
Pigbibi merged 8 commits into
mainfrom
codex/yahoo-etf-history-20260711

Conversation

@Pigbibi

@Pigbibi Pigbibi commented Jul 10, 2026

Copy link
Copy Markdown
Contributor

Summary

  • add Tencent qfq and Yahoo Chart as explicit CN ETF history sources while retaining AkShare compatibility
  • publish the complete 21-symbol universe from Tencent qfq after AkShare rejected GitHub runner traffic and Yahoo returned incomplete 511880 history
  • fail closed on any missing requested symbol and declare the adjusted-close price basis

Verification

  • PYTHONPATH=src python3 -m pytest -q tests/test_akshare_staging.py tests/test_publish_market_history_workflow.py (8 passed)
  • real Tencent qfq download: 22,951 rows, all 21 symbols, no short symbol history
  • python3 -m ruff check ...
  • actionlint .github/workflows/publish-market-history.yml
  • git diff --check

Co-Authored-By: Codex <noreply@openai.com>
@github-actions

github-actions Bot commented Jul 10, 2026

Copy link
Copy Markdown

🤖 Codex PR Review

⚠️ Review unavailable: Codex review quota or capacity is unavailable. No direct paid API fallback was used; required CI checks remain the merge gate.

Co-Authored-By: Codex <noreply@openai.com>
@Pigbibi

Pigbibi commented Jul 10, 2026

Copy link
Copy Markdown
Contributor Author

Review finding analyzed: the existing AkShare path calls fund_etf_hist_em(..., adjust="qfq"), so the established close contract is already adjusted rather than raw exchange close. I kept Yahoo adjclose, made the price basis explicit in diagnostics/code, and added a regression test that distinguishes raw 12.0 from adjusted 10.0. Changing to raw close would be the incompatible behavior here.

Co-Authored-By: Codex <noreply@openai.com>
@Pigbibi Pigbibi changed the title fix: use reliable ETF history source fix: use reliable complete ETF history source Jul 10, 2026
Pigbibi and others added 2 commits July 11, 2026 07:39
Co-Authored-By: Codex <noreply@openai.com>
Co-Authored-By: Codex <noreply@openai.com>

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 018c28cf2e

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread src/cn_equity_snapshot_pipelines/akshare_market_history.py
Comment thread src/cn_equity_snapshot_pipelines/akshare_market_history.py
Comment thread pyproject.toml
Comment thread src/cn_equity_snapshot_pipelines/akshare_market_history.py
Pigbibi and others added 2 commits July 11, 2026 07:57
Co-Authored-By: Codex <noreply@openai.com>
Co-Authored-By: Codex <noreply@openai.com>
@chatgpt-codex-connector

This comment has been minimized.

Co-Authored-By: Codex <noreply@openai.com>
@chatgpt-codex-connector

This comment has been minimized.

@Pigbibi Pigbibi merged commit 7d9ca23 into main Jul 11, 2026
3 checks passed
@Pigbibi Pigbibi deleted the codex/yahoo-etf-history-20260711 branch July 11, 2026 00:36
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.

1 participant