Opened 5 years ago

Closed 5 years ago

Last modified 5 years ago

#30523 closed Bug (fixed)

StatReloader does not update file times if notify_file_changed() is triggered.

Reported by: Tom Forbes Owned by: Tom Forbes
Component: Utilities Version: 2.2
Severity: Release blocker 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

If notify_file_changed is triggered then the files mtime is not updated. This can cause notify_file_changed() to be triggered many times if a translation is changed.

Change History (5)

comment:1 by Tom Forbes, 5 years ago

Component: UncategorizedUtilities
Has patch: set
Owner: changed from nobody to Tom Forbes
Status: newassigned
Triage Stage: UnreviewedAccepted
Type: UncategorizedBug

comment:2 by Mariusz Felisiak, 5 years ago

Summary: StatReloader does not update file times if notify_file_changed() is triggeredStatReloader does not update file times if notify_file_changed() is triggered.
Triage Stage: AcceptedUnreviewed
Version 0, edited 5 years ago by Mariusz Felisiak (next)

comment:3 by Mariusz Felisiak, 5 years ago

Severity: NormalRelease blocker
Triage Stage: UnreviewedAccepted

comment:4 by Mariusz Felisiak <felisiak.mariusz@…>, 5 years ago

Resolution: fixed
Status: assignedclosed

In 480492fe:

Fixed #30523 -- Fixed updating file modification times on seen files in auto-reloader when using StatReloader.

Previously we updated the file mtimes if the file has not been seen
before - i.e on the first iteration of the loop.

If the mtime has been changed we triggered the notify_file_changed()
method which in all cases except the translations will result in the
process being terminated. To be strictly correct we need to update the
mtime for either branch of the conditional.

Regression in 6754bffa2b2df15a741008aa611c1bb0e8dff22b.

comment:5 by Mariusz Felisiak <felisiak.mariusz@…>, 5 years ago

In 7089502b:

[2.2.x] Fixed #30523 -- Fixed updating file modification times on seen files in auto-reloader when using StatReloader.

Previously we updated the file mtimes if the file has not been seen
before - i.e on the first iteration of the loop.

If the mtime has been changed we triggered the notify_file_changed()
method which in all cases except the translations will result in the
process being terminated. To be strictly correct we need to update the
mtime for either branch of the conditional.

Regression in 6754bffa2b2df15a741008aa611c1bb0e8dff22b.

Backport of 480492fe70b0bb7df61c00854dc8535c9d21ba64 from master

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