forked from fetchai/agents-aea
-
Notifications
You must be signed in to change notification settings - Fork 23
Expand file tree
/
Copy pathtox.ini
More file actions
810 lines (676 loc) · 26.3 KB
/
Copy pathtox.ini
File metadata and controls
810 lines (676 loc) · 26.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
; By default, testenvs are configured to:
; - don't skip dist (skipsdist = False)
; - don't skip the package installation (skip_install = False)
; - don't use source installation (usedevelop = False)
; where one of those steps is not necessary for the test,
; we set the associated flag (e.g. for linting we don't need
; the package installation).
[tox]
envlist = bandit, safety, black, black-check, isort, isort-check, fix-copyright, check-copyright, hash-check, docs, flake8, liccheck, mypy, pylint, vulture, {plugins-,}py{3.10,3.11,3.12,3.13,3.14}, dependencies-check, package-version-checks, lock-packages, package-dependencies-checks, fix-doc-hashes, check-doc-links-hashes, check-generate-all-protocols, generate-api-documentation
; when running locally we don't want to fail for no good reason
skip_missing_interpreters = true
[packages-deps]
deps =
aiohttp<4.0.0,>=3.8.5
hypothesis==6.151.9
numpy>=1.18.1
openapi-core==0.22.0
openapi-spec-validator<0.8.0,>=0.7.0
asn1crypto<1.5.0,>=1.4.0
ecdsa>=0.19.2,<0.20
tomte[tests]==0.7.0
[tests-common]
deps =
{[packages-deps]deps}
docker==7.1.0
pexpect==4.8.0
GitPython<4.0.0,>=3.1.47
packaging>=22.0,<27
protobuf<7,>=5
requests>=2.32.5,<3
mistune==2.0.3
tomte[isort]==0.7.0
tomte[black]==0.7.0
tomte[tests]==0.7.0
; Plugin dependencies. We need this
; because we use --no-deps to install the plugins.
; aea_ledger_cosmos/aea_ledger_fetchai
ecdsa>=0.19.2,<0.20
asn1crypto<1.5.0,>=1.4.0
bech32>=1.2.0,<2
; aea_ledger_ethereum
web3<8,>=7.0.0
eth-account>=0.13.0,<0.14.0
; for password encryption in cosmos
pycryptodome>=3.10.1,<4.0.0
cosmpy<0.12,>=0.11.0
certifi<=2022.6.15.1
google-api-python-client<=2.60.0
idna<=3.3
numpy>=1.18.1
psutil>=5.7.0,<6.0.0
setuptools==59.6.0
ledgerwallet==0.1.3
defusedxml==0.6.0
[extra-deps]
deps =
memory-profiler==0.57.0
multidict
pytest-asyncio
werkzeug
; end-extra
[testenv]
basepython = python3.10
allowlist_externals = /bin/sh
passenv = *
extras = all
deps =
setuptools==59.6.0
[commands-local-install]
commands =
pip install {toxinidir}[all]
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-ethereum
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-cosmos
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-fetchai
python -m pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
python -m pip install --no-deps {toxinidir}/plugins/aea-ci-helpers
[test-framework]
deps =
{[tests-common]deps}
commands =
; for some reason tox installs aea without respect to the dependencies version specified in seetup.py. at least in CI env
; so install current aea in a normal way
{[commands-local-install]commands}
pytest -rfE --doctest-modules aea tests/ --durations=0 --cov=aea --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov-config=.coveragerc --cov-append {posargs}
[test-packages]
deps =
{[tests-common]deps}
commands =
; for some reason tox installs aea without respect to the dependencies version specified in setup.py. at least in CI env
; so install current aea in a normal way
{[commands-local-install]commands}
aea test --cov --append packages --durations=0 {posargs}
[test-plugins]
deps =
{[tests-common]deps}
pytest-custom-exit-code==0.3.0
hexbytes==1.3.1
commands =
{[commands-local-install]commands}
pytest -rfE plugins/aea-ledger-fetchai/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_ledger_fetchai --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
pytest -rfE plugins/aea-ledger-ethereum/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_ledger_ethereum --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
pytest -rfE plugins/aea-ledger-cosmos/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_ledger_cosmos --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
pytest -rfE plugins/aea-cli-ipfs/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_cli_ipfs --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
pytest -rfE plugins/aea-ci-helpers/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_ci_helpers --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-ethereum-hwi
pytest -rfE plugins/aea-ledger-ethereum-hwi/tests --durations=0 --cov-report=html --cov-report=xml --cov-report=term --cov-report=term-missing --cov=aea_ledger_ethereum_hwi --cov-config=.coveragerc --suppress-no-test-exit-code --cov-append {posargs}
[testenv:py3.10]
basepython = python3.10
usedevelop = True
deps = {[test-framework]deps}
commands = {[test-framework]commands}
[testenv:packages-py3.10]
basepython = python3.10
deps = {[test-packages]deps}
commands = {[test-packages]commands}
[testenv:plugins-py3.10]
basepython = python3.10
usedevelop = True
deps = {[test-plugins]deps}
commands = {[test-plugins]commands}
; Since the ledgerwallet still uses protobufs compiled using protoc<=3.20
setenv =
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
[testenv:py3.11]
basepython = python3.11
usedevelop = True
deps = {[test-framework]deps}
commands = {[test-framework]commands}
[testenv:packages-py3.11]
basepython = python3.11
deps = {[test-packages]deps}
commands = {[test-packages]commands}
[testenv:plugins-py3.11]
basepython = python3.11
usedevelop = True
deps = {[test-plugins]deps}
commands = {[test-plugins]commands}
; Since the ledgerwallet still uses protobufs compiled using protoc<=3.20
setenv =
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
[testenv:py3.12]
basepython = python3.12
usedevelop = True
deps = {[test-framework]deps}
commands = {[test-framework]commands}
[testenv:packages-py3.12]
basepython = python3.12
deps = {[test-packages]deps}
commands = {[test-packages]commands}
[testenv:plugins-py3.12]
basepython = python3.12
usedevelop = True
deps = {[test-plugins]deps}
commands = {[test-plugins]commands}
; Since the ledgerwallet still uses protobufs compiled using protoc<=3.20
setenv =
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
[testenv:py3.13]
basepython = python3.13
usedevelop = True
deps = {[test-framework]deps}
commands = {[test-framework]commands}
[testenv:packages-py3.13]
basepython = python3.13
deps = {[test-packages]deps}
commands = {[test-packages]commands}
[testenv:plugins-py3.13]
basepython = python3.13
usedevelop = True
deps = {[test-plugins]deps}
commands = {[test-plugins]commands}
; Since the ledgerwallet still uses protobufs compiled using protoc<=3.20
setenv =
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
[testenv:py3.14]
basepython = python3.14
usedevelop = True
deps = {[test-framework]deps}
commands = {[test-framework]commands}
[testenv:packages-py3.14]
basepython = python3.14
deps = {[test-packages]deps}
commands = {[test-packages]commands}
[testenv:plugins-py3.14]
basepython = python3.14
usedevelop = True
deps = {[test-plugins]deps}
commands = {[test-plugins]commands}
; Since the ledgerwallet still uses protobufs compiled using protoc<=3.20
setenv =
PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python
[testenv:bandit]
skipsdist = True
skip_install = True
deps =
tomte[bandit]==0.7.0
commands = bandit -c {envsitepackagesdir}/tomte/configs/bandit.yaml -r aea benchmark examples \
plugins/aea-ledger-fetchai/aea_ledger_fetchai \
plugins/aea-ledger-ethereum/aea_ledger_ethereum \
plugins/aea-ledger-cosmos/aea_ledger_cosmos \
plugins/aea-ledger-solana/aea_ledger_solana \
plugins/aea-cli-ipfs/aea_cli_ipfs
bandit -c {envsitepackagesdir}/tomte/configs/bandit.yaml -r packages
bandit -c {envsitepackagesdir}/tomte/configs/bandit.yaml -r tests scripts
[testenv:black]
skipsdist = True
skip_install = True
deps =
tomte[black]==0.7.0
commands = black aea benchmark examples packages plugins scripts tests --exclude ".*_pb2.py"
[testenv:black-check]
skipsdist = True
skip_install = True
deps =
tomte[black]==0.7.0
commands =black aea benchmark examples packages plugins scripts tests --check --verbose --exclude ".*_pb2.py"
[testenv:isort]
skipsdist = True
skip_install = True
deps =
tomte[isort,cli]==0.7.0
commands_pre = tomte render-isort-config --output={envtmpdir}/isort.cfg --known-first-party=aea --known-packages=packages --known-local-folder=tests
commands = isort --settings-path={envtmpdir}/isort.cfg aea benchmark examples packages plugins scripts tests
[testenv:isort-check]
skipsdist = True
skip_install = True
deps =
tomte[isort,cli]==0.7.0
commands_pre = tomte render-isort-config --output={envtmpdir}/isort.cfg --known-first-party=aea --known-packages=packages --known-local-folder=tests
commands = isort --check-only --verbose --settings-path={envtmpdir}/isort.cfg aea benchmark examples packages plugins scripts tests
[testenv:fix-copyright]
skipsdist = True
skip_install = True
deps =
tomte[cli]==0.7.0
commands = tomte format-copyright --author "Valory AG" --author "Fetch.AI Limited" --scan-path aea --scan-path packages/fetchai/agents --scan-path packages/fetchai/connections --scan-path packages/fetchai/contracts --scan-path packages/fetchai/skills --scan-path packages/valory/connections --scan-path packages/open_aea/agents --scan-path tests --scan-path plugins --scan-path scripts -e dummy_packages
[testenv:check-copyright]
skipsdist = True
skip_install = True
deps =
tomte[cli]==0.7.0
commands = tomte check-copyright --author "Valory AG" --author "Fetch.AI Limited" --scan-path aea --scan-path packages/fetchai/agents --scan-path packages/fetchai/connections --scan-path packages/fetchai/contracts --scan-path packages/fetchai/skills --scan-path packages/valory/connections --scan-path packages/open_aea/agents --scan-path tests --scan-path plugins --scan-path scripts -e dummy_packages
[testenv:hash-check]
skipsdist = True
usedevelop = True
commands =
pip install {toxinidir}[all]
python -m pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
aea packages lock --check
aea --registry-path=./tests/data/packages packages lock --check
[testenv:lock-packages]
skipsdist = True
usedevelop = True
commands =
pip install {toxinidir}[all]
python -m pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
aea packages lock
aea --registry-path=./tests/data/packages packages lock
python -m pip install --no-deps {toxinidir}/plugins/aea-ci-helpers
aea-ci generate-pkg-list
aea-ci check-doc-hashes --fix
[testenv:package-version-checks]
skipsdist = True
usedevelop = True
deps =
{toxinidir}{/}plugins{/}aea-ci-helpers
commands =
aea-ci check-pkg-versions
[testenv:package-dependencies-checks]
skipsdist = True
usedevelop = True
deps =
{[testenv]deps}
{[packages-deps]deps}
commands =
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-ethereum
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-cosmos
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-fetchai
python -m aea.cli check-packages
[testenv:docs]
skipsdist = True
skip_install = True
deps =
tomte[docs]==0.7.0
commands = pip3 install git+https://github.com/pugong/mkdocs-mermaid-plugin.git@abf1439#egg=mkdocs-mermaid-plugin
mkdocs build --clean
[testenv:docs-serve]
skipsdist = True
skip_install = True
deps =
tomte[docs]==0.7.0
commands = pip3 install git+https://github.com/pugong/mkdocs-mermaid-plugin.git@abf1439#egg=mkdocs-mermaid-plugin
mkdocs build --clean
python -c 'print("###### Starting local server. Press Control+C to stop server ######")'
mkdocs serve -a localhost:8080
[testenv:flake8]
allowlist_externals =
/bin/sh
/usr/bin/sh
skipsdist = True
skip_install = True
deps =
tomte[flake8]==0.7.0
# tomte ships the canonical [flake8] section. Per-repo extend-exclude
# and per-file-ignores must be passed as CLI flags: flake8's config-
# file `exclude` only matches basenames, so file-path overrides like
# `aea/__init__.py` are only honored via `--extend-exclude` on argv.
# Wrapped in sh -c so the long argument list reads as one command
# across multiple lines.
commands =
sh -c "flake8 \
--config={envsitepackagesdir}/tomte/configs/flake8.cfg \
--extend-exclude=aea/__init__.py,aea/cli/__init__.py,tests/common/oef_search_pluto_scripts,tests/common/click_testing.py,scripts/oef/launch.py \
'--per-file-ignores=tests/test_cli/test_upgrade.py:E800 tests/test_protocols/test_generator/test_end_to_end.py:E800,F401 tests/test_cli/test_launch_end_to_end.py:E800 **/aea_ledger_cosmos/cosmos.py:F401 **/aea_ledger_fetchai/_cosmos.py:F401' \
aea benchmark examples packages plugins scripts tests"
[testenv:liccheck]
skipsdist = True
usedevelop = True
deps =
setuptools==59.6.0
liccheck==0.6.0
tomte[cli]==0.7.0
commands = tomte freeze-dependencies --output-path {envtmpdir}/requirements.txt --exclude-package open-aea
liccheck -s strategy.ini -r {envtmpdir}/requirements.txt -l PARANOID
[testenv:mypy]
skipsdist = True
skip_install = True
deps =
tomte[mypy]==0.7.0
types-requests==2.33.0.20260408
{toxinidir}{/}plugins{/}aea-ci-helpers
commands = mypy --config-file=tox.ini aea packages --disallow-untyped-defs
mypy --config-file=tox.ini benchmark examples --disallow-untyped-defs
mypy --config-file=tox.ini scripts tests plugins/aea-ledger-fetchai/aea_ledger_fetchai plugins/aea-ledger-ethereum/aea_ledger_ethereum plugins/aea-ledger-cosmos/aea_ledger_cosmos plugins/aea-cli-ipfs/aea_cli_ipfs
[testenv:pylint]
allowlist_externals =
/bin/sh
/usr/bin/sh
skipsdist = True
deps =
tomte[pylint]==0.7.0
requests>=2.32.5,<3
urllib3==2.6.3
certifi<=2022.6.15.1
# tomte ships the canonical pylintrc; the repo-local pylintrc.local
# adds OAEA's [IMPORTS] ignored-modules. They concat cleanly because
# [IMPORTS] is not a section in tomte's canonical. Two guards make
# both assumptions explicit: the grep fails the env if a future tomte
# release ships [IMPORTS] (otherwise pylint would silently keep only
# the last duplicate header); the printf injects a newline between
# the two files so the concat doesn't silently glue tomte's last
# line onto pylintrc.local's first if tomte's file lacks a trailing
# newline.
commands_pre =
sh -c "! grep -qE '^\[IMPORTS\]' {envsitepackagesdir}/tomte/configs/pylintrc || { echo 'tomte pylintrc now ships [IMPORTS]; reconcile pylintrc.local' >&2; exit 1; }"
sh -c "{ cat {envsitepackagesdir}/tomte/configs/pylintrc; printf '\n'; cat {toxinidir}/pylintrc.local; } > {envtmpdir}/pylintrc"
commands =
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-ethereum
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-cosmos
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-fetchai
python -m pip install --no-deps {toxinidir}/plugins/aea-ledger-solana
python -m pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
sh -c "pylint \
--rcfile={envtmpdir}/pylintrc \
--ignore-patterns=__main__.py,.*_pb2.py,tac.sh,tac_local.sh \
aea benchmark packages \
plugins/aea-ledger-fetchai/aea_ledger_fetchai \
plugins/aea-ledger-ethereum/aea_ledger_ethereum \
plugins/aea-ledger-cosmos/aea_ledger_cosmos \
plugins/aea-cli-ipfs/aea_cli_ipfs \
scripts examples/*"
[testenv:safety]
skipsdist = True
skip_install = True
deps =
tomte[safety]==0.7.0
typer==0.16.0
commands = safety check --policy-file {envsitepackagesdir}/tomte/configs/safety-policy.yml
[testenv:vulture]
skipsdist = True
skip_install = True
deps =
tomte[vulture]==0.7.0
commands = vulture aea scripts/whitelist.py --exclude "*_pb2.py"
[testenv:darglint]
skipsdist = True
skip_install = True
deps =
tomte[darglint]==0.7.0
commands = darglint aea benchmark examples libs packages plugins scripts
[testenv:gitleaks]
skipsdist = True
skip_install = True
deps =
tomte[cli]==0.7.0
allowlist_externals = gitleaks
# Matches the gitleaks CI job: full git-history scan with verbose
# output, using tomte's canonical config.
commands = gitleaks detect --config={envsitepackagesdir}/tomte/configs/gitleaks.toml -v
[testenv:fix-doc-hashes]
skipsdist = True
usedevelop = True
deps =
pip
{toxinidir}{/}plugins{/}aea-ci-helpers
commands =
aea-ci generate-pkg-list
aea-ci check-doc-hashes --fix
[testenv:check-doc-links-hashes]
skipsdist = True
usedevelop = True
deps =
pip
setuptools==59.6.0
tomte[cli]==0.7.0
{toxinidir}{/}plugins{/}aea-ci-helpers
commands =
tomte check-doc-links \
-u "https://faucet.dimensions.network/" \
-u "https://www.cs.ox.ac.uk/people/michael.wooldridge/" \
-u "https://multiformats.io/multiaddr/" \
-u "https://github.com/MarcoFavorito" \
-u "https://github.com/valory-xyz/open-aea/branches/main/deploy-image" \
-u "https://explore-stargateworld.fetch.ai/" \
-u "https://explore-dorado.fetch.ai" \
-u "https://rest-dorado.fetch.ai:443" \
-u "https://www.python.org/dev/peps/pep-0426/name" \
-u "https://bugs.python.org/issue8296" \
-u "https://rpc1.example.com" -u "https://rpc2.example.com" \
-u "https://github.com/LedgerHQ/apduboy/blob/master/apduboy/lib/bip32.py" \
-u "https://docs.optimism.io/builders/app-developers/transactions/estimates" \
-u "https://docs.optimism.io/builders/app-developers/transactions/estimates\#l1-data-fee" \
; http://www.fipa.org is both HTTP-only and unreachable, so it
; needs BOTH skips: -u (url-skips) suppresses the reachability
; check, -n (http-skips) suppresses the "use HTTPS" check. Both
; checks are independently fatal in tomte, so dropping either
; re-reds the lane.
-u "http://www.fipa.org" \
-n "http://www.fipa.org" \
; go.dev/dl/ times out intermittently on CI runners
-u "https://go.dev/dl/"
aea-ci check-doc-hashes
aea-ci generate-pkg-list --check
aea-ci check-ipfs-pushed
[testenv:generate-all-protocols]
skipsdist = True
usedevelop = True
deps =
tomte[isort]==0.7.0
tomte[black]==0.7.0
commands = pip install {toxinidir}[all]
pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
aea generate-all-protocols
aea generate-all-protocols tests/data/packages
[testenv:check-generate-all-protocols]
skipsdist = True
usedevelop = True
deps =
tomte[isort]==0.7.0
tomte[black]==0.7.0
commands = pip install {toxinidir}[all]
python -m pip install --no-deps {toxinidir}/plugins/aea-cli-ipfs
aea generate-all-protocols --check-clean
aea generate-all-protocols tests/data/packages --check-clean
[testenv:dependencies-check]
skipsdist = True
skip_install = True
deps =
pip
setuptools==59.6.0
{toxinidir}{/}plugins{/}aea-ci-helpers
allowlist_externals = pip
commands =
pip install {toxinidir}[all]
pip uninstall open-aea -y
aea-ci check-imports
[testenv:plugins_env]
skipsdist = True
skip_install = True
passenv = *
deps = .[all]
allowlist_externals = sh
/bin/sh
/usr/bin/sh
commands =
- /bin/sh -c "rm -fr ./*private_key.txt"
{posargs}
[testenv:check-api-docs]
skipsdist = True
usedevelop = True
deps =
tomte[docs]==0.7.0
docspec==2.2.1
docspec-python==2.2.1
{toxinidir}{/}plugins{/}aea-ci-helpers
commands =
aea-ci generate-api-docs --check
[testenv:generate-api-documentation]
skipsdist = True
usedevelop = True
deps =
tomte[docs]==0.7.0
docspec==2.2.1
docspec-python==2.2.1
{toxinidir}{/}plugins{/}aea-ci-helpers
commands =
aea-ci generate-api-docs
[testenv:update-dependencies]
deps =
{toxinidir}{/}plugins{/}aea-ci-helpers
commands = aea-ci check-dependencies
[testenv:check-dependencies]
deps =
{toxinidir}{/}plugins{/}aea-ci-helpers
commands = aea-ci check-dependencies --check
; -- mypy config -----------------------------------------------------------
; Mypy reads `[mypy*]` sections from any ini file. Per-package overrides
; live here in tox.ini (not pyproject.toml) so `[testenv:mypy]` can pass
; `--config-file=tox.ini` and pick everything up; mypy does not auto-
; discover from pyproject.toml when an explicit config file is given.
[mypy]
python_version = 3.10
strict_optional = True
exclude = contract_api/tests/test_contract_api.py|fipa/tests/test_fipa.py|default/tests/test_default.py|http/tests/test_http.py|ledger_api/tests/test_ledger_api.py|oef_search/tests/test_oef_search.py|state_update/tests/test_state_update.py|tac/tests/test_tac.py|erc1155/tests/test_contract.py|erc1155_deploy/tests/test_behaviours.p|erc1155_deploy/tests/test_dialogues.py|erc1155_deploy/tests/test_handlers.py|erc1155_deploy/tests/test_handlers.py|erc1155_deploy/tests/test_strategy.py|erc1155_client/tests/test_behaviours.py|erc1155_client/tests/test_handlers.py|erc1155_client/tests/test_dialogues.py|erc1155_client/tests/test_strategy.py|generic_buyer/tests/test_handlers.py|generic_buyer/tests/test_behaviours.py|generic_buyer/tests/test_dialogues.py|generic_buyer/tests/test_models.py|erc1155_deploy/tests/intermediate_class.py|generic_seller/tests/test_handlers.py|generic_seller/tests/test_models.py|generic_seller/tests/test_dialogues.py|generic_seller/tests/test_behaviours.py|ledger/tests/test_ledger_api.py|local/tests/test_search_services.py|echo/tests/test_handlers.py|http_echo/tests/test_dialogues.py|http_client/tests/test_http_client.py|http_server/tests/test_http_server.py|echo/tests/test_dialogues.py|echo/tests/test_behaviours.py|local/tests/test_misc.py|signing/tests/test_signing.py|tendermint/tests/test_tendermint.py|stub/tests/test_stub.py|ledger/tests/conftest.py|erc1155_client/tests/intermediate_class.py|acn/tests/test_acn.py|packages/valory/connections/test_libp2p
[mypy-aea.mail.base_pb2]
ignore_errors = True
[mypy-aea.helpers.multiaddr.crypto_pb2]
ignore_errors = True
[mypy-aea.helpers.search.models_pb2]
ignore_errors = True
[mypy-packages.valory.protocols.ledger_api.serialization]
ignore_errors = True
[mypy-oef.*]
ignore_missing_imports = True
[mypy-eth_keys.*]
ignore_missing_imports = True
[mypy-connexion]
ignore_missing_imports = True
[mypy-eth_account.*]
ignore_missing_imports = True
[mypy-aea.helpers.ipfs.pb.unixfs_pb2]
ignore_errors = True
[mypy-aea.helpers.ipfs.pb.merkledag_pb2]
ignore_errors = True
[mypy-win32con.*]
ignore_missing_imports = True
[mypy-win32file.*]
ignore_missing_imports = True
[mypy-pywintypes.*]
ignore_missing_imports = True
[mypy-urllib3.*]
ignore_missing_imports = True
[mypy-aea_ledger_fetchai.*]
ignore_missing_imports = True
[mypy-aea_ledger_ethereum.*]
ignore_missing_imports = True
[mypy-aea_ledger_cosmos.*]
ignore_missing_imports = True
[mypy-aea_ledger_solana.*]
ignore_missing_imports = True
[mypy-numpy]
ignore_missing_imports = True
[mypy-pytest]
ignore_missing_imports = True
[mypy-pytest_asyncio]
ignore_missing_imports = True
[mypy-docker.*]
ignore_missing_imports = True
[mypy-tests.data.generator.t_protocol.*]
ignore_errors = True
[mypy-tests.data.generator.t_protocol_no_ct.*]
ignore_errors = True
[mypy-tests.data.dummy_aea.vendor.*]
ignore_errors = True
[mypy-mistune]
ignore_missing_imports = True
[mypy-git.*]
ignore_missing_imports = True
[mypy-packaging.*]
ignore_missing_imports = True
[mypy-aiohttp.*]
ignore_missing_imports = True
[mypy-multidict.*]
ignore_missing_imports = True
[mypy-web3.*]
ignore_missing_imports = True
[mypy-packages.fetchai.protocols.contract_api.contract_api_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.default.default_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.fipa.fipa_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.http.http_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.ledger_api.ledger_api_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.oef_search.oef_search_pb2]
ignore_errors = True
[mypy-packages.open_aea.protocols.signing.signing_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.state_update.state_update_pb2]
ignore_errors = True
[mypy-packages.fetchai.protocols.tac.tac_pb2]
ignore_errors = True
[mypy-packages.valory.protocols.acn.acn_pb2]
ignore_errors = True
[mypy-packages.valory.protocols.tendermint.tendermint_pb2]
ignore_errors = True
[mypy-tests.data.packages.fetchai.protocols.t_protocol.t_protocol_pb2]
ignore_errors = True
[mypy-tests.data.packages.fetchai.protocols.t_protocol_no_ct.t_protocol_no_ct_pb2]
ignore_errors = True
[mypy-tests.data.packages.fetchai.protocols.t_protocol.serialization]
ignore_errors = True
[mypy-tests.data.packages.fetchai.protocols.t_protocol_no_ct.serialization]
ignore_errors = True
[mypy-tensorflow.*]
ignore_missing_imports = True
[mypy-temper.*]
ignore_missing_imports = True
[mypy-openapi_core.*]
ignore_missing_imports = True
[mypy-openapi_spec_validator.*]
ignore_missing_imports = True
[mypy-sqlalchemy]
ignore_missing_imports = True
[mypy-defusedxml.*]
ignore_missing_imports = True
[mypy-cosmpy.*]
ignore_missing_imports = True
[mypy-google.*]
ignore_missing_imports = True
[mypy-click.*]
ignore_missing_imports = True
[mypy-yaml.*]
ignore_missing_imports = True
[mypy-certifi.*]
ignore_missing_imports = True
[mypy-werkzeug.*]
ignore_missing_imports = True
[mypy-pkg_resources.*]
ignore_missing_imports = True
[mypy-rl.*]
ignore_missing_imports = True
[mypy-coverage.*]
ignore_missing_imports = True
[mypy-Crypto.*]
ignore_missing_imports = True
[mypy-eth_typing.*]
ignore_missing_imports = True
[mypy-bech32.*]
ignore_missing_imports = True
[mypy-eth_utils.*]
ignore_missing_imports = True
[mypy-_strptime.*]
ignore_missing_imports = True
[mypy-hypothesis.*]
ignore_missing_imports = True
[mypy-hexbytes.*]
ignore_missing_imports = True
[mypy-asyncio.*]
ignore_missing_imports = True
[mypy-toml.*]
ignore_missing_imports = True
[mypy-attr.*]
ignore_missing_imports = True
[mypy-ecdsa.*]
ignore_missing_imports = True
; -- darglint config -------------------------------------------------------
; Darglint doesn't read pyproject.toml — it reads .darglint / setup.cfg /
; tox.ini in that order, so settings live here.
[darglint]
docstring_style = sphinx
strictness = short
ignore_regex = .*_pb2\.py
ignore = DAR401