8000 Remove finders kwarg from get_embed · Issue #7287 · wagtail/wagtail · GitHub
[go: up one dir, main page]

Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove finders kwarg from get_embed #7287

Open
gasman opened this issue Jun 25, 2021 · 1 comment
Open

Remove finders kwarg from get_embed #7287

gasman opened this issue Jun 25, 2021 · 1 comment
8000

Comments

@gasman
Copy link
Collaborator
gasman commented Jun 25, 2021

The finders kwarg on get_embed is undocumented and only used in tests:

def get_embed(url, max_width=None, max_height=None, finder=None):

It also doesn't receive a 'finder' object as per get_finders - it's a callable with its own calling convention.

Tests that follow a different code path to real-world code are of questionable usefulness - we should rewrite them, perhaps by using mocks or override_settings to pass in the single finder being tested in place of the result of get_finders.

@lb-
Copy link
Member
lb- commented Mar 8, 2025

PR up for this #12933

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants
0