Skip to content

Commit

Permalink
Merge pull request #738 from hvac/develop
Browse files Browse the repository at this point in the history
Release v0.11.0
  • Loading branch information
jeffwecan committed Jul 12, 2021
2 parents 9505717 + e5a2e5b commit 0eca358
Show file tree
Hide file tree
Showing 150 changed files with 13,204 additions and 9,289 deletions.
2 changes: 1 addition & 1 deletion .bumpversion.cfg
@@ -1,5 +1,5 @@
[bumpversion]
current_version = 0.10.14
current_version = 0.11.0
commit = True
tag = True

Expand Down
1 change: 1 addition & 0 deletions .github/FUNDING.yml
@@ -0,0 +1 @@
ko_fi: jeffwecan
154 changes: 154 additions & 0 deletions .github/workflows/lint-and-test.yml
@@ -0,0 +1,154 @@
name: Lint and Test

on:
push:
branches:
- main
- develop
pull_request:
branches:
- main
- develop

jobs:
lint:
name: Lint
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- 3.6
- 3.7
- 3.8
- 3.9

steps:
- uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install `black` and `flake8`
run: |
pip install \
black \
flake8 \
;
- name: Check formatting with `black`
run: black --check .

- name: Lint with `flake8`
run: flake8 . --count --statistics

unit-tests:
name: Unit Tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- 3.6
- 3.7
- 3.8
- 3.9

steps:
- uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install Python dependencies
run: pip install -r requirements-dev.txt

- name: pytest tests/unit_tests
run: |
pytest \
--cov=hvac \
--cov-report=xml \
tests/unit_tests
- name: Upload unit tests coverage artifacts
uses: actions/upload-artifact@v2
with:
name: unit_tests-coverage.xml
path: coverage.xml
if-no-files-found: error

integration-tests:
name: Integration Tests
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- 3.6
vault-version:
- 1.4.7
- 1.5.9
- 1.6.5
- 1.7.2

steps:
- uses: actions/checkout@v2

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Install Python dependencies
run: pip install -r requirements-dev.txt

- name: Install Vault and Consul (for integration tests)
run: |
curl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add -
echo "deb [arch=amd64] https://apt.releases.hashicorp.com $(lsb_release -cs) main" \
| sudo tee /etc/apt/sources.list.d/hashicorp.list
sudo apt update \
-o Dir::Etc::sourceparts="-" \
-o APT::Get::List-Cleanup="0" \
-o Dir::Etc::sourcelist="sources.list.d/hashicorp.list"
sudo apt install \
consul \
vault-enterprise \
;
# We disble cap_ipc_lock here as its generally incompatabile with GitHub
# Actions' runtime environments.
sudo setcap cap_ipc_lock= /usr/bin/vault
- name: pytest tests/integration_tests
run: |
pytest \
--cov=hvac \
--cov-report=xml \
tests/integration_tests
- name: Upload integration tests coverage artifacts
uses: actions/upload-artifact@v2
with:
name: integration_tests-coverage.xml
path: coverage.xml
if-no-files-found: error

upload-to-codecov:
name: Upload to Codecov
runs-on: ubuntu-latest
needs:
- unit-tests
- integration-tests
steps:
- name: Checkout
uses: actions/checkout@v2

- name: Download artifacts
uses: actions/download-artifact@v2

- name: Upload to Codecov
uses: codecov/codecov-action@v1
42 changes: 0 additions & 42 deletions .github/workflows/python-package.yml

This file was deleted.

32 changes: 32 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,37 @@
# Changelog

## 0.11.0 (July 12th, 2021)

### 💥 Breaking Changes

- **Note**: This is intended to by the last hvac release supporting Python 2.7.

**_Starting with hvac version `1.0.0`, Python versions `>=3.6` will be the only explictly supported versions._**
- Userpass: Add `use_token` param on `login()`, Accept passthrough `**kwargs` on create user . GH-733

### 🚀 Features

- Support CA-related Environment Variables. GH-735
- Migrate Token Auth Methods to Dedicated Class. GH-734
- Allow Omission of Password Argument on Userpass `create_or_update_user()`. GH-714
- Add `token_ttl` & `token_max_ttl` Arguments to `ldap.configure()`. GH-707

### 🐛 Bug Fixes

- Fix Cert.login() handling of use_token argument. GH-720
- Use PUTs for AWS Secrets Engine STS Requests. GH-718

### 🧰 Miscellaneous

- Add deprecation notices for `Client()` k8s methods. GH-732
- Add deprecation notices for `Client()` approle methods. GH-731
- Deprecate AppID-related `Client()` Methods. GH-730
- Update Deprecated Usage In Documentation & Tests. GH-728
- Add `python_requires='>=2.7'` to setuptools Metadata. GH-727
- Transition to `black` Formatting + Updated PR Actions Workflow. GH-726

Thanks to @el-deano, @intgr, @jeffwecan, @pjaudiomv, @tp6783 and tyhess for their lovely contributions.

## 0.10.14 (May 21st, 2021)

### 🐛 Bug Fixes
Expand Down
2 changes: 1 addition & 1 deletion CONTRIBUTING.md
Expand Up @@ -18,7 +18,7 @@ pip install -e .
Integration tests will automatically start a Vault server in the background. Just make sure
the latest `vault` binary is available in your `PATH`.

1. [Install Vault](https://vaultproject.io/docs/install/index.html) or execute `tests/scripts/install-vault.sh`. Note: by default this script installs the OSS version of Vault. An enterprise trial version of the Vault binary is available for testing (but has an explicitly limited runtime). To run integration test cases requiring enterprise Vault, you can invoke the installation script with: `install-vault.sh <desired version> 'enterprise'`
1. [Install Vault](https://vaultproject.io/docs/install/index.html)
2. Install requirements

```
Expand Down
61 changes: 31 additions & 30 deletions docs/conf.py
Expand Up @@ -6,60 +6,61 @@
# Set up import path to allow the autodoc extension to find the local module code.
import os
import sys
sys.path.insert(0, os.path.abspath('..'))

sys.path.insert(0, os.path.abspath(".."))


# -- Project information -----------------------------------------------------

project = u'hvac'
copyright = u'2018-2020, Ian Unruh, Jeffrey Hogan'
author = u'Ian Unruh, Jeffrey Hogan'
project = u"hvac"
copyright = u"2018-2020, Ian Unruh, Jeffrey Hogan"
author = u"Ian Unruh, Jeffrey Hogan"

# The short X.Y version
version = '0.10.14'
version = "0.11.0"
# The full version, including alpha/beta/rc tags
release = '0.10.14'
release = "0.11.0"


# -- General configuration ---------------------------------------------------

extensions = [
'docs.ext.hvac_doctest',
'sphinx.ext.autodoc',
'sphinx.ext.coverage',
'sphinx.ext.viewcode',
'sphinx.ext.githubpages',
'm2r2',
'autodocsumm',
"docs.ext.hvac_doctest",
"sphinx.ext.autodoc",
"sphinx.ext.coverage",
"sphinx.ext.viewcode",
"sphinx.ext.githubpages",
"m2r2",
"autodocsumm",
]

# Add any paths that contain templates here, relative to this directory.
templates_path = ['_templates']
templates_path = ["_templates"]

source_suffix = ['.rst', '.md']
source_suffix = [".rst", ".md"]

# The master toctree document.
master_doc = 'index'
master_doc = "index"

language = None
exclude_patterns = [u'_build', 'Thumbs.db', '.DS_Store']
pygments_style = 'sphinx'
exclude_patterns = [u"_build", "Thumbs.db", ".DS_Store"]
pygments_style = "sphinx"


# -- Options for HTML output -------------------------------------------------

html_theme = 'sphinx_rtd_theme'
html_static_path = ['_static']
html_context = {'no_skippy': True}
html_theme = "sphinx_rtd_theme"
html_static_path = ["_static"]
html_context = {"no_skippy": True}
html_theme_options = {
# Toc options
'collapse_navigation': False,
"collapse_navigation": False,
}

# -- Options for HTMLHelp output ---------------------------------------------

# Output file base name for HTML help builder.
htmlhelp_basename = 'hvacdoc'
htmlhelp_basename = "hvacdoc"

# -- Options for Epub output -------------------------------------------------

Expand All @@ -70,13 +71,13 @@
epub_copyright = copyright

# A list of files that should not be packed into the epub file.
epub_exclude_files = ['search.html']
epub_exclude_files = ["search.html"]

# -- doctest configuration -------------------------------------------------
if os.getenv('READ_THE_DOCS_BUILD') is not None:
if os.getenv("READ_THE_DOCS_BUILD") is not None:
doctest_global_enabled = False

doctest_global_setup = '''
doctest_global_setup = """
import os
from pprint import pprint, pformat
Expand All @@ -93,17 +94,17 @@
manager, mocker = doctest_global_setup()
client = manager.client
'''
"""

doctest_global_cleanup = '''
doctest_global_cleanup = """
mocker.stop()
manager.stop()
'''
"""

# -- Autodoc configuration -------------------------------------------------

autodoc_default_options = {
'autosummary': True,
"autosummary": True,
}


Expand Down

0 comments on commit 0eca358

Please sign in to comment.