Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
546 commits
Select commit Hold shift + click to select a range
0d181b7
trying to fix #122
Tim55667757 Jan 30, 2023
85172b6
revert #122 not a bug, need export PYTHONPATH
Tim55667757 Jan 30, 2023
afbd4a5
#119 up version
Tim55667757 Jan 30, 2023
f0fceab
#119 bot readme was updated
Tim55667757 Jan 30, 2023
c9068ee
#122 main readmes were updated
Tim55667757 Jan 30, 2023
7a3ce9f
#122 main readmes were updated
Tim55667757 Jan 30, 2023
6c07624
#122 changelogs were updated
Tim55667757 Jan 30, 2023
966bb3a
#119 unused variable was removed
Tim55667757 Feb 1, 2023
097cb75
#119 `volumeIgnored` parameter was added
Tim55667757 Feb 1, 2023
e3ce939
`retry` and `pause` variables were moved to class variables
Tim55667757 Feb 13, 2023
6cbef0e
debug builds were disabled
Tim55667757 Feb 13, 2023
9516d80
#119 new screenshots with examples were added
Tim55667757 Feb 13, 2023
ab55da0
#119 new screenshots with examples were added to readme
Tim55667757 Feb 13, 2023
ffa75f0
trigger debug build for: `retry` and `pause` variables were moved to …
Tim55667757 Feb 13, 2023
04573a5
debug build was disabled
Tim55667757 Feb 13, 2023
9b855cb
#124 Bug fixed: `Incorrect values in view["stat"]["funds"] record`.
Tim55667757 Feb 14, 2023
85b4a1b
#124 Bug fixed: `Incorrect values in view["stat"]["funds"] record`.
Tim55667757 Feb 14, 2023
a1437ed
#125 New types were added to `TKS_OPERATION_TYPES` constant
Tim55667757 Feb 14, 2023
8ee9491
#125 changelogs were updated
Tim55667757 Feb 14, 2023
534a812
#101 Bug fixed with incorrect calculation of available currency and a…
Tim55667757 Feb 14, 2023
569163f
debug builds were disabled
Tim55667757 Feb 14, 2023
2d771a9
#124 bug fix
Tim55667757 Feb 15, 2023
54b7cc2
debug build was disabled
Tim55667757 Feb 15, 2023
2243516
#103 format fixed
Tim55667757 Feb 16, 2023
0faf64c
#126 Operation type counts was updated in Deals report
Tim55667757 Feb 16, 2023
200fe36
debug build was disabled
Tim55667757 Feb 16, 2023
a8ecaec
little typo in template css
Tim55667757 Feb 17, 2023
da21a67
Merge remote-tracking branch 'origin/develop' into develop
Tim55667757 Feb 17, 2023
4773eda
little typo in changelogs
Tim55667757 Feb 17, 2023
334ff14
little typo in html template
Tim55667757 Feb 17, 2023
1585daa
little typo in html template: links were changed
Tim55667757 Feb 17, 2023
3f50909
decreased count of some warning messages
Tim55667757 Feb 20, 2023
5957f98
debug build was disabled
Tim55667757 Feb 20, 2023
f0d32cf
#127 Add some currency aliases. Set EUR, GBP, CHF, JPY as not for tra…
Tim55667757 Feb 27, 2023
fbdf92f
#127 Bug fixed: `KeyError: 'name'`, in `Overview()` method
Tim55667757 Feb 27, 2023
9bdc4d2
#127 disabling debug builds
Tim55667757 Feb 27, 2023
accd644
#128 Bug fixed: `RUB000UTSTOM` FIGI not in `dump.json`. Since 7 March…
Tim55667757 Mar 7, 2023
1e6ff10
#128 debug build was disabled
Tim55667757 Mar 7, 2023
499398d
Link to translated article (EN) was added
Tim55667757 Sep 9, 2023
c80235b
little typo in `Order()`
Tim55667757 Sep 9, 2023
4c5d757
#14 Example of `secrets.yaml` config file for "Orders Grid Setter" sc…
Tim55667757 Sep 10, 2023
813c145
#14 Example of `config.yaml` - the main config file for "Orders Grid …
Tim55667757 Sep 10, 2023
b72b94c
#14 `requirements.txt` for "Orders Grid Setter" scenario was added
Tim55667757 Sep 10, 2023
eb2f748
#14 Main implementation of "Orders Grid Setter" scenario
Tim55667757 Sep 10, 2023
0834af8
#14 changelogs were updated
Tim55667757 Sep 10, 2023
9a0e1ba
#14 Explanation of how the "Order Grid Setter" scenario work was added
Tim55667757 Sep 10, 2023
b5c95d5
#14 Test config was updated
Tim55667757 Sep 20, 2023
8a0ecf2
little typo in README_EN.md
Tim55667757 Sep 20, 2023
0498388
#14 Documentation for "Order Grid Setter" scenario was added
Tim55667757 Sep 20, 2023
1abb4c0
#14 little typo
Tim55667757 Sep 20, 2023
4d5c121
#14 The speed of placing orders has been calculated
Tim55667757 Sep 20, 2023
808758e
master builds were disabled
Tim55667757 Nov 25, 2023
0941541
Promoted: `PriceGenerator==1.4.93` and `TKSBrokerAPI==1.6.dev155`. Ex…
Tim55667757 Nov 25, 2023
141003a
more informative message if token is broken or old
Tim55667757 Mar 13, 2025
f0609f2
little typo
Tim55667757 Mar 13, 2025
8660941
little typo
Tim55667757 Mar 13, 2025
7234e0b
check if the key exists when a dump is requested
Tim55667757 Apr 18, 2025
8562398
check if the instrument's list is empty
Tim55667757 Apr 18, 2025
322f99e
Update dependencies in requirements.txt
Tim55667757 Apr 18, 2025
2b0e82a
#142 Set up local imports and fix package import paths
Tim55667757 Apr 18, 2025
fd39d74
#142 Remove the import error troubleshooting section from README files
Tim55667757 Apr 18, 2025
8c08662
#140 Add GitHub Actions CI/CD workflow for Python package
Tim55667757 Apr 18, 2025
c089348
#140 Disables CI/CD workflows for the 'develop' branch by default. On…
Tim55667757 Apr 18, 2025
515c1d4
#140 Migrate to GitHub Actions and refactor setup configuration
Tim55667757 Apr 18, 2025
fe01b62
#140 Adjust versioning to include build number offset
Tim55667757 Apr 18, 2025
1a7c656
#140 Enable manual trigger for CI/CD workflow
Tim55667757 Apr 18, 2025
9bf0d58
#140 new test build
Tim55667757 Apr 18, 2025
87566a1
#140 Monkey Patch for PriceGenerator's `pandas_ta` module
Tim55667757 Apr 18, 2025
e6c85f2
#140 little typo.
Tim55667757 Apr 18, 2025
5426a41
#140 Update workflow to rely on requirements.txt for dependencies
Tim55667757 Apr 18, 2025
159e417
#140 Update workflow to rely on requirements.txt for dependencies
Tim55667757 Apr 18, 2025
fe28772
#140 test build
Tim55667757 Apr 18, 2025
4f2a3d6
#140 Update CI/CD workflow steps and upgrade artifact actions
Tim55667757 Apr 18, 2025
40e58b4
#142 Fix import path for UniLogger in TKSBrokerAPI module
Tim55667757 Apr 18, 2025
1f065a2
#140 Simplify GitHub event name handling in CI workflow.
Tim55667757 Apr 18, 2025
a6c615e
#140 Add Python version matrix and caching to GitHub Actions
Tim55667757 Apr 18, 2025
f0abf3d
#140 Refactor CI/CD workflows, increase build speed with cache, and o…
Tim55667757 Apr 19, 2025
b72829d
#140 Add QA checks, cache management, and ensure universal builds
Tim55667757 Apr 19, 2025
cddcf58
#140 Update workflow notification conditions and license format
Tim55667757 Apr 19, 2025
aa9c4a8
#140 Simplify CI/CD workflow notifications and remove pip cache clear.
Tim55667757 Apr 19, 2025
858e71e
#140 Simplify workflows and standardize project configuration
Tim55667757 Apr 19, 2025
844090c
№140 Remove build system configuration from pyproject.toml
Tim55667757 Apr 19, 2025
b532a65
№140 Update version management to use a dedicated _version.py file
Tim55667757 Apr 19, 2025
3c92d74
#140 Remove Twine metadata verification from CI/CD workflow
Tim55667757 Apr 19, 2025
4e567e3
#140 Update CI/CD badges and dependencies in documentation
Tim55667757 Apr 19, 2025
e3a90f3
#140 return twine check dist
Tim55667757 Apr 19, 2025
2effa08
Update documentation and implement CI/CD with GitHub Actions
Tim55667757 Apr 19, 2025
96d8de8
#140 Refactor `long_description` format in `setup.py`.
Tim55667757 Apr 19, 2025
b839755
#140 little typo
Tim55667757 Apr 19, 2025
cef185a
#142 little typo
Tim55667757 Apr 19, 2025
f84a8a2
#138 little typo
Tim55667757 Apr 19, 2025
0836ee2
Add some tests for TradeRoutines.GetDatesAsString
Tim55667757 Apr 20, 2025
3ea4116
#145 Add SIGNAL_FILTER for adjusting signal strength levels
Tim55667757 Apr 20, 2025
7160771
#144 Add `CalculateAdaptiveCacheReserve()` function for dynamic reser…
Tim55667757 Apr 20, 2025
60e4a9a
#144 Add input validation for portfolio computation parameters
Tim55667757 Apr 20, 2025
2c359f8
#144 Improve cash reserve calculation with exponential amplification
Tim55667757 Apr 20, 2025
a0eaf14
#144 Add unit tests for `CalculateAdaptiveCacheReserve()` function
Tim55667757 Apr 20, 2025
3cd3d76
#144 little typo
Tim55667757 Apr 20, 2025
d25b859
Update TKSBrokerAPI version in dependencies and remove outdated READM…
Tim55667757 Apr 21, 2025
4dbb5b4
Update TKSBrokerAPI version in dependencies in the Jupiter Notebooks
Tim55667757 Apr 21, 2025
0827b9b
#145 Add HampelCleaner function for outlier detection and handling
Tim55667757 Apr 21, 2025
cb72743
#145 Add tests for `HampelCleaner()` function with various strategies
Tim55667757 Apr 21, 2025
5a10a54
#146 Changelogs are updated
Tim55667757 Apr 22, 2025
66224ed
#146 Global refactor Hampel Filter algorithm.
Tim55667757 Apr 24, 2025
587720b
Enhance Hampel filter tests and add performance benchmarks
Tim55667757 Apr 24, 2025
22bfd6f
Add references and examples for Hampel filter in docstring
Tim55667757 Apr 24, 2025
a110e9e
#146 links are updated
Tim55667757 Apr 24, 2025
5c6c9b4
#146 Improve anomaly detection logic and extend test coverage
Tim55667757 Apr 24, 2025
2f12581
#146 Update scipy dependency
Tim55667757 Apr 24, 2025
34cbe9d
Little typo
Tim55667757 Apr 24, 2025
d8223a0
#145 Add target reachability estimation and related utility functions
Tim55667757 Apr 25, 2025
d78621e
#145 Add tests for EstimateTargetReachability function
Tim55667757 Apr 25, 2025
f10c31d
#145 Add Hampel-based outlier cleaning option to probability estimation
Tim55667757 Apr 25, 2025
fffd186
#145 Update documentation
Tim55667757 Apr 25, 2025
2c4b9b6
#145 Refactor `HampelCleaner()` logic to increase speed and add perfo…
Tim55667757 Apr 25, 2025
1008778
#145 Add unit tests for LogReturns method in TradeRoutines
Tim55667757 Apr 25, 2025
e2a0289
#145 Add tests for MeanReturn functionality in TradeRoutines
Tim55667757 Apr 25, 2025
33e8939
#145 little typo in tests
Tim55667757 Apr 25, 2025
f8780e7
#145 Adjust performance test parameters for HampelCleaner.
Tim55667757 Apr 25, 2025
b49ff8d
#145 Add unit tests for TradeRoutines.Volatility function
Tim55667757 Apr 25, 2025
4f8dcf2
#145 Add unit tests for TradeRoutines.ZScore method
Tim55667757 Apr 25, 2025
ffe3cfd
#145 Add unit tests for BayesianAggregation in TradeRoutines
Tim55667757 Apr 25, 2025
a3d3249
#145 Add tests for VolatilityWeight with positive and edge cases
Tim55667757 Apr 25, 2025
140d4fd
Add reference to Fuzzy Technologies in documentation
Tim55667757 Apr 25, 2025
194610d
#145 Add Target Probability Estimation feature
Tim55667757 Apr 25, 2025
a80a6b2
#145 Added a new option `compareWithMax`: bool (default `True`) to co…
Tim55667757 Apr 26, 2025
941f314
#145 doc is updated
Tim55667757 Apr 26, 2025
9fc197d
#148 Reorganize and expand dependencies in requirements.txt
Tim55667757 Apr 27, 2025
dcd246c
#148 Add unit tests for RollingMean, RollingStd, and FastBBands
Tim55667757 Apr 27, 2025
0b08187
#148 Add improved FastBBands() implementation to changelogs.
Tim55667757 Apr 27, 2025
04f95f6
#148 Add fast Bollinger Bands with Numba-optimized rolling functions.
Tim55667757 Apr 27, 2025
31bf6cf
#149 Add tests for FastPSAR functionality and performance
Tim55667757 Apr 27, 2025
fa4635d
#149 Fix typos and grammar in CHANGELOG files
Tim55667757 Apr 27, 2025
65b4708
Clean up docs folder before generating new documentation
Tim55667757 Apr 27, 2025
d7bb695
Simplify docs build process by removing redundant step
Tim55667757 Apr 27, 2025
bb8175d
#148 #149 Add new TA functions to documentation and search integration
Tim55667757 Apr 27, 2025
0e3ab13
#149 Add `FastPSAR()` implementation for Parabolic SAR calculation.
Tim55667757 Apr 27, 2025
47daba7
#148 Enhance SMA calculation and update search script comment.
Tim55667757 Apr 27, 2025
a342bd8
#148 Optimize SMA calculation with running sum approach
Tim55667757 Apr 27, 2025
becb56e
Add links to release notes in both English and Russian sections
Tim55667757 Apr 27, 2025
3442e62
#146 Refactor anomaly detection logic in series with NaN to improve c…
Tim55667757 Apr 27, 2025
bf43e8e
little typo
Tim55667757 Apr 29, 2025
c838771
#150 Improve error handling and add unit tests for API requests
Tim55667757 Apr 29, 2025
6bc8455
#150 Changelogs were updated: enhance `SendAPIRequest()` with retries…
Tim55667757 Apr 29, 2025
d32e7b9
#150 Change log level from warning to debug for retry messages
Tim55667757 Apr 29, 2025
bafbdb6
#151 Refactor imports for clarity and organization
Tim55667757 Apr 29, 2025
d8b9d54
#151 Refactor logging messages and improve thread pool usage, also te…
Tim55667757 Apr 29, 2025
0059b90
#151 Improve `_ParseJSON` handling for edge cases and enhance tests
Tim55667757 Apr 29, 2025
58e1d07
#151 Truncate and preview long error response bodies.
Tim55667757 Apr 29, 2025
8c43de6
#151 Fix rate limit header check to handle missing headers safely.
Tim55667757 Apr 29, 2025
efeaf1b
#151 Refactor conditionals to use dict.get() for clarity
Tim55667757 Apr 29, 2025
45abe2f
#151 Reduce retry pause and enhance request error handling
Tim55667757 Apr 29, 2025
3a26f20
#151 Add test for SendAPIRequest handling empty auth token
Tim55667757 Apr 29, 2025
8014d25
#151 Refactor portfolio calculation and optimize data handling in `Ov…
Tim55667757 Apr 29, 2025
5a4d156
#151 api doc is updated
Tim55667757 Apr 29, 2025
22f12fe
#151 Refactor `Overview` method and add comprehensive tests.
Tim55667757 Apr 29, 2025
bc05f6d
#151 changelogs: Refactor `Overview` method and add comprehensive tests.
Tim55667757 Apr 29, 2025
0e0447a
Remove unnecessary multiprocessing lock in API requests
Tim55667757 Apr 29, 2025
8824ad0
little typo
Tim55667757 Apr 30, 2025
9449ce4
#153 Changelogs: Add `FormatTimedelta()` utility for timedelta format…
Tim55667757 May 1, 2025
50e0cef
#153 Add tests for `TradeRoutines.FormatTimedelta()` functionality
Tim55667757 May 1, 2025
6395f77
#153 Add FormatTimedelta function and fix minor documentation issues …
Tim55667757 May 1, 2025
dc1a0f2
#153 Add `FormatTimedelta()` utility function for formatting timedelt…
Tim55667757 May 1, 2025
2cb86b5
#152 Changelogs: Add centralized throttling with cooperative waiting
Tim55667757 May 2, 2025
29423d9
#152 Add `RateLimiter` class to API documentation
Tim55667757 May 2, 2025
f683e08
#152 Add unit tests for RateLimiter class
Tim55667757 May 2, 2025
32ded48
#152 Add rate limiting to API requests with new RateLimiter class
Tim55667757 May 2, 2025
549315c
#152 Add support for optional methodName override in API requests
Tim55667757 May 3, 2025
926433c
#152 Initialize RateLimiter in constructor to enforce request limits
Tim55667757 May 3, 2025
b160617
Update TKSBrokerAPI documentation and improve functionality
Tim55667757 May 5, 2025
e1b61cc
little typo in api-doc
Tim55667757 May 5, 2025
d2705be
Refactor logging and update terminology for clarity
Tim55667757 May 5, 2025
3494877
Fix incorrect attribute access on FUZZY_SCALE.Fuzzy result
Tim55667757 May 5, 2025
46871b1
#154 Add FastHurst function for estimating Hurst exponent
Tim55667757 May 7, 2025
003f34e
#154 Add FastSampEn function for entropy estimation
Tim55667757 May 8, 2025
e55bbf1
#154 little typo
Tim55667757 May 8, 2025
4f377e0
#154 Add FastDfa function for Detrended Fluctuation Analysis
Tim55667757 May 8, 2025
98edf07
#154 Add ChaosMeasure function for chaos estimation models
Tim55667757 May 8, 2025
3e35da4
#154 Add ChaosConfidence function for trust coefficient conversion
Tim55667757 May 8, 2025
20f4c1a
#154 Add phase-based location and confidence utility functions
Tim55667757 May 8, 2025
9093fb7
#154 Add chaos and phase-related functions to TradeRoutines
Tim55667757 May 8, 2025
5bad199
#154 Add AdjustProbabilityByChaosAndPhaseTrust function
Tim55667757 May 8, 2025
82baa5d
#154 Reorder `EstimateTargetReachability` in module.
Tim55667757 May 8, 2025
bd4f1d6
#154 Add tests for TradeRoutines.FastHurst functionality
Tim55667757 May 8, 2025
c071b27
#154 Fix edge cases in FastSampEn and add comprehensive tests.
Tim55667757 May 8, 2025
24ecc2d
#154 Update FastSampEnPerformance test to cover larger inputs
Tim55667757 May 8, 2025
1a6345c
#154 Remove Numba JIT decoration from FastDfa and add tests.
Tim55667757 May 8, 2025
649c923
#154 Add unit tests for ChaosMeasure and ChaosConfidence methods
Tim55667757 May 8, 2025
b29dd34
#154 Add tests for PhaseLocation and PhaseConfidence methods
Tim55667757 May 8, 2025
24a3719
#154 Update test_FastDfaPositive to adjust expected range
Tim55667757 May 8, 2025
95405d8
#154 Add unit tests for AdjustProbabilityByChaosAndPhaseTrust
Tim55667757 May 8, 2025
1fc65ce
#154 Adjust performance threshold in HampelCleaner test
Tim55667757 May 8, 2025
723c0e7
#154 api-doc updated
Tim55667757 May 8, 2025
0a0db54
#154 Add chaos and phase confidence modifiers to probability
Tim55667757 May 8, 2025
c7fcd76
#154 Add chaosTail parameter for chaos estimation and update tests
Tim55667757 May 9, 2025
e2375ec
#154 api-doc updated
Tim55667757 May 9, 2025
3664df2
#154 Added chaos/phase metrics and optimizations to `EstimateTargetRe…
Tim55667757 May 9, 2025
410c08c
#154 Refactor chaos and phase adjustment logic, fix tests.
Tim55667757 May 9, 2025
e9e6998
#154 Remove debug print statements in test_TradeRoutines.py
Tim55667757 May 9, 2025
28aba37
#129 Add DetermineDecimalPrecision function and corresponding tests
Tim55667757 May 11, 2025
6ff974e
#129 Round float values to match data precision before CSV export
Tim55667757 May 11, 2025
b322f64
#129 Add `DetermineDecimalPrecision()` for automatic rounding and api…
Tim55667757 May 11, 2025
3218963
#91 api-doc updated
Tim55667757 May 17, 2025
7667816
#91 Fixed incorrect .upper() conversion for FIGI in CLI argument pars…
Tim55667757 May 17, 2025
86192ff
#88 Refactor stop-orders display logic with grouping by ticker.
Tim55667757 May 17, 2025
fd2eed5
#137 bug fix with RUB funds access. Implemented safer dictionary hand…
Tim55667757 May 17, 2025
03a4561
#133 Remove redundant encoding parameter in Excel writer
Tim55667757 May 17, 2025
0579244
Update pandas dependency to version 2.2.3
Tim55667757 May 17, 2025
f33270a
#78 Optimize historical data fetching with multi-threading
Tim55667757 May 18, 2025
5202feb
Fix datetime parsing with explicit formats for date and time.
Tim55667757 May 18, 2025
7edaa12
#78 Fix --only-missing flag logic
Tim55667757 May 19, 2025
64f0589
Merge remote-tracking branch 'origin/develop' into develop
Tim55667757 May 19, 2025
2040d63
#78 Bug fixed with `--only-missing` key. Refactor history data handli…
Tim55667757 May 19, 2025
ebfe6ba
#78 Update type hinting and refine logger initialization handling
Tim55667757 May 19, 2025
5e32c85
#78 cnahgelogs
Tim55667757 May 19, 2025
b802bfc
#88 #91 #131 #133 #137 #144 changelogs updated
Tim55667757 May 19, 2025
563d238
#57 Add pycron dependency to requirements.txt
Tim55667757 May 19, 2025
9308dfb
#57 Add tests for `HistoryAutoUpdater()`
Tim55667757 May 19, 2025
9966763
#57 Add test case for single ticker string in `HistoryAutoUpdater()`
Tim55667757 May 19, 2025
8db4528
#57 Fix and enhance test for _HistoryAutoUpdaterWrapper behavior
Tim55667757 May 20, 2025
c1333fc
#57 changelogs
Tim55667757 May 20, 2025
d586610
#57 api-doc
Tim55667757 May 20, 2025
31a6340
#57 readmes updated
Tim55667757 May 20, 2025
04d1770
#57 Auto-updating historical data with multithreading and cron suppor…
Tim55667757 May 20, 2025
e059b82
little typo
Tim55667757 May 20, 2025
1801a8a
#57 Update README with new features for history downloads and charts
Tim55667757 May 20, 2025
386108f
release-1.6 preapring...
Tim55667757 May 20, 2025
c3215d1
release-1.6 preapring...
Tim55667757 May 20, 2025
179910b
#141 Add Dockerfile for TKSBrokerAPI container deployment
Tim55667757 May 21, 2025
447bcfd
#141 Add build version ARG and optimize cleanup in Dockerfile
Tim55667757 May 21, 2025
3ecf0c1
#141 Add Docker build and push step to CI/CD workflow
Tim55667757 May 21, 2025
fed34c6
#141 changelogs
Tim55667757 May 21, 2025
f52545a
#141 Update version info output for better branding
Tim55667757 May 21, 2025
fd5c396
#141 Update CI/CD pipeline to streamline version handling
Tim55667757 May 21, 2025
6740fc0
#141 fix version
Tim55667757 May 21, 2025
3e7d3c7
#141 fix version 2
Tim55667757 May 21, 2025
d0b525e
#141 Update Docker image push to use personal DockerHub account tim55…
Tim55667757 May 21, 2025
0bca2ea
#141 fix setup.py
Tim55667757 May 21, 2025
d65301d
#141 Refactor version handling in CI/CD workflow
Tim55667757 May 21, 2025
6e10b7b
#141 Update workflow to use $GITHUB_OUTPUT for version output
Tim55667757 May 21, 2025
645cf05
#141 Simplify workflow by removing matrix strategy for Python 3.9.
Tim55667757 May 21, 2025
d107801
release-1.6 preapring...
Tim55667757 May 21, 2025
f91a624
#141 Optimize Docker version handling in workflow
Tim55667757 May 21, 2025
b512657
#141 Update Docker job dependencies in CI/CD workflow
Tim55667757 May 21, 2025
21f052b
#141 fix path
Tim55667757 May 21, 2025
8d805b9
release-1.6 preapring...
Tim55667757 May 21, 2025
9c2354d
release-1.6 preapring...
Tim55667757 May 21, 2025
77e233c
#141 Add retry logic for TKSBrokerAPI installation in Dockerfile
Tim55667757 May 21, 2025
1861b7f
release-1.6 preapring...
Tim55667757 May 21, 2025
f2f3e21
Merge remote-tracking branch 'origin/master' into develop
Tim55667757 May 21, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
272 changes: 272 additions & 0 deletions .github/workflows/python-package-ci-cd.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,272 @@
name: Python Package CI/CD

on:
push:
branches:
- 'release-*'
- master
- develop
pull_request:
branches:
- 'release-*'
- master
workflow_dispatch: # Manual runs allowed.

jobs:

pre_build:
name: 🔧 Pre-Building Environment
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.9"]
steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Setup Python 3.9
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Check Python Version
run: |
echo 🐍 Using Python version:
python --version

- name: Cache Python packages
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Upgrade pip and install dependencies
run: |
echo 🔄 Upgrading pip and reinstalling all dependencies...
python -m pip install --upgrade pip --force-reinstall
pip install -r requirements-dev.txt

- name: Log Installed Dependencies
run: |
echo 📄 Installed packages:
pip list

- name: Pre-Build Completed
run: echo ✅ PRE-BUILDING stage completed successfully!

testing:
name: 📝 Running Tests
needs: pre_build
runs-on: ubuntu-latest
env:
PYTHONPATH: ${{ github.workspace }}:${{ github.workspace }}/tksbrokerapi:${{ github.workspace }}/tests
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11", "3.12"]
steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Check Python Version
run: |
echo 🐍 Using Python version:
python --version

- name: Restore Python packages cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Install Test Dependencies
run: |
echo 🔄 Installing dev dependencies...
python -m pip install --upgrade pip
pip install -r requirements-dev.txt

- name: Log Used Dependencies
run: |
echo 📄 Used packages:
pip list

- name: Run Tests
run: |
echo 🔍 Starting pytest...
pytest tests -v --disable-pytest-warnings

- name: Testing Completed
run: echo ✅ TESTING stage completed successfully!

building:
name: ⚙️ Building Package
needs: testing
runs-on: ubuntu-latest
outputs:
version: ${{ steps.setver.outputs.version }}
steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Setup Python 3.9
uses: actions/setup-python@v4
with:
python-version: 3.9

- name: Check Python Version
run: |
echo 🐍 Using Python version:
python --version

- name: Restore Python packages cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Install Build Dependencies
run: |
echo 🔄 Installing dev dependencies...
python -m pip install --upgrade pip
pip install -r requirements-dev.txt

- name: Log Used Dependencies
run: |
echo 📄 Used packages:
pip list

- name: Build Package
run: |
echo 📦 Building distribution...
python setup.py sdist bdist_wheel

- name: Build Universal Wheel
run: |
echo 🌍 Building universal wheel...
python setup.py bdist_wheel --universal

- name: Test Package Installation
run: |
echo 📦 Testing distribution...
pip install ./dist/*.tar.gz

- name: Upload Build Artifacts
uses: actions/upload-artifact@v4
with:
name: python-package
path: dist/

- name: Set version from .version
id: setver
run: |
VERSION=$(cat .version | tr -d '\n')
echo "VERSION=$VERSION"
echo "version=$VERSION" >> $GITHUB_OUTPUT

- name: Building Completed
run: echo ✅ BUILDING stage completed successfully!

publish:
name: 🚀 Publishing to PyPI
needs: building
runs-on: ubuntu-latest
if: github.event_name != 'pull_request'
strategy:
matrix:
python-version: ["3.9"]
steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Setup Python 3.9
uses: actions/setup-python@v4
with:
python-version: ${{ matrix.python-version }}

- name: Check Python Version
run: |
echo 🐍 Using Python version:
python --version

- name: Restore Python packages cache
uses: actions/cache@v3
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-dev.txt') }}
restore-keys: |
${{ runner.os }}-pip-

- name: Install Publish Dependencies
run: |
echo 🔄 Installing dev dependencies...
python -m pip install --upgrade pip
pip install -r requirements-dev.txt

- name: Log Used Dependencies
run: |
echo 📄 Used packages:
pip list

- name: Download Build Artifacts
uses: actions/download-artifact@v4
with:
name: python-package
path: dist/

- name: Verify Distribution
run: |
echo 🗂️ Showing files in dist/
ls -l dist/
echo 🔍 Verifying package metadata...
twine check dist/*

- name: Publish Package to PyPI
run: |
echo 🚀 Publishing distribution to PyPI...
python -m twine upload --verbose dist/* --skip-existing
env:
TWINE_USERNAME: __token__
TWINE_PASSWORD: ${{ secrets.PYPI_API_TOKEN }}

- name: Publishing Completed
run: echo ✅ PUBLISHING stage completed successfully!

docker:
name: 🐳 Build & Push Docker Image
needs: [publish, building]
runs-on: ubuntu-latest
if: github.event_name != 'pull_request'
steps:
- name: Checkout Repository
uses: actions/checkout@v3

- name: Log in to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build & Push Docker Image
run: |
echo 🐳 Building Docker image with TKSBrokerAPI==${{ needs.building.outputs.version }}
docker build \
--build-arg TKS_BUILD_VERSION=${{ needs.building.outputs.version }} \
-f deploy/Dockerfile \
-t tim55667757/tksbrokerapi:latest \
-t tim55667757/tksbrokerapi:${{ needs.building.outputs.version }} \
.
docker push tim55667757/tksbrokerapi:latest
docker push tim55667757/tksbrokerapi:${{ needs.building.outputs.version }}

- name: Docker Build Completed
run: echo ✅ DOCKER IMAGE published successfully!
3 changes: 2 additions & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ python: "3.9"

branches:
only:
- master
# - master
- /^release-.*$/
# - develop

Expand All @@ -18,6 +18,7 @@ jobs:
- echo "---> Running PRE-BUILDING stage..."
- python -m pip install --upgrade pip --force-reinstall
- pip install setuptools==59.5.0 --force-reinstall
- pip install urllib3==1.26.6 --force-reinstall
- pip install -r requirements.txt
before_script:
- export PYTHONPATH=$PYTHONPATH:$PWD:$PWD/tksbrokerapi:$PWD/tests
Expand Down
Loading