Commit graph

94 commits

Author SHA1 Message Date
c67748d950 ops: draft self-hosted ownership snapshot publish flow 2026-04-13 16:46:53 +07:00
f24aa888b5 docs: add idx release skill 2026-04-13 14:39:40 +07:00
5f1d9e6d24 fix: resolve clippy manual_flatten warning in snapshot
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-12 14:41:01 +07:00
aad29eaf23 feat: default ownership sync to published snapshot 2026-04-12 14:27:47 +07:00
Rasyidan A F
71f283edc3
Merge pull request #18 from 0xrsydn/codex/ownership-snapshot-publish ownership-snapshot-current
[codex] add ownership snapshot publish flow
2026-04-12 13:47:48 +07:00
afa20d9b2f feat: add ownership snapshot publish flow 2026-04-12 13:35:09 +07:00
04eaa75882 fix: handle missing scrip column in April 2026 KSEI PDF v0.2.2
The April 2026 IDX ownership PDF omits the zero-valued scrip column for
some holders, causing the parser to leave holdings_scripless/scrip as
empty strings. This broke normalize_ksei_row which called parse_id_number
on empty input.

Two-layer fix:
- Parser: pop_numeric_tail handles 2-column (missing scrip) rows by
  defaulting scrip to "0"
- Normalizer: parse_id_number_or_zero backstop treats empty component
  share fields as 0 while still requiring total_shares

Also includes AGENTS.md refresh, formatting cleanup (rustfmt), and
version bump to 0.2.2.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-04-06 19:15:19 +07:00
c94c826307 chore: prepare v0.2.1 release v0.2.1 2026-04-06 17:47:20 +07:00
1f5c4b2798 Add KSEI archive fallback import 2026-03-31 19:29:00 +07:00
8404b27628 Add ownership snapshot sync 2026-03-31 19:28:13 +07:00
1e5be755ea Merge branch 'codex/batch-2' 2026-03-31 07:41:28 +07:00
a52712b063 Complete batch 2 ownership import hardening 2026-03-30 16:40:32 +07:00
b1a8c88024 docs: record post-merge batch 1 reconfirmation 2026-03-30 14:59:56 +07:00
c0bcf9c688 test: add real above1 parser fixture
Add a compact parser fixture excerpted from the real 2026-03-10 IDX above1 lamp1 mutool stext output and assert the first live row still parses as expected.

This keeps the post-merge ownership parser coverage grounded in the supported above1 layout instead of relying only on synthetic line fixtures.
2026-03-30 13:06:39 +07:00
5f75856b16 Merge pull request #17 from 0xrsydn/codex/test-first-batch-live-e2e
Ownership Refactor
2026-03-30 12:59:48 +07:00
7928e83cc5 test: reset smoke cache between warm cases
Clear the smoke cache before each cache-group warm case so the following offline and stale-cache checks always start from a fresh baseline instead of earlier group state.

Document the runner behavior in the smoke guide to make the cache-group sequencing explicit.
2026-03-30 12:35:22 +07:00
9d406ba3ee Add IDX above1 ownership discovery and import 2026-03-30 11:58:53 +07:00
a36648fd89 ownership: add IDX above1 discovery and import
Refactor KSEI PDF parsing for the live above-1 holder-register layout, add IDX announcement discovery plus browser-impersonated PDF fetches, and update the ownership docs to mark Batch 1 complete and scope Batch 2 around above1 hardening and unsupported legacy inputs.
2026-03-30 11:57:14 +07:00
b431a8c251 docs: smoke testing 2026-03-27 16:54:05 +07:00
d23f16e7a3 test: live smoke testing 2026-03-27 16:53:57 +07:00
5d80891d40 chore: type, schema, error define 2026-03-27 16:53:50 +07:00
76656de1f6 feat: cache, schema 2026-03-27 16:53:09 +07:00
06e06975b8 improve: error handling, output table enhancement 2026-03-27 16:45:14 +07:00
0fd6c666a6 test: autoresgressive simple 2026-03-27 16:44:52 +07:00
7ea79d24e6 test: fixture test msn-only 2026-03-27 16:44:45 +07:00
fe5f46f4d2 test: mock body tets 2026-03-26 18:33:31 +07:00
1df47affb3 test: autoregressive 2026-03-26 18:33:17 +07:00
fece94c9fc test: fixture test 2026-03-26 18:33:08 +07:00
7d32e9d69d fix(screen): debug the msn api, remove probelamtic msn api, filtering via client side 2026-03-18 11:09:51 +07:00
69ca349c49 chore: add alias idx for cli testing 2026-03-18 11:08:59 +07:00
3a81d86ff8 chore: idx direnv switch 2026-03-18 11:08:51 +07:00
83d362afcd Fix clippy warnings for CI 2026-03-17 22:02:58 +07:00
65b95aa7b8 Fix config regressions and ownership import errors 2026-03-17 21:23:33 +07:00
Rasyidan A F
db4ff4f9fe
Merge pull request #12 from 0xrsydn/fix/resilient-cache
fix(cache): treat corrupted cache entries as cache misses
2026-03-17 09:03:15 +07:00
3533670d92 fix: narrow cache miss recovery behavior 2026-03-17 09:02:06 +07:00
Rasyidan A F
8b8d261802
Merge pull request #13 from 0xrsydn/fix/config-validation
fix(config): validate known config keys at write time
2026-03-17 09:00:09 +07:00
018b8aeb55 fix: stabilize cache behavior and local xdg paths 2026-03-17 08:53:13 +07:00
d8ab300748 style: format config tests and fix clippy import 2026-03-17 08:52:00 +07:00
e20b41642f style: format cache tests and fix clippy import 2026-03-17 08:52:00 +07:00
Ciphercat
0bcb7adffb fix(config): validate known config keys at write time
Reject invalid values for known config keys in 'idx config set':
- general.provider: only yahoo|msn
- general.history_provider: only auto|yahoo|msn
- general.output: only table|json
- general.color: only true|false
- cache TTL fields: non-negative integers only
- Unknown keys: rejected with clear error listing valid keys
2026-03-12 17:23:45 +00:00
Ciphercat
299d315a16 fix(cache): treat corrupted cache entries as cache misses
Issue #9: Previously, corrupted JSON in cache files would cause commands
to fail with a ParseError. Now:

- IO errors and parse errors are caught in read_entry()
- A warning is printed to stderr with the data_type/symbol
- The corrupted file is deleted
- Ok(None) is returned (treated as cache miss)

This applies to both get() and get_stale() since they share read_entry().

Added tests:
- corrupted_cache_entry_returns_none_and_deletes_file
- corrupted_cache_entry_get_stale_returns_none_and_deletes_file

Both verify the corrupted file is cleaned up after the graceful failure.
2026-03-12 17:15:40 +00:00
Rasyidan A F
df80a8201a
Merge pull request #11 from 0xrsydn/fix/dead-flags-financials-earnings
fix(cli): remove ignored financials and earnings flags
2026-03-13 00:10:16 +07:00
Ciphercat
97502608c8 fix(cli): remove ignored financials and earnings flags 2026-03-12 17:07:24 +00:00
Ciphercat
cd4d8d8323 fix(api): reject empty ticker in resolve_symbol()
- Change resolve_symbol return type from String to Result<String, IdxError>
- Add early validation for empty/whitespace-only ticker input
- Return Err(IdxError::InvalidInput) for empty tickers
- Add InvalidInput variant to IdxError enum
- Update all 15 callers in cli/stocks.rs to handle Result with ? propagation
- Update tests: empty/whitespace tickers now return error

Fixes #7
2026-03-12 16:53:28 +00:00
Ciphercat
bd4f3d49cc 2026-03-12 16:48:29 +00:00
Ciphercat
3d3b4d1dc4 chore: bump version to v0.2.0 v0.2.0 2026-03-07 22:19:27 +00:00
Rasyidan A F
6b760525ed
Merge pull request #5 from 0xrsydn/feat/ownership 2026-03-08 05:01:10 +07:00
Ciphercat
6671e22976 feat(ownership): complete ownership intelligence module
Sprints 0-8: Types, schema, KSEI parser, entity resolution, DB CRUD,
Bing API client, import pipeline, query commands, graph traversal,
changes diff, entity resolution CLI, FTS5 search.

- KSEI PDF parser (mutool stext + quick-xml, 99.2% accuracy)
- 7 query commands: ticker, entity, search, cross-holders, concentration, flow, releases
- Ownership graph with recursive CTE (ASCII tree + Graphviz DOT)
- Release diff/changes between KSEI snapshots
- Entity resolution CLI: unresolved, map, merge
- FTS5 trigram search on entity names
- Feature-gated under 'ownership' (default-on)
- 82 tests passing
2026-03-07 21:10:58 +00:00
Rasyidan A F
d49a8ed60e
Merge pull request #4 from 0xrsydn/feat/hybrid-provider
feat: hybrid provider with Yahoo history fallback
2026-03-07 19:22:10 +07:00
Ciphercat
ed85428c90 feat: hybrid provider with Yahoo history fallback 2026-03-07 08:22:39 +00:00