only update pinned hash if new hash is newer than old hash (#82173)
For https://github.com/pytorch/pytorch/issues/82033
Only update the pinned hash if the new hash is strictly newer than the old hash. This should allow us to use commits on PRs as the pinned hash, which helps with fixes in XLA. General hash update behavior (looking at hash on branch, trying to update + pushing, creating pr) should be unchanged.
If the currently pinned hash is newer than the hash we are trying to update to, the existing pr will be closed if it exists.
Also changes the hash update time to 12:37am PST (7:37am UTC).
Pull Request resolved: https://github.com/pytorch/pytorch/pull/82173
Approved by: https://github.com/ZainRizvi, https://github.com/huydhn