@@ -22,11 +22,11 @@ permissions:
22
22
23
23
jobs :
24
24
test :
25
-
25
+ name : Tests
26
26
runs-on : ${{ matrix.os }}
27
27
strategy :
28
28
matrix :
29
- os : [ "ubuntu-22.04", "ubuntu-24.04", "macos-13", "macos-14", "macos-15" ]
29
+ os : [ "ubuntu-22.04", "ubuntu-24.04", "macos-13", "macos-14", "macos-15", "windows-2022", "windows-2025" ]
30
30
python-version : ["3.10", "3.11", "3.12", "3.13"]
31
31
exclude :
32
32
- os : macos-13
@@ -42,32 +42,19 @@ jobs:
42
42
with :
43
43
python-version : ${{ matrix.python-version }}
44
44
45
- - name : Cache_dependencies
46
- uses : actions/cache@v4
47
- id : cache
48
- with :
49
- path : ~/dependencies/
50
- key : ${{ matrix.os }}-dependencies
51
-
52
- - name : pip cache (linux)
53
- uses : actions/cache@v4
54
- if : startsWith(matrix.os, 'ubuntu')
45
+ - name : Install uv
46
+ uses : astral-sh/setup-uv@4959332f0f014c5280e7eac8b70c90cb574c9f9b # v6.6.0
55
47
with :
56
- path : ~/.cache/pip
57
- key : test-${{ matrix.os }}-${{ matrix.python-version }}-pip
58
-
59
- - name : pip cache (macOS)
60
- uses : actions/cache@v4
61
- if : startsWith(matrix.os, 'macOS')
62
- with :
63
- path : ~/Library/Caches/pip
64
- key : test-${{ matrix.os }}-${{ matrix.python-version }}-pip
48
+ activate-environment : true
49
+ enable-cache : true
50
+ python-version : ${{ matrix.python-version }}
51
+ cache-dependency-glob : " requirements**.txt"
52
+ cache-suffix : " ${{ matrix.python-version }}"
65
53
66
54
- name : Installation - *nix
67
55
run : |
68
- python -m pip install --upgrade pip
69
- pip install -r requirements-dev.txt
70
- pip install -e .
56
+ uv pip install -r requirements-dev.txt
57
+ uv pip install -e .
71
58
72
59
- name : Tests
73
60
run : |
97
84
details : Technical CI failed on ${{ matrix.os }}
98
85
webhookUrl : ${{ secrets.DISCORD_WEBHOOK }}
99
86
100
-
101
- test_windows :
102
-
103
- runs-on : ${{ matrix.os }}
104
- strategy :
105
- matrix :
106
- os : [ "windows-2022", "windows-2025" ]
107
- python-version : ["3.10", "3.11", "3.12", "3.13"]
108
-
109
- steps :
110
- - uses : actions/checkout@v5
111
- with :
112
- persist-credentials : false
113
-
114
- - name : Set up Python
115
- uses : actions/setup-python@v5.1.1
116
- with :
117
- python-version : ${{ matrix.python-version }}
118
-
119
- - name : Pip cache (Windows)
120
- uses : actions/cache@v4
121
- if : startsWith(runner.os, 'Windows')
122
- with :
123
- path : ~\AppData\Local\pip\Cache
124
- key : ${{ matrix.os }}-${{ matrix.python-version }}-pip
125
-
126
- - name : Installation
127
- run : |
128
- python -m pip install --upgrade pip
129
- pip install -r requirements-dev.txt
130
- pip install -e .
131
-
132
- - name : Tests
133
- run : |
134
- pytest --random-order
135
-
136
- - name : Run Ruff
137
- run : |
138
- ruff check --output-format=github .
139
-
140
- - name : Discord notification
141
- uses : rjstone/discord-webhook-notify@c2597273488aeda841dd1e891321952b51f7996f # v2.2.1
142
- if : failure() && ( github.event_name != 'pull_request' || github.event.pull_request.head.repo.fork == false)
143
- with :
144
- severity : error
145
- details : Technical CI failed on ${{ matrix.os }}
146
- webhookUrl : ${{ secrets.DISCORD_WEBHOOK }}
147
-
148
87
# Notify on discord only once - when CI completes (and after deploy) in case it's successfull
149
88
notify-complete :
150
- needs : [ test, test_windows ]
89
+ needs : [ test ]
151
90
runs-on : ubuntu-latest
152
91
# Discord notification can't handle schedule events
153
92
if : (github.event_name != 'schedule')
@@ -169,7 +108,8 @@ jobs:
169
108
webhookUrl : ${{ secrets.DISCORD_WEBHOOK }}
170
109
171
110
build :
172
- needs : [ test, test_windows ]
111
+ name : Build Python 🐍 distribution 📦
112
+ needs : [ test ]
173
113
runs-on : ubuntu-22.04
174
114
steps :
175
115
- uses : actions/checkout@v5
@@ -181,6 +121,16 @@ jobs:
181
121
with :
182
122
python-version : 3.11
183
123
124
+ - name : Install uv
125
+ uses : astral-sh/setup-uv@4959332f0f014c5280e7eac8b70c90cb574c9f9b # v6.6.0
126
+ with :
127
+ activate-environment : true
128
+ enable-cache : true
129
+ python-version : 3.13
130
+ cache-dependency-glob : " requirements**.txt"
131
+ cache-suffix : " build-3.13"
132
+
133
+
184
134
- name : Extract branch name
185
135
id : extract-branch
186
136
run : |
@@ -189,7 +139,7 @@ jobs:
189
139
190
140
- name : Build distribution
191
141
run : |
192
- pip install -U build
142
+ uv pip install -U build
193
143
python -m build --sdist --wheel
194
144
195
145
- name : Upload artifacts 📦
@@ -201,6 +151,7 @@ jobs:
201
151
retention-days : 10
202
152
203
153
deploy-test-pypi :
154
+ name : " Publish Python 🐍 distribution 📦 to TestPyPI"
204
155
if : (github.event_name == 'release') && github.repository == 'freqtrade/technical'
205
156
needs : [ build ]
206
157
runs-on : ubuntu-22.04
@@ -226,6 +177,7 @@ jobs:
226
177
repository-url : https://test.pypi.org/legacy/
227
178
228
179
deploy-pypi :
180
+ name : " Publish Python 🐍 distribution 📦 to PyPI"
229
181
if : (github.event_name == 'release') && github.repository == 'freqtrade/technical'
230
182
needs : [ build ]
231
183
runs-on : ubuntu-22.04
0 commit comments