Skip to content
This repository has been archived by the owner on Jun 7, 2024. It is now read-only.

Update charm libraries #27

Merged
merged 1 commit into from
Jul 5, 2023
Merged

Update charm libraries #27

merged 1 commit into from
Jul 5, 2023

Conversation

github-actions[bot]
Copy link
Contributor

@github-actions github-actions bot commented Jun 30, 2023

Automated action to fetch latest version of charm libraries. The branch of this PR
will be wiped during the next check. Unless you really know what you're doing, you
most likely don't want to push any commits to this branch.

@github-actions github-actions bot requested a review from a team as a code owner June 30, 2023 01:49
Copy link
Contributor

@gregory-schiano gregory-schiano left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions
Copy link
Contributor Author

github-actions bot commented Jul 3, 2023

Unit tests failed for caea33d

```

============================= test session starts ==============================
platform linux -- Python 3.10.6, pytest-7.4.0, pluggy-1.2.0 -- /opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/.tox/unit/bin/python
cachedir: .tox/unit/.pytest_cache
rootdir: /opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator
configfile: pyproject.toml
collecting ... collected 0 items / 1 error

==================================== ERRORS ====================================
________________________ ERROR collecting test session _________________________
Traceback (most recent call last):
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/.tox/unit/lib/python3.10/site-packages/_pytest/config/init.py", line 642, in _importconftest
mod = import_path(conftestpath, mode=importmode, root=rootpath)
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/.tox/unit/lib/python3.10/site-packages/_pytest/pathlib.py", line 565, in import_path
importlib.import_module(module_name)
File "/usr/lib/python3.10/importlib/init.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1050, in _gcd_import
File "", line 1027, in _find_and_load
File "", line 1006, in _find_and_load_unlocked
File "", line 688, in _load_unlocked
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/.tox/unit/lib/python3.10/site-packages/_pytest/assertion/rewrite.py", line 178, in exec_module
exec(co, module.dict)
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/tests/unit/conftest.py", line 15, in
from charm import FlaskCharm
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/src/charm.py", line 15, in
from charm_state import CharmState
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/src/charm_state.py", line 43, in
class FlaskConfig(BaseModel, extra=Extra.allow): # pylint: disable=too-few-public-methods
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/src/charm_state.py", line 66, in FlaskConfig
preferred_url_scheme: str | None = Field(None, regex="(?i)^(HTTP|HTTPS)$")
File "/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/.tox/unit/lib/python3.10/site-packages/pydantic/fields.py", line 707, in Field
raise PydanticUserError('regex is removed. use pattern instead', code='removed-kwargs')
pydantic.errors.PydanticUserError: regex is removed. use pattern instead

For further information visit https://errors.pydantic.dev/2.0/u/removed-kwargs
=============================== warnings summary ===============================
src/charm_state.py:43
/opt/github-runner/_work/flask-k8s-operator/flask-k8s-operator/src/charm_state.py:43: PydanticDeprecatedSince20: pydantic.config.Extra is deprecated, use literal values instead (e.g. extra='allow'). Deprecated in Pydantic V2.0 to be removed in V3.0. See Pydantic V2 Migration Guide at https://errors.pydantic.dev/2.0/migration/
class FlaskConfig(BaseModel, extra=Extra.allow): # pylint: disable=too-few-public-methods

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
=========================== short test summary info ============================
ERROR - pydantic.errors.PydanticUserError: regex is removed. use pattern instead
!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!
========================= 1 warning, 1 error in 0.34s ==========================

@github-actions
Copy link
Contributor Author

github-actions bot commented Jul 3, 2023

Test coverage for caea33d

Name                    Stmts   Miss Branch BrPart  Cover   Missing
-------------------------------------------------------------------
src/charm.py               96     88     12      0     7%   16-226
src/charm_state.py         82     63     10      1    22%   25, 68-292
src/charm_types.py          8      0      0      0   100%
src/constants.py            6      6      0      0     0%   4-10
src/databases.py           52     52     15      0     0%   4-153
src/exceptions.py           8      2      0      0    75%   20, 40
src/flask_app.py           16     16      8      0     0%   4-50
src/observability.py       12     12      0      0     0%   4-36
src/secret_storage.py      35     21      6      0    34%   29-31, 44-47, 58-62, 73-79, 87-88, 92-93
src/webserver.py           70     70     12      0     0%   4-163
-------------------------------------------------------------------
TOTAL                     385    330     63      1    12%
Coverage failure: total of 12 is less than fail-under=85

Static code analysis report

Run started:2023-07-03 11:58:52.761896

Test results:
  No issues identified.

Code scanned:
  Total lines of code: 1893
  Total lines skipped (#nosec): 1
  Total potential issues skipped due to specifically being disabled (e.g., #nosec BXXX): 0

Run metrics:
  Total issues (by severity):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
  Total issues (by confidence):
  	Undefined: 0
  	Low: 0
  	Medium: 0
  	High: 0
Files skipped (0):

@arturo-seijas arturo-seijas merged commit 688896a into main Jul 5, 2023
@arturo-seijas arturo-seijas deleted the chore/auto-libs branch July 5, 2023 08:53
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants