You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
ThemeFilesFinder.find() got an unexpected keyword argument 'find_all' #36862
In Django 5.2, the BaseFinder.find() method signature has changed from:
def find(self, path, all=False): to: def find(self, path, find_all=False, **kwargs):
However, in ThemeFilesFinder, the find() method still uses the old signature:
def find(self, path, all=False):
This causes compatibility issues when running collectstatic or when Django attempts to use the finder, resulting in a TypeError or warning about method signature mismatch.
Ideally, we should fix this in a way that maintains compatibility with both Django 4.2 and 5.2. If that's not feasible, we can defer the change and include it as part of the final Django 5.2 upgrade PR.
I think there are hacky ways to do this by making a function signature that takes both all and find_all as keyword params and uses sentinel values to choose between them, but I think it's fine to just include this change in the PR that makes the upgrade from 4.2 to 5.2.
Activity
awais786 commentedon Jun 5, 2025
Ideally, we should fix this in a way that maintains compatibility with both Django 4.2 and 5.2. If that's not feasible, we can defer the change and include it as part of the final Django 5.2 upgrade PR.
@feanil FYI
feanil commentedon Jun 9, 2025
I think there are hacky ways to do this by making a function signature that takes both
allandfind_allas keyword params and uses sentinel values to choose between them, but I think it's fine to just include this change in the PR that makes the upgrade from 4.2 to 5.2.