Opened 16 years ago

Closed 16 years ago

Last modified 12 years ago

#7830 closed (fixed)

removal of some deprecated features for 1.0

Reported by: Gary Wilson Owned by:
Component: Uncategorized Version: dev
Severity: Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

Attached is a patch that removes:

  • "simple" cache backend
  • ObjectPaginator
  • edit_inline_type argument for ForeignKey fields
  • QOperator, QNot, QAnd and QOr
  • maxlength argument

Along with mentions of them in the docs.

Note, the following should also be removed (if applying the patch doesn't do it):

  • django/utils/maxlength.py
  • tests/regressiontests/maxlength/

Attachments (1)

deprecated.patch (24.5 KB ) - added by Gary Wilson 16 years ago.

Download all attachments as: .zip

Change History (16)

by Gary Wilson, 16 years ago

Attachment: deprecated.patch added

comment:1 by Gary Wilson, 16 years ago

Triage Stage: UnreviewedReady for checkin

comment:2 by Russell Keith-Magee, 16 years ago

Another list of bits that need to be purged are the oldforms-specific parts of model fields. An incomplete list:

  • get_manipulator_field_names()
  • prepare_field_objs_and_params()
  • get_manipulator_fields()
  • get_manipulator_new_data()
  • flatten_data()
  • get_choices() and get_choices_default()

These aren't just in db.models.fields.init.py - they are in a few other locations, too. Doing a search for any method that mentions "manipulator" would be a pretty good starting point for finding the remainder.

comment:3 by Jacob, 16 years ago

milestone: 1.0 alpha1.0 beta

comment:4 by Alex Gaynor, 16 years ago

Is the auto_now auto_now_add stuff slated for removal(I only ask because if we keep those in then we can't remove them until 2.0 or whenever we next break backwards-compatibility)?

comment:5 by Gary Wilson, 16 years ago

(In [8191]) Removed several deprecated features for 1.0 (refs #7830):

  • "simple" cache backend
  • ObjectPaginator
  • edit_inline_type argument for ForeignKey fields
  • QOperator, QNot, QAnd and QOr
  • maxlength argument

comment:6 by Gary Wilson, 16 years ago

(In [8197]) Removed notes about legacy Paginator object in the generic view docs (refs #7830).

comment:7 by Gary Wilson, 16 years ago

(In [8199]) Removed unused warnings import that should have been removed in [8191], refs #7830.

comment:8 by Gary Wilson, 16 years ago

Has patch: unset
Owner: Gary Wilson removed
Triage Stage: Ready for checkinDesign decision needed

The following items are still issuing warnings:

  • UploadedFile properties - filename, file_name, file_size, and chunk. IMO, we should go ahead and remove these; weren't they only around for 6 days ([7814] to [7859])!?
  • Using uploaded-files-as-dictionaries. This should stay around for 1.0 and be removed next release.
  • form_for_model and form_for_instance. I'm not sure what the latest fate of these two functions are. Anyone have a status update?
  • Attempting to import django.newforms. I assume we are also going to want to keep this for 1.0 and remove next release.
  • Use of the follow argument in create/update generic views. This should probably get removed as part of #7742.

comment:9 by Alex Gaynor, 16 years ago

I don't think we can remove in the next release, 1.0 is supposed to mean backward compatibility going forward, aka everything that works on 1.0 will work with 1.1, etc. So I don't think that lets us remove things.

comment:10 by Gary Wilson, 16 years ago

Hmm... according to the contributing documentation, it looks like we actually need to remove all deprecated features before 1.0:

"A minor release may deprecate certain features in previous releases. If a feature in version A.B is deprecated, it will continue to work in version A.B+1. In version A.B+2, use of the feature will raise a PendingDeprecationWarning but will continue to work. Version A.B+3 will remove the feature entirely. Major point releases will always remove deprecated features immediately."

in reply to:  2 ; comment:11 by Gary Wilson, 16 years ago

Replying to russellm:

Another list of bits that need to be purged are the oldforms-specific parts of model fields. An incomplete list:

These should probably be removed with #7742, don't you think?

in reply to:  11 comment:12 by Russell Keith-Magee, 16 years ago

Replying to gwilson:

Replying to russellm:

Another list of bits that need to be purged are the oldforms-specific parts of model fields. An incomplete list:

These should probably be removed with #7742, don't you think?

I didn't notice #7742 when I commented on this ticket. Yes, oldforms bits should be removed as part of #7742.

comment:13 by Jacob, 16 years ago

Triage Stage: Design decision neededAccepted

comment:14 by Gary Wilson, 16 years ago

Resolution: fixed
Status: newclosed

(In [8291]) Fixed #7830 -- Removed all of the remaining, deprecated, non-oldforms features:

  • Support for representing files as strings was removed. Use django.core.files.base.ContentFile instead.
  • Support for representing uploaded files as dictionaries was removed. Use django.core.files.uploadedfile.SimpleUploadedFile instead.
  • The filename, file_name, file_size, and chuck properties of UploadedFile were removed. Use the name, name, size, and chunks properties instead, respectively.
  • The get_FIELD_filename, get_FIELD_url, get_FIELD_size, and save_FIELD_file methods for Models with FileField fields were removed. Instead, use the path, url, and size attributes and save method on the field itself, respectively.
  • The get_FIELD_width and get_FIELD_height methods for Models with ImageField fields were removed. Use the width and height attributes on the field itself instead.
  • The dispatcher connect, disconnect, send, and sendExact functions were removed. Use the signal object's own connect, disconnect, send, and send methods instead, respectively.
  • The form_for_model and form_for_instance functions were removed. Use a ModelForm subclass instead.
  • Support for importing django.newforms was removed. Use django.forms instead.
  • Support for importing django.utils.images was removed. Use django.core.files.images instead.
  • Support for the follow argument in the create_object and update_object generic views was removed. Use the django.forms package and the new form_class argument instead.

comment:15 by Jacob, 12 years ago

milestone: 1.0 beta

Milestone 1.0 beta deleted

Note: See TracTickets for help on using tickets.
Back to Top