From 156ef016334f02f5f8187e4700db9773bfe99e9f Mon Sep 17 00:00:00 2001 From: Raymond Rebbeck Date: Mon, 23 Jun 2025 22:27:26 +0930 Subject: [PATCH 1/2] Fix lut files that do not exist as never being considered outdated for the purpose of importing The timestamp returned by %RoutineMgr.TS() is always the current time for a lut file that does not exist or has yet to be imported, resulting in such lut files as never being considered as outdated when performing an import. Check that lut files exist before using the returned timestamp, allowing them to be imported. --- cls/SourceControl/Git/Utils.cls | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cls/SourceControl/Git/Utils.cls b/cls/SourceControl/Git/Utils.cls index 3587408e..775aff1a 100644 --- a/cls/SourceControl/Git/Utils.cls +++ b/cls/SourceControl/Git/Utils.cls @@ -1308,7 +1308,8 @@ ClassMethod RoutineTSH(InternalName As %String) As %String if tsh = "" { #dim ts as %String = ##class(%RoutineMgr).TS(InternalName) - if ts '= "" { + // lut files that do not exist always return the current time as a timestamp, check that they exist before using it + if (ts '= "") && ((type '= "lut") || ((type = "lut") && ##class(%RoutineMgr).Exists(InternalName))) { // prj files have milliseconds in timestamp, so we crop them set tsh = $piece($zdatetimeh(ts, 3),".",1) } else { From dd3b2443b1d0b2aec13f0b5d52e15270cd0be733 Mon Sep 17 00:00:00 2001 From: Raymond Rebbeck Date: Mon, 23 Jun 2025 22:44:51 +0930 Subject: [PATCH 2/2] Update CHANGELOG and module version --- CHANGELOG.md | 5 +++++ module.xml | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 772a67ab..67c36176 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html). +## [2.13.0] - Unreleased + +### Fixed +- Fixed importing Lookup Tables that do not already exist (#791) + ## [2.12.1] - 2025-06-27 ### Fixed diff --git a/module.xml b/module.xml index b1e85d7e..0660105c 100644 --- a/module.xml +++ b/module.xml @@ -3,7 +3,7 @@ git-source-control - 2.12.1 + 2.13.0 Server-side source control extension for use of Git on InterSystems platforms git source control studio vscode module