8000 Data request display does not handle time zones properly · Issue #53 · conwetlab/ckanext-datarequests · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Data request display does not handle time zones properly #53
Open
@ThrawnCA

Description

@ThrawnCA

Data requests are displayed with inaccurate "Created" strings, eg "-1 days ago".

This appears to result from a lack of time zone handling. actions.py populates the creation timestamp without specifying a time zone, but when it is rendered, it uses a localisation method (formatters.localised_nice_date) that assumes a lack of time zone data means UTC.

Either the time zone should be specified when first creating the data request, or else the current server time zone (eg from helpers.get_display_timezone()) should be assumed when displaying it. The latter approach would also resolve existing data requests.

This is similar to ckan/ckanext-xloader#102

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0