Opened 6 years ago

Closed 4 years ago

Last modified 3 years ago

#11350 closed (fixed)

Support "local flavor" for Israel

Reported by: yuval_a Owned by: yuval_a
Component: contrib.localflavor Version: master
Severity: Keywords: local flavor israel
Cc: shai Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: UI/UX:

Description

Support django.contrib.localflavor for Israel

Attachments (7)

forms.py (1.7 KB) - added by yuval_a 6 years ago.
Forms for Israel local flavor
il.py (1.4 KB) - added by yuval_a 6 years ago.
Added regression tests
11350.diff (5.2 KB) - added by yuval_a 5 years ago.
Updated proper diff, with tests and docs
django-11350.diff (5.8 KB) - added by Alex 4 years ago.
Converted tests to unittests.
django-11350.2.diff (5.5 KB) - added by Alex 4 years ago.
Use the luhn function as suggested by jezdez.
django-11350.3.diff (6.5 KB) - added by idangazit 4 years ago.
Adds checking for hyphenated checksum, cited references.
django-11350.4.diff (6.9 KB) - added by idangazit 4 years ago.
Adds more sensible docs.

Download all attachments as: .zip

Change History (23)

comment:1 Changed 6 years ago by anonymous

  • Needs documentation unset
  • Needs tests unset
  • Owner changed from nobody to anonymous
  • Patch needs improvement unset
  • Status changed from new to assigned

comment:2 Changed 6 years ago by yuval_a

  • Owner changed from anonymous to yuval_a
  • Status changed from assigned to new

Changed 6 years ago by yuval_a

Forms for Israel local flavor

comment:3 Changed 6 years ago by yuval_a

  • Resolution set to fixed
  • Status changed from new to closed

comment:4 Changed 6 years ago by Alex

  • Resolution fixed deleted
  • Status changed from closed to reopened

A ticket isn't fixed because a patch is uploaded, it's fixed when the code goes into Django.

comment:5 Changed 6 years ago by Honza_Kral

  • Needs tests set

Also please add some tests to the forms you included. That way everybody will know if their work broke your code and would be able to fix it.

comment:6 Changed 6 years ago by russellm

  • milestone 1.1 deleted

We are well past the feature deadline for v1.1. This will need to wait until the next development phase.

Changed 6 years ago by yuval_a

Added regression tests

comment:7 Changed 6 years ago by Alex

  • Triage Stage changed from Unreviewed to Accepted

comment:8 Changed 5 years ago by jezdez

  • Needs documentation set
  • Needs tests unset
  • Patch needs improvement set

Please provide a proper diff of the changes and a little bit of documentation.

comment:9 Changed 5 years ago by shai

  • Cc shai added

Changed 5 years ago by yuval_a

Updated proper diff, with tests and docs

comment:10 Changed 5 years ago by yuval_a

  • Has patch set
  • milestone set to 1.3
  • Needs documentation unset
  • Patch needs improvement unset

Changed 4 years ago by Alex

Converted tests to unittests.

comment:11 Changed 4 years ago by Alex

Does anyone know where I can find a description of the Israeli ID specification, google yields nothing of use.

comment:12 Changed 4 years ago by shai

Google yields plenty of results when you search in Hebrew... by following them, I got to the Luhn Algorithm -- the standard "mod 10" variant; numbers are 8 digits + checksum (9 digits altogether).

comment:13 Changed 4 years ago by jezdez

FYI, there is a luhn function in django.utils.checksums that is used by at least one localflavor.

Changed 4 years ago by Alex

Use the luhn function as suggested by jezdez.

comment:14 Changed 4 years ago by idangazit

Relevant (hebrew) wikipedia entries: the ID number format: the ID number format,
the checksum algorithm.

Changed 4 years ago by idangazit

Adds checking for hyphenated checksum, cited references.

Changed 4 years ago by idangazit

Adds more sensible docs.

comment:15 Changed 4 years ago by Alex

  • Resolution set to fixed
  • Status changed from reopened to closed

(In [14223]) Fixed #11350 -- added an Israeli localflavor. Thanks to Yuval and Idan Gazit for their work on the patch.

comment:16 Changed 3 years ago by jacob

  • milestone 1.3 deleted

Milestone 1.3 deleted

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