diff --git a/setup.py b/setup.py
index <HASH>..<HASH> 100644
--- a/setup.py
+++ b/setup.py
@@ -44,7 +44,7 @@ install_requires = [
 extras_require = {
     'testing': [
         # third-party dependencies (versions should be flexible to allow for bug fixes)
-        'flake8>=4,<6',
+        'flake8~=5.0',
         'flake8-blind-except~=0.2.1',
         'flake8-bugbear~=22.7',
         'flake8-debugger~=4.1',
Update flake8 requirement to ~<I>