Skip to content

Download and view counts highly inaccurate #19

@rebeltaz

Description

@rebeltaz

The [Downloads] count is highly inaccurate. Oftentimes, that number will be incremented with each viewing of the page, whether a file is downloaded or not. Sometimes the increment of that counter doesn't seem to be tied to any activity whatsoever.

Edit by @DrLex0:

Both the main download counter on Thing pages, as well as the separate download counts in the ‘files’ tab have problems:

  • Most obvious bug: simply (re)loading the ‘files’ tab of a Thing, increments the download count of all the files in the tab. This makes those counts meaningless.
  • The main counter goes up each time someone clicks the “Download all files” button, which makes sense. However, it is also incremented each time a separate file is downloaded from the files tab. Therefore if a Thing has 10 parts, and someone downloads all parts separately, the downloads are incremented by 10 although this should only be counted as one download.

I think it makes the most sense to:

  1. increment both the global counter, as well as the count for each separate part, when the “Download all files” button is clicked.
  2. only increment the count for a separate part if it is clicked in the files tab list. This means that if this is correctly implemented, the download counts for separate parts must always be more than or equal to the global download count.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions