bbstrader 2.0.2__tar.gz → 2.0.3__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 (96) hide show
  1. bbstrader-2.0.2/.github/workflows/cpp_linux.yml → bbstrader-2.0.3/.github/workflows/build.yml +26 -4
  2. {bbstrader-2.0.2 → bbstrader-2.0.3}/.github/workflows/python.yml +56 -0
  3. {bbstrader-2.0.2 → bbstrader-2.0.3}/.gitignore +0 -1
  4. {bbstrader-2.0.2 → bbstrader-2.0.3}/PKG-INFO +6 -4
  5. {bbstrader-2.0.2 → bbstrader-2.0.3}/README.md +4 -3
  6. bbstrader-2.0.3/VERSION.txt +1 -0
  7. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/data.py +2 -5
  8. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/portfolio.py +5 -1
  9. {bbstrader-2.0.2 → bbstrader-2.0.3}/pyproject.toml +1 -0
  10. bbstrader-2.0.3/tcopier.iss +25 -0
  11. {bbstrader-2.0.2 → bbstrader-2.0.3}/tcopier.spec +0 -3
  12. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/test_portfolio.py +0 -2
  13. bbstrader-2.0.2/.github/workflows/cpp_macos.yml +0 -66
  14. bbstrader-2.0.2/.github/workflows/cpp_win.yml +0 -62
  15. bbstrader-2.0.2/VERSION.txt +0 -1
  16. {bbstrader-2.0.2 → bbstrader-2.0.3}/.clang-format +0 -0
  17. {bbstrader-2.0.2 → bbstrader-2.0.3}/.clang-tidy +0 -0
  18. {bbstrader-2.0.2 → bbstrader-2.0.3}/.readthedocs.yaml +0 -0
  19. {bbstrader-2.0.2 → bbstrader-2.0.3}/CMakeLists.txt +0 -0
  20. {bbstrader-2.0.2 → bbstrader-2.0.3}/LICENSE +0 -0
  21. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/__init__.py +0 -0
  22. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/__main__.py +0 -0
  23. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/api/__init__.py +0 -0
  24. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/api/handlers.py +0 -0
  25. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/api/metatrader_client.pyi +0 -0
  26. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/assets/bbs_.png +0 -0
  27. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/assets/bbstrader.ico +0 -0
  28. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/assets/bbstrader.png +0 -0
  29. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/assets/qs_metrics_1.png +0 -0
  30. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/__init__.py +0 -0
  31. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/backtest.py +0 -0
  32. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/event.py +0 -0
  33. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/execution.py +0 -0
  34. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/performance.py +0 -0
  35. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/btengine/strategy.py +0 -0
  36. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/compat.py +0 -0
  37. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/config.py +0 -0
  38. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/core/__init__.py +0 -0
  39. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/core/data.py +0 -0
  40. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/core/strategy.py +0 -0
  41. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/__init__.py +0 -0
  42. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/_copier.py +0 -0
  43. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/account.py +0 -0
  44. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/broker.py +0 -0
  45. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/copier.py +0 -0
  46. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/rates.py +0 -0
  47. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/risk.py +0 -0
  48. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/trade.py +0 -0
  49. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/metatrader/utils.py +0 -0
  50. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/models/__init__.py +0 -0
  51. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/models/nlp.py +0 -0
  52. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/models/optimization.py +0 -0
  53. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/scripts.py +0 -0
  54. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/trading/__init__.py +0 -0
  55. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/trading/execution.py +0 -0
  56. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/trading/strategy.py +0 -0
  57. {bbstrader-2.0.2 → bbstrader-2.0.3}/bbstrader/trading/utils.py +0 -0
  58. {bbstrader-2.0.2 → bbstrader-2.0.3}/cmake/Helpers.cmake +0 -0
  59. {bbstrader-2.0.2 → bbstrader-2.0.3}/cmake/Versions.cmake +0 -0
  60. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/Doxyfile.in +0 -0
  61. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/Makefile +0 -0
  62. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.api.rst +0 -0
  63. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.btengine.rst +0 -0
  64. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.core.rst +0 -0
  65. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.metatrader.rst +0 -0
  66. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.models.rst +0 -0
  67. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.rst +0 -0
  68. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/bbstrader.trading.rst +0 -0
  69. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/conf.py +0 -0
  70. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/index.rst +0 -0
  71. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/make.bat +0 -0
  72. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/modules.rst +0 -0
  73. {bbstrader-2.0.2 → bbstrader-2.0.3}/docs/requirements.txt +0 -0
  74. {bbstrader-2.0.2 → bbstrader-2.0.3}/examples/strategies.py +0 -0
  75. {bbstrader-2.0.2 → bbstrader-2.0.3}/include/bbstrader/metatrader.hpp +0 -0
  76. {bbstrader-2.0.2 → bbstrader-2.0.3}/include/bbstrader/objects.hpp +0 -0
  77. {bbstrader-2.0.2 → bbstrader-2.0.3}/src/CMakeLists.txt +0 -0
  78. {bbstrader-2.0.2 → bbstrader-2.0.3}/src/bbstrader.cpp +0 -0
  79. {bbstrader-2.0.2 → bbstrader-2.0.3}/src/cmake/BbstraderConfig.cmake.in +0 -0
  80. {bbstrader-2.0.2 → bbstrader-2.0.3}/src/metatrader.cpp +0 -0
  81. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/CMakeLists.txt +0 -0
  82. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/__init__.py +0 -0
  83. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/api/__init__.py +0 -0
  84. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/api/test_metatrader_client.py +0 -0
  85. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/__init__.py +0 -0
  86. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/test_backtest.py +0 -0
  87. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/test_data.py +0 -0
  88. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/test_events.py +0 -0
  89. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/btengine/test_execution.py +0 -0
  90. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/cpp/test_metatrader_client.cpp +0 -0
  91. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/metatrader/__init__.py +0 -0
  92. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/metatrader/test_account.py +0 -0
  93. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/metatrader/test_rates.py +0 -0
  94. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/metatrader/test_risk_management.py +0 -0
  95. {bbstrader-2.0.2 → bbstrader-2.0.3}/tests/metatrader/test_trade.py +0 -0
  96. {bbstrader-2.0.2 → bbstrader-2.0.3}/vcpkg.json +0 -0
@@ -1,4 +1,4 @@
1
- name: Linux
1
+ name: build
2
2
 
3
3
  on:
4
4
  pull_request:
@@ -7,12 +7,13 @@ on:
7
7
 
8
8
  jobs:
9
9
  build-and-test:
10
- runs-on: ubuntu-latest
11
10
  strategy:
12
11
  fail-fast: false
13
12
  matrix:
13
+ os: [ubuntu-latest, windows-latest, macos-latest]
14
14
  build_type: [Release, Debug]
15
15
  cpp_standard: [20, 23]
16
+ runs-on: ${{ matrix.os }}
16
17
  env:
17
18
  VCPKG_ROOT: ${{ github.workspace }}/vcpkg
18
19
  BUILD_DIR: ${{ github.workspace }}/build
@@ -43,10 +44,31 @@ jobs:
43
44
  restore-keys: |
44
45
  ${{ runner.os }}-${{ matrix.build_type }}-cmake-
45
46
 
46
- - name: Install system package
47
+ - name: Install system packages (Linux)
48
+ if: runner.os == 'Linux'
47
49
  shell: bash
48
50
  run: sudo apt install autoconf autoconf-archive automake libtool
49
51
 
52
+ - name: Install system packages (macOS)
53
+ if: runner.os == 'macOS'
54
+ shell: bash
55
+ run: brew install autoconf autoconf-archive automake libtool
56
+
57
+ - name: Set VCPKG Triplet
58
+ shell: bash
59
+ run: |
60
+ if [ "$RUNNER_OS" == "Windows" ]; then
61
+ echo "VCPKG_TARGET_TRIPLET=x64-windows" >> $GITHUB_ENV
62
+ elif [ "$RUNNER_OS" == "Linux" ]; then
63
+ echo "VCPKG_TARGET_TRIPLET=x64-linux" >> $GITHUB_ENV
64
+ else
65
+ if [ "$(uname -m)" == "arm64" ]; then
66
+ echo "VCPKG_TARGET_TRIPLET=arm64-osx" >> $GITHUB_ENV
67
+ else
68
+ echo "VCPKG_TARGET_TRIPLET=x64-osx" >> $GITHUB_ENV
69
+ fi
70
+ fi
71
+
50
72
  - name: Configure CMake
51
73
  shell: bash
52
74
  run: |
@@ -55,7 +77,7 @@ jobs:
55
77
  -DBBSTRADER_CXX_STANDARD=${{ matrix.cpp_standard }} \
56
78
  -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
57
79
  -DCMAKE_TOOLCHAIN_FILE=$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake \
58
- -DVCPKG_TARGET_TRIPLET=x64-linux
80
+ -DVCPKG_TARGET_TRIPLET=$VCPKG_TARGET_TRIPLET
59
81
 
60
82
  - name: Build
61
83
  shell: bash
@@ -68,6 +68,44 @@ jobs:
68
68
  name: cibw-sdist
69
69
  path: dist/*.tar.gz
70
70
 
71
+ build_installer:
72
+ name: Build Windows Installer
73
+ runs-on: windows-latest
74
+ steps:
75
+ - uses: actions/checkout@v4
76
+ - name: Set up Python
77
+ uses: actions/setup-python@v4
78
+ with:
79
+ python-version: '3.12'
80
+
81
+ - name: Install dependencies
82
+ run: |
83
+ pip install pyinstaller
84
+ pip install .[MT5]
85
+
86
+ - name: Build executable
87
+ run: pyinstaller tcopier.spec
88
+
89
+ - name: Replace version in Inno Setup script
90
+ run: |
91
+ $version = "${{ github.ref_name }}".Substring(1)
92
+ (Get-Content tcopier.iss) -replace '__VERSION__', $version | Set-Content tcopier.iss
93
+
94
+ - name: Install Inno Setup (via Chocolatey)
95
+ run: |
96
+ choco install innosetup --no-progress
97
+ echo "C:\Program Files (x86)\Inno Setup 6" >> $env:GITHUB_PATH
98
+
99
+ - name: Compile installer
100
+ run: iscc tcopier.iss
101
+
102
+ - name: Upload installer artifact
103
+ uses: actions/upload-artifact@v4
104
+ with:
105
+ name: installer
106
+ path: "**/TradeCopier.exe"
107
+
108
+
71
109
  publish:
72
110
  needs: [build_wheels, build_sdist]
73
111
  runs-on: ubuntu-latest
@@ -84,3 +122,21 @@ jobs:
84
122
  with:
85
123
  user: __token__
86
124
  password: ${{ secrets.BBSTRADER_PYPI_API_TOKEN }}
125
+
126
+ release:
127
+ name: Create GitHub Release
128
+ needs: [build_installer, publish]
129
+ runs-on: ubuntu-latest
130
+ if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags/v')
131
+
132
+ steps:
133
+ - name: Download artifacts
134
+ uses: actions/download-artifact@v4
135
+ with:
136
+ path: dist
137
+ merge-multiple: true
138
+
139
+ - name: Create GitHub Release
140
+ uses: softprops/action-gh-release@v2
141
+ with:
142
+ files: dist/*
@@ -16,7 +16,6 @@ notes.txt
16
16
  *.h5
17
17
  *ipynb_checkpoints/
18
18
  *.exe
19
- *.iss
20
19
  cmd.ps1
21
20
  .vscode
22
21
  CMakePresets.json
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: bbstrader
3
- Version: 2.0.2
3
+ Version: 2.0.3
4
4
  Summary: Simplified Investment & Trading Toolkit with Python & C++
5
5
  Keywords: Finance,Toolkit,Financial,Analysis,Fundamental,Quantitative,Database,Equities,Currencies,Economics,ETFs,Funds,Indices,Moneymarkets,Commodities,Futures,CFDs,Derivatives,Trading,Investing,Portfolio,Optimization,Performance
6
6
  Author-Email: Bertin Balouki SIMYELI <bertin@bbs-trading.com>
@@ -10,6 +10,7 @@ Classifier: Development Status :: 5 - Production/Stable
10
10
  Classifier: Intended Audience :: Developers
11
11
  Classifier: Topic :: Office/Business :: Financial :: Investment
12
12
  Classifier: Programming Language :: Python :: 3.12
13
+ Classifier: Programming Language :: C++
13
14
  Classifier: Operating System :: Microsoft :: Windows
14
15
  Classifier: Operating System :: POSIX :: Linux
15
16
  Classifier: Operating System :: MacOS
@@ -54,9 +55,10 @@ Description-Content-Type: text/markdown
54
55
  [![PYPI Version](https://img.shields.io/pypi/v/bbstrader)](https://pypi.org/project/bbstrader/)
55
56
  [![PyPi status](https://img.shields.io/pypi/status/bbstrader.svg?maxAge=60)](https://pypi.python.org/pypi/bbstrader)
56
57
  [![Supported Python Versions](https://img.shields.io/pypi/pyversions/bbstrader)](https://pypi.org/project/bbstrader/)
57
- [![Linux](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_linux.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_linux.yml)
58
- [![macOS](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_macos.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_macos.yml)
59
- [![Windows](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_win.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_win.yml)
58
+ [![Build](https://github.com/bbalouki/bbstrader/actions/workflows/build.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/build.yml)
59
+ ![Linux](https://img.shields.io/badge/Linux-FCC624?logo=linux&logoColor=black)
60
+ ![macOS](https://img.shields.io/badge/macOS-000000?logo=apple&logoColor=white)
61
+ ![Windows](https://img.shields.io/badge/Windows-0078D6?logo=windows&logoColor=white)
60
62
  [![C++20](https://img.shields.io/badge/C++-20-blue.svg)](https://isocpp.org/std/the-standard)
61
63
  [![CMake](https://img.shields.io/badge/CMake-3.20+-blue.svg)](https://cmake.org/)
62
64
  [![PyPI Downloads](https://static.pepy.tech/badge/bbstrader)](https://pepy.tech/projects/bbstrader)
@@ -4,9 +4,10 @@
4
4
  [![PYPI Version](https://img.shields.io/pypi/v/bbstrader)](https://pypi.org/project/bbstrader/)
5
5
  [![PyPi status](https://img.shields.io/pypi/status/bbstrader.svg?maxAge=60)](https://pypi.python.org/pypi/bbstrader)
6
6
  [![Supported Python Versions](https://img.shields.io/pypi/pyversions/bbstrader)](https://pypi.org/project/bbstrader/)
7
- [![Linux](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_linux.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_linux.yml)
8
- [![macOS](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_macos.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_macos.yml)
9
- [![Windows](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_win.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/cpp_win.yml)
7
+ [![Build](https://github.com/bbalouki/bbstrader/actions/workflows/build.yml/badge.svg)](https://github.com/bbalouki/bbstrader/actions/workflows/build.yml)
8
+ ![Linux](https://img.shields.io/badge/Linux-FCC624?logo=linux&logoColor=black)
9
+ ![macOS](https://img.shields.io/badge/macOS-000000?logo=apple&logoColor=white)
10
+ ![Windows](https://img.shields.io/badge/Windows-0078D6?logo=windows&logoColor=white)
10
11
  [![C++20](https://img.shields.io/badge/C++-20-blue.svg)](https://isocpp.org/std/the-standard)
11
12
  [![CMake](https://img.shields.io/badge/CMake-3.20+-blue.svg)](https://cmake.org/)
12
13
  [![PyPI Downloads](https://static.pepy.tech/badge/bbstrader)](https://pepy.tech/projects/bbstrader)
@@ -0,0 +1 @@
1
+ 2.0.3
@@ -702,9 +702,7 @@ class FMPDataHandler(BaseCSVDataHandler):
702
702
  if data.empty or len(data) == 0:
703
703
  raise ValueError("No data found.")
704
704
  if period[0].isnumeric():
705
- data = data.drop(
706
- columns=["Return", "Volatility", "Cumulative Return"], axis=1
707
- )
705
+ data = data.drop(columns=["Return", "Volatility", "Cumulative Return"])
708
706
  else:
709
707
  data = data.drop(
710
708
  columns=[
@@ -714,8 +712,7 @@ class FMPDataHandler(BaseCSVDataHandler):
714
712
  "Excess Return",
715
713
  "Excess Volatility",
716
714
  "Cumulative Return",
717
- ],
718
- axis=1,
715
+ ]
719
716
  )
720
717
  data = data.reset_index()
721
718
  if "Adj Close" not in data.columns:
@@ -349,9 +349,13 @@ class Portfolio:
349
349
  sharpe_ratio = create_sharpe_ratio(returns, periods=self.tf)
350
350
  sortino_ratio = create_sortino_ratio(returns, periods=self.tf)
351
351
  drawdown, _, _ = create_drawdowns(pnl)
352
+ drawdown = drawdown.fillna(0.0)
352
353
  max_dd = qs.stats.max_drawdown(returns)
353
354
  dd_details = qs.stats.drawdown_details(drawdown)
354
- dd_duration = dd_details["days"].max()
355
+ if dd_details.empty:
356
+ dd_duration = 0
357
+ else:
358
+ dd_duration = dd_details["days"].max()
355
359
  self.equity_curve["Drawdown"] = drawdown
356
360
 
357
361
  stats = [
@@ -54,6 +54,7 @@ classifiers = [
54
54
  "Intended Audience :: Developers",
55
55
  "Topic :: Office/Business :: Financial :: Investment",
56
56
  "Programming Language :: Python :: 3.12",
57
+ "Programming Language :: C++",
57
58
  "Operating System :: Microsoft :: Windows",
58
59
  "Operating System :: POSIX :: Linux",
59
60
  "Operating System :: MacOS",
@@ -0,0 +1,25 @@
1
+ [Setup]
2
+ AppName=TradeCopier
3
+ AppVersion=2.0.3
4
+ AppPublisher=bbstrading
5
+ DefaultDirName={pf}\TradeCopier
6
+ DefaultGroupName=TradeCopier
7
+ OutputDir=.
8
+ OutputBaseFilename=TradeCopier
9
+ Compression=lzma
10
+ SolidCompression=yes
11
+ LicenseFile=LICENSE
12
+ SetupIconFile=bbstrader\assets\bbstrader.ico
13
+
14
+ [Files]
15
+ Source: "dist\tcopier.exe"; DestDir: "{app}"; Flags: ignoreversion
16
+ Source: "bbstrader\assets\bbstrader.ico"; DestDir: "{app}"; Flags: ignoreversion
17
+ [Icons]
18
+ Name: "{group}\TradeCopier"; Filename: "{app}\tcopier.exe"; IconFilename: "{app}\bbstrader.ico"
19
+ Name: "{group}\Uninstall tradecopier"; Filename: "{uninstallexe}"
20
+ Name: "{commondesktop}\tradecopier"; Filename: "{app}\tcopier.exe"; IconFilename: "{app}\bbstrader.ico"; Tasks: desktopicon
21
+
22
+
23
+
24
+ [Tasks]
25
+ Name: "desktopicon"; Description: "Create a &desktop shortcut"; GroupDescription: "Additional icons:"
@@ -4,7 +4,6 @@ from PyInstaller.utils.hooks import collect_data_files, collect_submodules, coll
4
4
 
5
5
  block_cipher = None
6
6
 
7
- # Collect files for en_core_web_sm
8
7
  datas_sm = collect_data_files('en_core_web_sm')
9
8
  hiddenimports_sm = collect_submodules('en_core_web_sm')
10
9
  hiddenimports_bbs = collect_submodules("bbstrader")
@@ -16,8 +15,6 @@ explicit_hidden_imports = [
16
15
  'MetaTrader5'
17
16
  ]
18
17
 
19
-
20
-
21
18
  a = Analysis(
22
19
  ['bbstrader/metatrader/_copier.py'],
23
20
  pathex=[],
@@ -277,8 +277,6 @@ def test_output_summary_stats(
277
277
  p.equity_curve["Returns"] = p.equity_curve["Returns"].fillna(0.0)
278
278
  p.equity_curve["Equity Curve"] = p.equity_curve["Equity Curve"].fillna(1.0)
279
279
 
280
- p.equity_curve["Drawdown"] = 0.0
281
-
282
280
  # Call the method under test
283
281
  stats = p.output_summary_stats()
284
282
 
@@ -1,66 +0,0 @@
1
- name: macOS
2
-
3
- on:
4
- pull_request:
5
- branches:
6
- - main
7
-
8
- jobs:
9
- build-and-test:
10
- runs-on: macos-latest
11
- strategy:
12
- fail-fast: false
13
- matrix:
14
- build_type: [Release, Debug]
15
- cpp_standard: [20, 23]
16
- env:
17
- VCPKG_ROOT: ${{ github.workspace }}/vcpkg
18
- BUILD_DIR: ${{ github.workspace }}/build
19
- CMAKE_BUILD_PARALLEL_LEVEL: 4
20
-
21
- steps:
22
- - name: Checkout source
23
- uses: actions/checkout@v4
24
-
25
- - name: Cache vcpkg
26
- uses: actions/cache@v4
27
- with:
28
- path: |
29
- ${{ env.VCPKG_ROOT }}
30
- ~/.cache/vcpkg
31
- key: ${{ runner.os }}-vcpkg-${{ hashFiles('vcpkg.json') }}
32
- restore-keys: |
33
- ${{ runner.os }}-vcpkg-
34
-
35
- - name: Set up vcpkg
36
- uses: lukka/run-vcpkg@v11
37
-
38
- - name: Cache CMake build
39
- uses: actions/cache@v4
40
- with:
41
- path: ${{ env.BUILD_DIR }}
42
- key: ${{ runner.os }}-${{ matrix.build_type }}-cmake-${{ hashFiles('CMakeLists.txt', '**/CMakeLists.txt') }}
43
- restore-keys: |
44
- ${{ runner.os }}-${{ matrix.build_type }}-cmake-
45
-
46
- - name: Install system package
47
- shell: bash
48
- run: brew install autoconf autoconf-archive automake libtool
49
-
50
- - name: Configure CMake
51
- shell: bash
52
- run: |
53
- cmake -S . -B $BUILD_DIR \
54
- -DBBSTRADER_BUILD_TESTS=ON \
55
- -DBBSTRADER_CXX_STANDARD=${{ matrix.cpp_standard }} \
56
- -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
57
- -DCMAKE_TOOLCHAIN_FILE=$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake \
58
- -DVCPKG_TARGET_TRIPLET=$(if [[ "$(uname -m)" == "arm64" ]]; then echo "arm64-osx"; else echo "x64-osx"; fi)
59
-
60
- - name: Build
61
- shell: bash
62
- run: cmake --build $BUILD_DIR --config ${{ matrix.build_type }}
63
-
64
- - name: Run tests
65
- shell: bash
66
- run: ctest --test-dir $BUILD_DIR --output-on-failure --build-config ${{ matrix.build_type }}
@@ -1,62 +0,0 @@
1
- name: Windows
2
-
3
- on:
4
- pull_request:
5
- branches:
6
- - main
7
-
8
- jobs:
9
- build-and-test:
10
- runs-on: windows-latest
11
- strategy:
12
- fail-fast: false
13
- matrix:
14
- build_type: [Release, Debug]
15
- cpp_standard: [20, 23]
16
- env:
17
- VCPKG_ROOT: ${{ github.workspace }}/vcpkg
18
- BUILD_DIR: ${{ github.workspace }}/build
19
- CMAKE_BUILD_PARALLEL_LEVEL: 4
20
-
21
- steps:
22
- - name: Checkout source
23
- uses: actions/checkout@v4
24
-
25
- - name: Cache vcpkg
26
- uses: actions/cache@v4
27
- with:
28
- path: |
29
- ${{ env.VCPKG_ROOT }}
30
- ~/.cache/vcpkg
31
- key: ${{ runner.os }}-vcpkg-${{ hashFiles('vcpkg.json') }}
32
- restore-keys: |
33
- ${{ runner.os }}-vcpkg-
34
-
35
- - name: Set up vcpkg
36
- uses: lukka/run-vcpkg@v11
37
-
38
- - name: Cache CMake build
39
- uses: actions/cache@v4
40
- with:
41
- path: ${{ env.BUILD_DIR }}
42
- key: ${{ runner.os }}-${{ matrix.build_type }}-cmake-${{ hashFiles('CMakeLists.txt', '**/CMakeLists.txt') }}
43
- restore-keys: |
44
- ${{ runner.os }}-${{ matrix.build_type }}-cmake-
45
-
46
- - name: Configure CMake
47
- shell: bash
48
- run: |
49
- cmake -S . -B $BUILD_DIR \
50
- -DBBSTRADER_BUILD_TESTS=ON \
51
- -DBBSTRADER_CXX_STANDARD=${{ matrix.cpp_standard }} \
52
- -DCMAKE_BUILD_TYPE=${{ matrix.build_type }} \
53
- -DCMAKE_TOOLCHAIN_FILE=$VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake \
54
- -DVCPKG_TARGET_TRIPLET=x64-windows
55
-
56
- - name: Build
57
- shell: bash
58
- run: cmake --build $BUILD_DIR --config ${{ matrix.build_type }}
59
-
60
- - name: Run tests
61
- shell: bash
62
- run: ctest --test-dir $BUILD_DIR --output-on-failure --build-config ${{ matrix.build_type }}
@@ -1 +0,0 @@
1
- 2.0.2
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