mt5cli 0.4.1__tar.gz → 0.4.2__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.
Files changed (37) hide show
  1. {mt5cli-0.4.1 → mt5cli-0.4.2}/PKG-INFO +1 -1
  2. mt5cli-0.4.1/docs/api/sqlite_history.md → mt5cli-0.4.2/docs/api/history.md +2 -2
  3. {mt5cli-0.4.1 → mt5cli-0.4.2}/docs/api/index.md +4 -0
  4. {mt5cli-0.4.1 → mt5cli-0.4.2}/docs/index.md +1 -1
  5. {mt5cli-0.4.1 → mt5cli-0.4.2}/mkdocs.yml +1 -1
  6. mt5cli-0.4.1/mt5cli/sqlite_history.py → mt5cli-0.4.2/mt5cli/history.py +1 -1
  7. {mt5cli-0.4.1 → mt5cli-0.4.2}/mt5cli/sdk.py +1 -1
  8. {mt5cli-0.4.1 → mt5cli-0.4.2}/pyproject.toml +2 -2
  9. mt5cli-0.4.1/tests/test_sqlite_history.py → mt5cli-0.4.2/tests/test_history.py +4 -4
  10. {mt5cli-0.4.1 → mt5cli-0.4.2}/tests/test_sdk.py +1 -1
  11. {mt5cli-0.4.1 → mt5cli-0.4.2}/uv.lock +1 -1
  12. {mt5cli-0.4.1 → mt5cli-0.4.2}/.agents/skills/local-qa/SKILL.md +0 -0
  13. {mt5cli-0.4.1 → mt5cli-0.4.2}/.agents/skills/local-qa/scripts/qa.sh +0 -0
  14. {mt5cli-0.4.1 → mt5cli-0.4.2}/.agents/skills/mt5cli/SKILL.md +0 -0
  15. {mt5cli-0.4.1 → mt5cli-0.4.2}/.claude/agents/codex.md +0 -0
  16. {mt5cli-0.4.1 → mt5cli-0.4.2}/.claude/settings.json +0 -0
  17. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/FUNDING.yml +0 -0
  18. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/dependabot.yml +0 -0
  19. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/renovate.json +0 -0
  20. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/workflows/ci.yml +0 -0
  21. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/workflows/claude.yml +0 -0
  22. {mt5cli-0.4.1 → mt5cli-0.4.2}/.github/workflows/release.yml +0 -0
  23. {mt5cli-0.4.1 → mt5cli-0.4.2}/.gitignore +0 -0
  24. {mt5cli-0.4.1 → mt5cli-0.4.2}/AGENTS.md +0 -0
  25. {mt5cli-0.4.1 → mt5cli-0.4.2}/CLAUDE.md +0 -0
  26. {mt5cli-0.4.1 → mt5cli-0.4.2}/LICENSE +0 -0
  27. {mt5cli-0.4.1 → mt5cli-0.4.2}/README.md +0 -0
  28. {mt5cli-0.4.1 → mt5cli-0.4.2}/docs/api/cli.md +0 -0
  29. {mt5cli-0.4.1 → mt5cli-0.4.2}/docs/api/sdk.md +0 -0
  30. {mt5cli-0.4.1 → mt5cli-0.4.2}/docs/api/utils.md +0 -0
  31. {mt5cli-0.4.1 → mt5cli-0.4.2}/mt5cli/__init__.py +0 -0
  32. {mt5cli-0.4.1 → mt5cli-0.4.2}/mt5cli/__main__.py +0 -0
  33. {mt5cli-0.4.1 → mt5cli-0.4.2}/mt5cli/cli.py +0 -0
  34. {mt5cli-0.4.1 → mt5cli-0.4.2}/mt5cli/utils.py +0 -0
  35. {mt5cli-0.4.1 → mt5cli-0.4.2}/tests/__init__.py +0 -0
  36. {mt5cli-0.4.1 → mt5cli-0.4.2}/tests/test_cli.py +0 -0
  37. {mt5cli-0.4.1 → mt5cli-0.4.2}/tests/test_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: mt5cli
3
- Version: 0.4.1
3
+ Version: 0.4.2
4
4
  Summary: Command-line tool for MetaTrader 5
5
5
  Project-URL: Repository, https://github.com/dceoy/mt5cli.git
6
6
  Author-email: dceoy <dceoy@users.noreply.github.com>
@@ -1,6 +1,6 @@
1
- # SQLite History Module
1
+ # History Collection (SQLite)
2
2
 
3
- ::: mt5cli.sqlite_history
3
+ ::: mt5cli.history
4
4
 
5
5
  ## `collect-history` schema
6
6
 
@@ -18,6 +18,10 @@ Utility module providing constants, enums, Click parameter types, and helper fun
18
18
 
19
19
  Programmatic SDK for read-only MetaTrader 5 data collection. Returns pandas DataFrames and provides `collect_history` for SQLite bulk collection.
20
20
 
21
+ ### [History Collection (SQLite)](history.md)
22
+
23
+ SQLite storage helpers for the `collect-history` command schema, incremental updates, deduplication, indexes, and optional views.
24
+
21
25
  ## Architecture Overview
22
26
 
23
27
  The package follows a simple architecture built on top of pdmt5:
@@ -152,7 +152,7 @@ mt5cli -o history.db collect-history \
152
152
 
153
153
  History orders and deals are fetched per symbol and concatenated, so the symbol filter is applied consistently across all datasets. The `cash_events` view is derived from symbol-filtered `history_deals`, so account-level cash events with empty or non-matching symbols may be excluded. The `positions_reconstructed` view excludes positions with no closing deal, uses volume-weighted open/close prices, and reports reversal deals (`DEAL_ENTRY_INOUT`) via `volume_reversal` / `reversal_count`.
154
154
 
155
- See the [SQLite History schema diagram](api/sqlite_history.md#entity-relationship-diagram) for a sample ER layout of the resulting database.
155
+ See the [History schema diagram](api/history.md#entity-relationship-diagram) for a sample ER layout of the resulting database.
156
156
 
157
157
  ## Global Options
158
158
 
@@ -58,7 +58,7 @@ nav:
58
58
  - Overview: api/index.md
59
59
  - CLI: api/cli.md
60
60
  - SDK: api/sdk.md
61
- - SQLite History: api/sqlite_history.md
61
+ - History Collection (SQLite): api/history.md
62
62
  - Utils: api/utils.md
63
63
 
64
64
  markdown_extensions:
@@ -1,4 +1,4 @@
1
- """SQLite helpers for incremental MT5 history collection."""
1
+ """SQLite storage helpers for the ``collect-history`` incremental data pipeline."""
2
2
 
3
3
  from __future__ import annotations
4
4
 
@@ -12,7 +12,7 @@ from typing import TYPE_CHECKING, Self, TypeVar
12
12
 
13
13
  from pdmt5 import Mt5Config, Mt5DataClient
14
14
 
15
- from .sqlite_history import (
15
+ from .history import (
16
16
  create_cash_events_view,
17
17
  create_history_indexes,
18
18
  create_positions_reconstructed_view,
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "mt5cli"
3
- version = "0.4.1"
3
+ version = "0.4.2"
4
4
  description = "Command-line tool for MetaTrader 5"
5
5
  authors = [{name = "dceoy", email = "dceoy@users.noreply.github.com"}]
6
6
  maintainers = [{name = "dceoy", email = "dceoy@users.noreply.github.com"}]
@@ -124,7 +124,7 @@ ignore = [
124
124
  ]
125
125
 
126
126
  [tool.ruff.lint.per-file-ignores]
127
- "mt5cli/sqlite_history.py" = ["TC003"]
127
+ "mt5cli/history.py" = ["TC003"]
128
128
  "tests/**/*.py" = [
129
129
  "DOC201", # Missing return documentation
130
130
  "DOC501", # Raised exception missing from docstring
@@ -1,4 +1,4 @@
1
- """Tests for mt5cli.sqlite_history module."""
1
+ """Tests for mt5cli.history module."""
2
2
 
3
3
  from __future__ import annotations
4
4
 
@@ -14,7 +14,7 @@ import pytest
14
14
  if TYPE_CHECKING:
15
15
  from pathlib import Path
16
16
 
17
- from mt5cli.sqlite_history import (
17
+ from mt5cli.history import (
18
18
  DEFAULT_HISTORY_TIMEFRAMES,
19
19
  append_dataframe,
20
20
  augment_written_columns_from_sqlite,
@@ -1024,7 +1024,7 @@ class TestIncrementalIntegration:
1024
1024
  sqlite3.connect(tmp_path / "no-keys.db") as conn,
1025
1025
  caplog.at_level(
1026
1026
  logging.WARNING,
1027
- logger="mt5cli.sqlite_history",
1027
+ logger="mt5cli.history",
1028
1028
  ),
1029
1029
  ):
1030
1030
  deduplicate_history_tables(conn, {Dataset.ticks: {"time"}}, {Dataset.ticks})
@@ -1059,7 +1059,7 @@ class TestIncrementalIntegration:
1059
1059
  client = MagicMock()
1060
1060
  client.copy_rates_range_as_df.return_value = pd.DataFrame()
1061
1061
  with (
1062
- caplog.at_level(logging.WARNING, logger="mt5cli.sqlite_history"),
1062
+ caplog.at_level(logging.WARNING, logger="mt5cli.history"),
1063
1063
  sqlite3.connect(tmp_path / "views-warning.db") as conn,
1064
1064
  ):
1065
1065
  write_incremental_datasets(
@@ -16,6 +16,7 @@ if TYPE_CHECKING:
16
16
  from pathlib import Path
17
17
 
18
18
  from mt5cli import sdk
19
+ from mt5cli.history import DEFAULT_HISTORY_TIMEFRAMES
19
20
  from mt5cli.sdk import (
20
21
  Mt5CliClient,
21
22
  account_info,
@@ -40,7 +41,6 @@ from mt5cli.sdk import (
40
41
  update_history_with_config,
41
42
  version,
42
43
  )
43
- from mt5cli.sqlite_history import DEFAULT_HISTORY_TIMEFRAMES
44
44
  from mt5cli.utils import Dataset
45
45
 
46
46
  _DEALS_FIXTURE: dict[str, list[object]] = {
@@ -487,7 +487,7 @@ wheels = [
487
487
 
488
488
  [[package]]
489
489
  name = "mt5cli"
490
- version = "0.4.1"
490
+ version = "0.4.2"
491
491
  source = { editable = "." }
492
492
  dependencies = [
493
493
  { name = "click" },
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
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes