Opened 4 years ago

Closed 4 years ago

#15939 closed New feature (wontfix)

SignedIntegerField / UnsignedIntegerField as part of the core

Reported by: foxwhisper Owned by: nobody
Component: Database layer (models, ORM) Version: 1.3
Severity: Normal Keywords:
Cc: Triage Stage: Design decision needed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no


I'd like to place a feature request to see SignedIntegerField and UnsignedIntegerField included as part of the core ( which will adhere to the 32bit limits.h defaults - )

There has been some discussion so far in the following threads:

In terms of a use case scenario, I would imagine that most developers are used to working within the restrictions of a 32bit integer, and it would be nice to have this same ability for Django - out of the box.

If this is accepted, I'd be more than willing to submit the code and documentation patch.

Change History (2)

comment:1 Changed 4 years ago by aaugustin

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset
  • Triage Stage changed from Unreviewed to Design decision needed

I am not sure the 32 bit limit is really relevant: it does not exist in Python and 64 bit machines are the common case today.

SignedIntegerField and UnsignedIntegerField could cause confusion with PositiveIntegerField and IntegerField. Maybe adding optional min_value and max_value parameters to the existing fields would be more appropriate.

#56 tackles a similar problem, the solutions proposed over there could be interesting here.

comment:2 Changed 4 years ago by aaugustin

  • Resolution set to wontfix
  • Status changed from new to closed
  • UI/UX unset

Upon further thought, 32bit limits.h isn't very relevant for the modern web, and we already have too many field types.

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