I've run into this issue with the django-mfa2 package today (see error below). Looks like the FIDO2 package released some breaking changes. I'd advise to either update django-mfa2 with these changes or pin the FIDO2 dependency.
Traceback (most recent call last):
File "/Users/runner/work/tethys/tethys/tethys_portal/manage.py", line 20, in <module>
execute_from_command_line(sys.argv)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/__init__.py", line 419, in execute_from_command_line
utility.execute()
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/__init__.py", line 413, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/base.py", line 354, in run_from_argv
self.execute(*args, **cmd_options)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/base.py", line 398, in execute
output = self.handle(*args, **options)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/base.py", line 89, in wrapped
res = handle_func(*args, **kwargs)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/commands/migrate.py", line 75, in handle
self.check(databases=[database])
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/management/base.py", line 419, in check
all_issues = checks.run_checks(
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/checks/registry.py", line 76, in run_checks
new_errors = check(app_configs=app_configs, databases=databases)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/checks/urls.py", line 13, in check_url_config
return check_resolver(resolver)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/core/checks/urls.py", line 23, in check_resolver
return check_method()
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/urls/resolvers.py", line 416, in check
for pattern in self.url_patterns:
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/utils/functional.py", line 48, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/urls/resolvers.py", line 602, in url_patterns
patterns = getattr(self.urlconf_module, "urlpatterns", self.urlconf_module)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/utils/functional.py", line 48, in __get__
res = instance.__dict__[self.name] = self.func(instance)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/django/urls/resolvers.py", line 595, in urlconf_module
return import_module(self.urlconf_name)
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/importlib/__init__.py", line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1050, in _gcd_import
File "<frozen importlib._bootstrap>", line 1027, in _find_and_load
File "<frozen importlib._bootstrap>", line 1006, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 688, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 883, in exec_module
File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed
File "/Users/runner/work/tethys/tethys/tethys_portal/urls.py", line 20, in <module>
from tethys_portal.views import accounts as tethys_portal_accounts, \
File "/Users/runner/work/tethys/tethys/tethys_portal/views/accounts.py", line 15, in <module>
from mfa.helpers import has_mfa
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/mfa/helpers.py", line 3, in <module>
from . import TrustedDevice, U2F, FIDO2, totp
File "/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/mfa/FIDO2.py", line 1, in <module>
from fido2.client import ClientData
ImportError: cannot import name 'ClientData' from 'fido2.client' (/Users/runner/miniconda/envs/tethys/lib/python3.10/site-packages/fido2/client.py)