Commit Graph

33 Commits

Author SHA1 Message Date
Matthias Mair
abee2cee88
Code style improvements (#4683)
* fix list comps

* mopre comp fixes

* reduce computing cost on any() calls

* add bugbear

* check for clean imports

* only allow limited relative imports

* fix notification method lookup

* fix notification method assigement

* rewrite assigment

* fix upstream changes to new style

* fix upstream change to new coding style
2023-04-28 20:49:53 +10:00
Matthias Mair
f38386b13c
Add more checks to pre-commit (#3132)
* Add bandit to pre-commit checks

* fix catchall exceptions

* remove unused definitons

* remove unuseed ariables

* Add docstring

* fix B006, B008 errors

* fix B007 error

* ignore B009

* Add checks for formatting and naming
2022-06-06 08:56:52 +10:00
Matthias Mair
0c97a50e47
Docstring checks in QC checks (#3089)
* Add pre-commit to the stack

* exclude static

* Add locales to excludes

* fix style errors

* rename pipeline steps

* also wait on precommit

* make template matching simpler

* Use the same code for python setup everywhere

* use step and cache for python setup

* move regular settings up into general envs

* just use full update

* Use invoke instead of static references

* make setup actions more similar

* use python3

* refactor names to be similar

* fix runner version

* fix references

* remove incidential change

* use matrix for os

* Github can't do this right now

* ignore docstyle errors

* Add seperate docstring test

* update flake call

* do not fail on docstring

* refactor setup into workflow

* update reference

* switch to action

* resturcture

* add bash statements

* remove os from cache

* update input checks

* make code cleaner

* fix boolean

* no relative paths

* install wheel by python

* switch to install

* revert back to simple wheel

* refactor import export tests

* move setup keys back to not disturbe tests

* remove docstyle till that is fixed

* update references

* continue on error

* add docstring test

* use relativ action references

* Change step / job docstrings

* update to merge

* reformat comments 1

* fix docstrings 2

* fix docstrings 3

* fix docstrings 4

* fix docstrings 5

* fix docstrings 6

* fix docstrings 7

* fix docstrings 8

* fix docstirns 9

* fix docstrings 10

* docstring adjustments

* update the remaining docstrings

* small docstring changes

* fix function name

* update support files for docstrings

* Add missing args to docstrings

* Remove outdated function

* Add docstrings for the 'build' app

* Make API code cleaner

* add more docstrings for plugin app

* Remove dead code for plugin settings
No idea what that was even intended for

* ignore __init__ files for docstrings

* More docstrings

* Update docstrings for the 'part' directory

* Fixes for related_part functionality

* Fix removed stuff from merge 99676ee

* make more consistent

* Show statistics for docstrings

* add more docstrings

* move specific register statements to make them clearer to understant

* More docstrings for common

* and more docstrings

* and more

* simpler call

* docstrings for notifications

* docstrings for common/tests

* Add docs for common/models

* Revert "move specific register statements to make them clearer to understant"

This reverts commit ca96654622.

* use typing here

* Revert "Make API code cleaner"

This reverts commit 24fb68bd3e.

* docstring updates for the 'users' app

* Add generic Meta info to simple Meta classes

* remove unneeded unique_together statements

* More simple metas

* Remove unnecessary format specifier

* Remove extra json format specifiers

* Add docstrings for the 'plugin' app

* Docstrings for the 'label' app

* Add missing docstrings for the 'report' app

* Fix build test regression

* Fix top-level files

* docstrings for InvenTree/InvenTree

* reduce unneeded code

* add docstrings

* and more docstrings

* more docstrings

* more docstrings for stock

* more docstrings

* docstrings for order/views

* Docstrings for various files in the 'order' app

* Docstrings for order/test_api.py

* Docstrings for order/serializers.py

* Docstrings for order/admin.py

* More docstrings for the order app

* Add docstrings for the 'company' app

* Add unit tests for rebuilding the reference fields

* Prune out some more dead code

* remove more dead code

Co-authored-by: Oliver Walters <oliver.henry.walters@gmail.com>
2022-06-02 01:37:39 +10:00
Matthias Mair
799af89312 style fixes 2022-05-20 17:45:04 +02:00
Matthias Mair
fe4cbe0ad9
Merge branch 'master' into devOps 2022-05-19 18:28:15 +02:00
Oliver
80e3d0970a Adds unit tests for the samplepanel plugin 2022-05-19 11:28:18 +10:00
Matthias
3fd5761089
Merge branch 'master' of https://github.com/inventree/InvenTree into devOps 2022-05-18 23:39:58 +02:00
Matthias
545756eacb
add docstring testing 2022-05-16 01:20:04 +02:00
Matthias
af6eac8cc9
Add isort 2022-05-16 01:12:19 +02:00
Matthias
646107fee0
omit helpers from coverage 2022-03-13 20:09:54 +01:00
Matthias
fa865de073
add omittion 2022-03-13 19:44:51 +01:00
Matthias
8f06f5099c
fix reporting emition 2022-02-13 21:52:32 +01:00
Matthias
73500a4b82
omit coverage via setup.cfg 2022-02-13 21:19:41 +01:00
Matthias
c035cd4fc2
remove omitions
enforcing styles on the supporting files does not really hurt the dev enviroment - they already confirm
2021-11-23 00:44:56 +01:00
Matthias
0733d9940f
fix ci files 2021-11-23 00:42:21 +01:00
Matthias
92f0ca07d7
remove non existant file from checks 2021-11-23 00:39:12 +01:00
Matthias
68b8dcf19e
add todo 2021-11-23 00:37:17 +01:00
Matthias
aa845ce87d
add descriptions for all ignored errors 2021-11-23 00:36:44 +01:00
Matthias
3cd891229c
check rule W293 in pipeline 2021-11-23 00:29:02 +01:00
Matthias
c4700d0e10
move coverage settings into setup.cfg 2021-08-20 00:35:25 +02:00
Oliver Walters
75431f0ee4 Flake errors 2021-02-04 00:51:00 +11:00
Oliver Walters
ae7fbd6112 Add PEP8-naming extension for flake
- Enforcing python naming checks
2020-11-12 21:53:04 +11:00
Oliver Walters
b8856476be More CI file changes 2020-09-01 21:21:32 +10:00
Oliver Walters
beccbe8583 Flake fixes 2020-06-11 19:46:36 +10:00
Oliver Walters
7f269898c4 Flake - ignore media and static dirs 2020-03-22 20:02:13 +11:00
Oliver Walters
000229fcbb Ignore venv files for PEP checking 2019-12-05 23:05:28 +11:00
Oliver Walters
5567339e7a no message 2019-06-24 00:06:41 +10:00
Oliver Walters
faf2fd408f PEP fix 2019-06-24 00:01:34 +10:00
Oliver Walters
38001b5358 Peppy fixes 2019-06-13 22:16:27 +10:00
Oliver Walters
03eb6f7ef1 Exclude migration files from PEP 2019-05-02 17:44:01 +10:00
Oliver Walters
a3bbd5f8cb Increase allowed complexity 2019-04-25 21:09:02 +10:00
Oliver Walters
f9a54af9b1 Moved flake settings to setup.cfg 2019-04-25 20:59:41 +10:00
zakx
89e4cf899e Modernized environment 2017-04-10 22:55:25 +02:00