Opened 6 years ago

Closed 6 years ago

#29862 closed New feature (wontfix)

Add Weight and Volume classes to measure module

Reported by: David Ross Owned by: David Ross
Component: GIS Version: 2.1
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by David Ross)

Add functionality to manipulate weights and volumes in the same fashion as the Distance class.

Change History (7)

comment:1 by Tim Graham, 6 years ago

Triage Stage: UnreviewedAccepted

comment:2 by David Ross, 6 years ago

Description: modified (diff)
Summary: Add Weight class to measure moduleAdd Weight and Volume class to measure module

comment:3 by David Ross, 6 years ago

Summary: Add Weight and Volume class to measure moduleAdd Weight and Volume classes to measure module

comment:5 by Tim Graham, 6 years ago

I think I accepted the ticket prematurely. Do these classes have anything to do with GIS? If they aren't used by contrib.gis then they probably don't belong.

comment:6 by David Ross, 6 years ago

Now that you mention it, contrib.gis probably isn't really an appropriate location for these classes. It utilises the base class MeasureBase in the contrib.gis.measure.py file, hence why I placed the classes there. Is there a more appropriate place for these new classes in the code base?

I feel these classes are useful additions for being able to convert units on the fly. For example altering an app users weight units depending on their preferences or region or conversion of volumes for a scientific application.

comment:7 by Tim Graham, 6 years ago

Resolution: wontfix
Status: assignedclosed

I don't think it's Django's place to provide these helpers. We have django.utils but this is limited to code that Django itself uses. I'd be surprised if there isn't an existing Python package that provides this functionality. If not, maybe you'd consider creating one.

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