Skip to content

Commit

Permalink
Dependencies Update (#660)
Browse files Browse the repository at this point in the history
* Dependencies Update

* Build fixes to work around pip-tools problems.
  • Loading branch information
Paul Prescod authored May 12, 2022
1 parent 1d1f370 commit fff7c66
Show file tree
Hide file tree
Showing 7 changed files with 72 additions and 66 deletions.
9 changes: 5 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
run: |
python -VV
python -m pip install --upgrade pip
make dev-install
pip install -r requirements_dev.txt
- name: "Run tox targets for ${{ matrix.python-version }}"
run: python -m tox
Expand All @@ -51,7 +51,7 @@ jobs:
run: |
python -VV
python -m pip install --upgrade pip
make dev-install
pip install -r requirements_dev.txt
python -m pip install cumulusci
- name: Run Tests
Expand All @@ -69,7 +69,8 @@ jobs:
- name: Install dependencies
run: |
python -VV
make dev-install
pip install -r requirements_dev.txt
# docs build requires a proper install
python setup.py install
- name: Make Docs
Expand Down Expand Up @@ -116,7 +117,7 @@ jobs:
run: |
python -VV
python -m pip install --upgrade pip
make dev-install
pip install -r requirements_dev.txt
- name: Run Tests
run: python -m pytest
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/extra-checks-after-pull-request-review.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,8 @@ jobs:
- name: Install dependencies
run: |
python -VV
make dev-install
pip install -r requirements_dev.txt
# docs build requires a proper install
python setup.py install
- name: Make Docs
Expand Down
2 changes: 1 addition & 1 deletion requirements/dev.in
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
black
coverage
coveralls
mkdocs
mkdocs<1.3.0 # need to change Snowfakery monkey-patching before upgrade
mkdocs-exclude-search
pre-commit
pytest
Expand Down
87 changes: 42 additions & 45 deletions requirements/dev.txt
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#
# This file is autogenerated by pip-compile
# This file is autogenerated by pip-compile with python 3.9
# To update, run:
#
# pip-compile --allow-unsafe requirements/dev.in
Expand All @@ -8,24 +8,24 @@ attrs==21.4.0
# via
# jsonschema
# pytest
black==22.1.0
black==22.3.0
# via -r requirements/dev.in
certifi==2021.10.8
# via
# -r requirements/prod.txt
# requests
cfgv==3.3.1
# via pre-commit
charset-normalizer==2.0.11
charset-normalizer==2.0.12
# via
# -r requirements/prod.txt
# requests
click==8.0.3
click==8.1.3
# via
# -r requirements/prod.txt
# black
# mkdocs
coverage[toml]==6.3
coverage[toml]==6.3.2
# via
# -r requirements/dev.in
# coveralls
Expand All @@ -36,61 +36,59 @@ distlib==0.3.4
# via virtualenv
docopt==0.6.2
# via coveralls
faker-microservice==2.0.0
# via -r requirements/dev.in
faker==12.0.0
faker==12.3.3
# via
# -r requirements/prod.txt
# faker-microservice
filelock==3.4.2
faker-microservice==2.0.0
# via -r requirements/dev.in
filelock==3.6.0
# via
# tox
# virtualenv
ghp-import==2.0.2
ghp-import==2.1.0
# via mkdocs
greenlet==1.1.2
# via
# -r requirements/prod.txt
# sqlalchemy
gvgen==1.0
# via -r requirements/prod.txt
identify==2.4.7
identify==2.5.0
# via pre-commit
idna==3.3
# via
# -r requirements/prod.txt
# requests
# yarl
importlib-metadata==4.10.1
importlib-metadata==4.11.3
# via
# markdown
# mkdocs
importlib-resources==5.4.0
# via
# jsonschema
# tox-gh-actions
importlib-resources==5.7.1
# via tox-gh-actions
iniconfig==1.1.1
# via pytest
jinja2==2.11.3
# via
# -r requirements/prod.txt
# mkdocs
jsonschema==4.4.0
jsonschema==4.5.1
# via -r requirements/dev.in
markdown==3.3.6
markdown==3.3.7
# via mkdocs
markupsafe==2.0.1
# via
# -r requirements/prod.txt
# jinja2
mergedeep==1.3.4
# via mkdocs
mkdocs-exclude-search==0.6.4
# via -r requirements/dev.in
mkdocs==1.2.3
mkdocs==1.2.4
# via
# -r requirements/dev.in
# mkdocs-exclude-search
mkdocs-exclude-search==0.6.4
# via -r requirements/dev.in
multidict==6.0.2
# via yarl
mypy-extensions==0.4.3
Expand All @@ -104,91 +102,90 @@ packaging==21.3
# tox
pathspec==0.9.0
# via black
platformdirs==2.4.1
platformdirs==2.5.2
# via
# black
# virtualenv
pluggy==1.0.0
# via
# pytest
# tox
pre-commit==2.17.0
pre-commit==2.19.0
# via -r requirements/dev.in
py==1.11.0
# via
# pytest
# tox
pydantic==1.9.0
# via -r requirements/prod.txt
pyparsing==3.0.7
pyparsing==3.0.9
# via packaging
pyrsistent==0.18.1
# via jsonschema
pytest-cov==3.0.0
# via -r requirements/dev.in
pytest-vcr==1.0.2
# via -r requirements/dev.in
pytest==6.2.5
pytest==7.1.2
# via
# -r requirements/dev.in
# pytest-cov
# pytest-vcr
pytest-cov==3.0.0
# via -r requirements/dev.in
pytest-vcr==1.0.2
# via -r requirements/dev.in
python-baseconv==1.2.2
# via -r requirements/prod.txt
python-dateutil==2.8.2
# via
# -r requirements/prod.txt
# faker
# ghp-import
pyyaml-env-tag==0.1
# via mkdocs
pyyaml==6.0
# via
# -r requirements/prod.txt
# mkdocs
# pre-commit
# pyyaml-env-tag
# vcrpy
pyyaml-env-tag==0.1
# via mkdocs
requests==2.27.1
# via
# -r requirements/prod.txt
# coveralls
# responses
responses==0.17.0
responses==0.20.0
# via -r requirements/dev.in
six==1.16.0
# via
# -r requirements/prod.txt
# python-dateutil
# responses
# tox
# vcrpy
# virtualenv
sqlalchemy==1.4.31
sqlalchemy==1.4.36
# via -r requirements/prod.txt
toml==0.10.2
# via
# pre-commit
# pytest
# tox
tomli==2.0.0
tomli==2.0.1
# via
# black
# coverage
tox-gh-actions==2.9.1
# via -r requirements/dev.in
tox==3.24.5
# pytest
tox==3.25.0
# via
# -r requirements/dev.in
# tox-gh-actions
tox-gh-actions==2.9.1
# via -r requirements/dev.in
typeguard==2.10.0
# via -r requirements/dev.in
typing-extensions==4.0.1
typing-extensions==4.2.0
# via
# -r requirements/prod.txt
# black
# pydantic
urllib3==1.26.8
urllib3==1.26.9
# via
# -r requirements/prod.txt
# requests
Expand All @@ -197,17 +194,17 @@ vcrpy==4.1.1
# via
# -r requirements/dev.in
# pytest-vcr
virtualenv==20.13.0
virtualenv==20.14.1
# via
# pre-commit
# tox
watchdog==2.1.6
watchdog==2.1.7
# via mkdocs
wrapt==1.13.3
wrapt==1.14.1
# via vcrpy
yarl==1.7.2
# via vcrpy
zipp==3.7.0
zipp==3.8.0
# via
# importlib-metadata
# importlib-resources
3 changes: 3 additions & 0 deletions requirements/prod.in
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
SQLAlchemy
# Remove this when Faker/Docs building issue is cleared up.
Faker
jinja2<3 # until CCI is compatible
PyYAML
Expand All @@ -8,3 +9,5 @@ gvgen
pydantic
python-baseconv
requests
# This whole line should be deleted when Jinja and MarkupSafe are compatible:
MarkupSafe<2.1.0
18 changes: 10 additions & 8 deletions requirements/prod.txt
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
#
# This file is autogenerated by pip-compile
# This file is autogenerated by pip-compile with python 3.9
# To update, run:
#
# pip-compile --allow-unsafe requirements/prod.in
#
certifi==2021.10.8
# via requests
charset-normalizer==2.0.11
charset-normalizer==2.0.12
# via requests
click==8.0.3
click==8.1.3
# via -r requirements/prod.in
faker==12.0.0
faker==12.3.3
# via -r requirements/prod.in
greenlet==1.1.2
# via sqlalchemy
Expand All @@ -21,7 +21,9 @@ idna==3.3
jinja2==2.11.3
# via -r requirements/prod.in
markupsafe==2.0.1
# via jinja2
# via
# -r requirements/prod.in
# jinja2
pydantic==1.9.0
# via -r requirements/prod.in
python-baseconv==1.2.2
Expand All @@ -36,9 +38,9 @@ requests==2.27.1
# via -r requirements/prod.in
six==1.16.0
# via python-dateutil
sqlalchemy==1.4.31
sqlalchemy==1.4.36
# via -r requirements/prod.in
typing-extensions==4.0.1
typing-extensions==4.2.0
# via pydantic
urllib3==1.26.8
urllib3==1.26.9
# via requests
16 changes: 9 additions & 7 deletions tools/faker_docs_utils/mkdocs_plugins/main_mkdocs_plugin.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,11 +2,9 @@
import sys
import os
from unittest.mock import patch
from functools import lru_cache
from logging import Logger

from mkdocs.plugins import BasePlugin
from faker.factory import Factory


class Plugin(BasePlugin):
Expand Down Expand Up @@ -35,12 +33,16 @@ def new_warning(self, *args, **kwargs):
logger_patch = patch("logging.Logger.warning", new=new_warning)

# speed up a critical function
lru_patch = patch(
"faker.factory.Factory._get_provider_class",
lru_cache(maxsize=10_000)(Factory._get_provider_class),
)
#
# Disabled due to Faker refactoring. After release can look into
# whether it is still needed.
#
# lru_patch = patch(
# "faker.factory.Factory._get_provider_class",
# lru_cache(maxsize=10_000)(Factory._get_provider_class),
# )

with sys_path_patch, lru_patch, logger_patch:
with sys_path_patch, logger_patch: # lru_patch,
from tools.faker_docs_utils.faker_markdown import (
generate_markdown_for_all_locales,
generate_markdown_for_fakers,
Expand Down

0 comments on commit fff7c66

Please sign in to comment.