HomePhabricator

resourceloader: Convert FileModule to use version hashing

Authored by Krinkle.

Description

resourceloader: Convert FileModule to use version hashing

Enabling the module content versioning is not feasible for FileModule as that
would involve Lessc and CSSJanus just to compute the version hash.

Instead, we can keep the existing logic that exists for the timestamp-based
versioning (which already has a comprehensive grip on tracking all involved
factors that cause a module to change) and convert it to use hashing instead.

This way the version hashes will be deterministic. Currently module versions
tend to be invalidated too often (and sometimes not often enough) due to Git and
other transport mechanisms not preserving file timestamps.

Research

Bug: T104950
Change-Id: I732fa4db32258c634e32b507952f76eac7fc9395