Opened 7 years ago

Closed 7 years ago

#29181 closed New feature (needsinfo)

Move admin's flatten() function to django.utils

Reported by: Daniel Hahler Owned by: nobody
Component: Utilities Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

I think flatten from django.contrib.admin.utils should be moved to django.utils, and get modernized to not only handle nested lists and tuples.

I've tried to use it with django/forms/widgets.py, but it caused an recursive import issue.

Where should it go? django/utils/functional.py

Change History (2)

comment:1 by Tim Graham, 7 years ago

Component: UncategorizedUtilities
Summary: Move `flatten` to utilsMove admin's flatten() function to django.utils
Type: UncategorizedNew feature

It might be a candidate or django.utils.intercompat (although the "itercompat" name is no longer really relevant). How will the function be used in widgest?

Version 1, edited 7 years ago by Tim Graham (previous) (next) (diff)

comment:2 by Tim Graham, 7 years ago

Resolution: needsinfo
Status: newclosed
Note: See TracTickets for help on using tickets.
Back to Top