Commit Graph

42 Commits

Author SHA1 Message Date
Takashi Kajinami 2cb9e99a03 Bump hacking
hacking 3.0.x is too old.

Change-Id: I0459d714c21fe00eb6d4bffff1a08321782362f4
2024-01-26 01:25:02 +09:00
Hervé Beraud e70a618f33 Bump bandit
Change-Id: I0bab40e92e00f15a6cade62867fd309d26c73aa2
2023-05-17 16:27:49 +02:00
Stephen Finucane 3400cc2871 Integrate mypy
oslo.context is pretty small and therefore easy to introduce mypy for.
Minimal type hints are added, along with tox targets to validate things.
We can build on these in the future if we'd like to.

Change-Id: Ie5ab9eedfc89654ac3aa635f4a3ad24409ad23b6
Signed-off-by: Stephen Finucane <stephenfin@redhat.com>
2022-01-25 15:00:32 +01:00
Hervé Beraud 3b6da997d6 Adding pre-commit
Introduced changes:
- pre-commit config and rules.
- Add pre-commit to pep8 gate, Flake8 is covered in the pre-commit hooks.
- Applying fixes for pre-commit compliance in all code.

Also commit hash will be used instead of version tags in pre-commit to
prevend arbitrary code from running in developer's machines.

pre-commit will be used to:
- trailing whitespace;
- Replaces or checks mixed line ending (mixed-line-ending);
- Forbid files which have a UTF-8 byte-order marker
  (check-byte-order-marker);
- Checks that non-binary executables have a proper
  shebang (check-executables-have-shebangs);
- Check for files that contain merge conflict strings
  (check-merge-conflict);
- Check for debugger imports and py37+ breakpoint()
  calls in python source (debug-statements);
- Attempts to load all yaml files to verify syntax (check-yaml);
- Run flake8 checks (flake8) (local)

For further details about tests please refer to:
https://github.com/pre-commit/pre-commit-hooks

Change-Id: I4473e5e96419e4da9c8922d5832249da23c61acd
Signed-off-by: Moisés Guimarães de Medeiros <moguimar@redhat.com>
2020-09-08 14:01:06 +02:00
Moisés Guimarães de Medeiros 37dea647ef Bump bandit version
This patch bumps bandit allowed version to >=1.6.0,<1.7.0 in order to
avoid the errors detailed here https://github.com/PyCQA/bandit/pull/393

Change-Id: I2e498fd13356f571acb905384206b4c97e6c5d92
Signed-off-by: Moisés Guimarães de Medeiros <moguimar@redhat.com>
2020-07-25 11:31:15 +02:00
zhangboye e43df8bb49 Fix hacking min version to 3.0.1
Change-Id: Icc7d4b4016e44edfc4750ab3be0f180d6fb55d52
2020-05-22 11:10:19 +08:00
Andreas Jaeger a943cd8fb3 Update hacking for Python3
The repo is Python 3 now, so update hacking to version 3.0 which
supports Python 3.

Change-Id: I447f5d69e6932b41878ff5d138b19b319038f6fb
2020-03-30 12:01:09 +00:00
Ben Nemec 016904f816 Cap Bandit below 1.6.0 and update Sphinx requirement
Bandit 1.6.0 accidentally changed how the exclusion list option is
handled and breaks our use of it. Cap to the previous version until
Bandit has fixed the problem.

Sphinx 2.0 no longer works on python 2.7, so we need to start capping
it there as well.

Change-Id: Ib7f8df3fc5b83520b179d0a260c54e015c042b17
Reference: https://github.com/PyCQA/bandit/pull/489
2019-05-13 18:02:21 +00:00
ZhijunWei f3f1b88226 Update hacking version
Change-Id: I15bccfb206275218739227d784aa88a298f11017
2019-01-25 02:05:37 +00:00
Vu Cong Tuan 4abd5377e4 Switch to stestr
According to Openstack summit session [1],
stestr is maintained project to which all Openstack projects should migrate.
Let's switch to stestr as other projects have already moved to it.

[1] https://etherpad.openstack.org/p/YVR-python-pti

Change-Id: Ic863da849df2a728ce6b26bfd946262a5439fcad
2018-07-04 08:30:19 +07:00
OpenStack Proposal Bot d71d5abac6 Updated from global requirements
Change-Id: Ide21671b1374f761f8b95aa189b7c403a2488263
2018-01-16 04:26:42 +00:00
ChangBo Guo(gcb) f0dd124daa Follow the new PTI for document build
For compliance with the Project Testing Interface as described in:

https://governance.openstack.org/tc/reference/project-testing-interface.html

For more detials information, please refer to:

http://lists.openstack.org/pipermail/openstack-dev/2017-December/125710.html

Change-Id: I9d23ea7b5731fb677b2b1a09cdec74a1101dcd2c
2017-12-19 19:00:49 +08:00
ChangBo Guo(gcb) c7a2b56c4f add bandit to pep8 job
Add the bandit security scanner to the pep8 job.

Change-Id: Ie418ecadcff9351a776ff790492c73225efddb6f
2017-11-30 11:12:43 +08:00
OpenStack Proposal Bot 8c7a18fc55 Updated from global requirements
Change-Id: I29406d9fb7b8a309970b287a7fac8788beeeafd2
2017-09-20 16:22:52 +00:00
OpenStack Proposal Bot b1bbc6906c Updated from global requirements
Change-Id: Ibeb06d99a868cdc6655011a274cfc744f6398ea4
2017-08-18 11:39:55 +00:00
OpenStack Proposal Bot 03ddf2ce65 Updated from global requirements
Change-Id: Ie060bb41688c9c75139332fd01f5f59a65ed7d35
2017-07-27 19:19:27 +00:00
Van Hung Pham 3ce185402e Switch from oslosphinx to openstackdocstheme
As part of the docs migration work[0] for Pike we need to switch to use
the openstackdocstheme.

[0]https://review.openstack.org/#/c/472275/

Change-Id: I2ac1a1b9899b8bcb939fb287f09e7c69caca7fc9
2017-06-29 10:40:24 +07:00
OpenStack Proposal Bot bfb9ec786b Updated from global requirements
Change-Id: I3a8c5b11bfcf882f978331e9ec8f1a376607ffbf
2017-06-27 12:20:02 +00:00
OpenStack Proposal Bot e23339728a Updated from global requirements
Change-Id: I7fb240668a278d587141591b76d95e1d2b6e1065
2017-06-02 22:05:08 +00:00
OpenStack Proposal Bot f147f09961 Updated from global requirements
Change-Id: I21f20cab7a33ac3ba5684f8305de4b21f0f4af64
2017-05-17 03:56:29 +00:00
OpenStack Proposal Bot a6f994bcbd Updated from global requirements
Change-Id: Ie684a8605cb9ec6810e84b9651670da05a0f5c93
2017-05-15 00:52:45 +00:00
OpenStack Proposal Bot be7b1bf331 Updated from global requirements
Change-Id: I3c2534e4b628ba7666dd68a626d03a7287ed881e
2017-03-03 03:06:56 +00:00
ricolin c6e995323e [Fix gate]Update test requirement
Since pbr already landed and the old version of hacking seems not
work very well with pbr>=2, we should update it to match global
requirement.
Partial-Bug: #1668848

Change-Id: I2fbdd6f472704d5e1c6f8cf1c2ac5b09ea05aead
2017-03-02 18:28:24 +08:00
OpenStack Proposal Bot ad51df8640 Updated from global requirements
Change-Id: Ifd9ce0d91f508212139246852737e674ab1bb6bf
2017-02-10 05:57:33 +00:00
OpenStack Proposal Bot a6f104109d Updated from global requirements
Change-Id: I7e241be9655cb6f31773482702006a5020c312cf
2016-11-02 15:39:05 +00:00
OpenStack Proposal Bot 2bf8f2a1da Updated from global requirements
Change-Id: I6559df0df600a7edd9dbe874fddd37ff96004ee4
2016-10-22 01:25:54 +00:00
OpenStack Proposal Bot 91986c6b1d Updated from global requirements
Change-Id: I0fe18a8e19a52af3cbd0710889f89f1ea23242aa
2016-09-28 16:59:31 +00:00
OpenStack Proposal Bot 1bbe01652c Updated from global requirements
Change-Id: I5f65ecd8fb1ef72cf445bb1ef36bb57476cf7a63
2016-08-13 01:36:29 +00:00
Jamie Lennox 9e6c924040 Emit deprecation warnings when positional args passed
We should try and enforce that all arguments passed to an oslo_context
are passed as keyword arguments. positional is a library maintained by
the openstack community for exactly this.

We can't simply switch over to raising an error, so by setting
enforcement to warn we will issue a deprecation warning whenever
arguments are being passed positionally.

Change-Id: I47456ac65911d4cc4a5acbacfd1d0dae8429684a
2016-07-12 08:07:08 +10:00
OpenStack Proposal Bot 4db9262800 Updated from global requirements
Change-Id: I57bb582178a5cdb4a9ccc8c546129bdf3be44e07
2016-06-24 03:16:28 +00:00
Kirill Bespalov 061741287a Add reno for releasenotes management
An initial patch to add reno and create a base directory for
release notes

Change-Id: I8a18a2f2550ff82954d28a6e897a9ce9b1f8f1ba
2016-05-20 17:58:52 +03:00
OpenStack Proposal Bot ebf47d1a3d Updated from global requirements
Change-Id: Ibdd5af8eb5f29661a76cd5628381ec108e2e9c92
2016-01-16 03:31:07 +00:00
OpenStack Proposal Bot 73f2810749 Updated from global requirements
Change-Id: Ia351582a1a12fbf1268ad96f947d55f5551b81f5
2015-11-19 15:51:33 +00:00
OpenStack Proposal Bot 1513a0e37b Updated from global requirements
Change-Id: If8001b9baf0ef0e375a05420a305947748c9a2ba
2015-08-04 00:48:12 +00:00
OpenStack Proposal Bot 08e1f67004 Updated from global requirements
Change-Id: I610ee926687b666c1eaa6e7734bb90c8e8dfe8ea
2015-07-29 03:49:52 +00:00
OpenStack Proposal Bot e37501328f Updated from global requirements
Change-Id: Ib298c6c07d5ef21005345536297b67f3f1ce8c4f
2015-07-15 01:36:29 +00:00
OpenStack Proposal Bot dc4e7b10fe Updated from global requirements
Change-Id: I5dff4bb6ab3e959c393fa18c562bc1e2139878cc
2015-06-22 08:26:59 +00:00
Doug Hellmann 95c031d41b Uncap library requirements for liberty
Change-Id: Ib0fc2f1b538a38d057de355d317006a792ee574b
Depends-On: Ib948b756b8e6ca47a4c9c44c48031e54b7386a06
2015-04-16 18:02:15 +00:00
Doug Hellmann 2d6b2d6dd5 Update to latest hacking
Change-Id: I3e92326c01fba0c30fec7b7585ca9b56db500f9b
2015-04-03 13:57:40 +00:00
OpenStack Proposal Bot abfc021fcb Updated from global requirements
Change-Id: I4da5707598829b1d304e94b9bd83271ecef74c78
2015-03-26 11:00:56 +00:00
Davanum Srinivas e629730aa5 fix links and requirements to latest versions 2014-11-05 15:28:13 +01:00
Davanum Srinivas 885f545d81 exported from oslo-incubator by graduate.sh 2014-11-05 15:03:32 +01:00