diff --git a/.circleci/config.yml b/.circleci/config.yml index eb10bbe3..b4b822ad 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -19,7 +19,7 @@ common: &common when: on_fail - restore_cache: keys: - - cache-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "tox.ini" }} + - cache-v1-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "tox.ini" }} - run: name: install dependencies command: pip install --user tox @@ -33,7 +33,7 @@ common: &common - ~/.cache/pip - ~/.local - ./eggs - key: cache-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "tox.ini" }} + key: cache-v1-{{ arch }}-{{ .Environment.CIRCLE_JOB }}-{{ checksum "setup.py" }}-{{ checksum "tox.ini" }} jobs: docs: diff --git a/.project-template/fill_template_vars.py b/.project-template/fill_template_vars.py index bbbe2f7f..52ceb02b 100644 --- a/.project-template/fill_template_vars.py +++ b/.project-template/fill_template_vars.py @@ -7,7 +7,7 @@ def _find_files(project_root): - path_exclude_pattern = r"\.git($|\/)|venv|_build|\.tox" + path_exclude_pattern = r"\.git($|\/)|venv|_build" file_exclude_pattern = r"fill_template_vars\.py|\.swp$" filepaths = [] for dir_path, _dir_names, file_names in os.walk(project_root): @@ -22,11 +22,14 @@ def _find_files(project_root): def _replace(pattern, replacement, project_root): print(f"Replacing values: {pattern}") for file in _find_files(project_root): - with open(file) as f: - content = f.read() - content = re.sub(pattern, replacement, content) - with open(file, "w") as f: - f.write(content) + try: + with open(file) as f: + content = f.read() + content = re.sub(pattern, replacement, content) + with open(file, "w") as f: + f.write(content) + except UnicodeDecodeError: + pass def main(): diff --git a/LICENSE b/LICENSE index 17bc694e..b76b24d4 100644 --- a/LICENSE +++ b/LICENSE @@ -1,6 +1,6 @@ The MIT License (MIT) -Copyright (c) 2020 The Ethereum Foundation +Copyright (c) 2019-2023 The Ethereum Foundation Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal diff --git a/README.md b/README.md index a3bc2c7c..86b1e410 100644 --- a/README.md +++ b/README.md @@ -1,9 +1,10 @@ # +[![Join the conversation on Discord](https://img.shields.io/discord/809793915578089484?color=blue&label=chat&logo=discord&logoColor=white)](https://discord.gg/GHryRvPB84) [![Build Status](https://circleci.com/gh/ethereum/.svg?style=shield)](https://circleci.com/gh/ethereum/) [![PyPI version](https://badge.fury.io/py/.svg)](https://badge.fury.io/py/) [![Python versions](https://img.shields.io/pypi/pyversions/.svg)](https://pypi.python.org/pypi/) -[![Docs build](https://readthedocs.org/projects//badge/?version=latest)](http://.readthedocs.io/en/latest/?badge=latest) +[![Docs build](https://readthedocs.org/projects//badge/?version=latest)](https://.readthedocs.io/en/latest/?badge=latest) diff --git a/docs/_static/.suppress-sphinx-build-warning b/docs/_static/.suppress-sphinx-build-warning deleted file mode 100644 index e69de29b..00000000 diff --git a/newsfragments/validate_files.py b/newsfragments/validate_files.py index 684c7987..c4bd29f6 100755 --- a/newsfragments/validate_files.py +++ b/newsfragments/validate_files.py @@ -3,7 +3,6 @@ # Towncrier silently ignores files that do not match the expected ending. # We use this script to ensure we catch these as errors in CI. -import os import pathlib import sys diff --git a/pytest.ini b/pytest.ini index ae90934f..95a6b2d6 100644 --- a/pytest.ini +++ b/pytest.ini @@ -1,6 +1,9 @@ [pytest] -addopts= -v --showlocals --durations 10 +addopts= -v --showlocals --durations 10 xfail_strict=true +log_format = %(levelname)8s %(asctime)s %(filename)20s %(message)s +log_date_format = %m-%d %H:%M:%S +timeout = 300 [pytest-watch] runner= pytest --failed-first --maxfail=1 --no-success-flaky-report diff --git a/setup.py b/setup.py index a18d9bc4..c359d0be 100644 --- a/setup.py +++ b/setup.py @@ -11,11 +11,11 @@ "pytest-xdist>=2.4.0", ], "lint": [ - "flake8==6.0.0", - "flake8-bugbear==23.3.23", + "flake8==6.0.0", # flake8 claims semver but adds new warnings at minor releases, leave it pinned. + "flake8-bugbear==23.3.23", # flake8-bugbear does not follow semver, leave it pinned. "isort>=5.10.1", - "mypy==0.971", - "pydocstyle>=5.0.0", + "mypy==0.971", # mypy does not follow semver, leave it pinned. + "pydocstyle>=6.0.0", "black>=22", ], "doc": [ diff --git a/tests/core/conftest.py b/tests/core/conftest.py deleted file mode 100644 index e69de29b..00000000 diff --git a/tests/core/test_import.py b/tests/core/test_import.py index f146ae79..07b2a18e 100644 --- a/tests/core/test_import.py +++ b/tests/core/test_import.py @@ -1,4 +1,2 @@ - - def test_import(): import # noqa: F401