Skip to content

Fix: IPM Update Resource Conflict#1129

Open
isc-jlechtne wants to merge 5 commits into
mainfrom
fix-1128
Open

Fix: IPM Update Resource Conflict#1129
isc-jlechtne wants to merge 5 commits into
mainfrom
fix-1128

Conversation

@isc-jlechtne
Copy link
Copy Markdown
Collaborator

@isc-jlechtne isc-jlechtne commented Apr 30, 2026

Fixes #1128

Updates update test with the following resources:

  • Adds pre-update resources to dependency modules module-a (Class1.cls) and module-b (Class2.cls)
  • For post-update versions: moved resources so that Class1.cls is in module-c and Class2.cls is in module-a
  • Creates an intermediate module-a v2.0.5+snapshot with Class1.cls

Steps added:

  1. After install of pre-update versions, attempt to update to module-a v2.0.5+snapshot. This will fail due to Class1.cls belonging to both module-a and module-c
  2. Update to module-a v2.1.0+snapshot has Class1 and Class2 moving around modules, which will no longer fail due to this fix

Copy link
Copy Markdown
Collaborator

@isc-cborbonm isc-cborbonm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just left a couple of comments! but it looks great to me 😃

@@ -1371,6 +1364,12 @@ Method GetResolvedReferences(
}

if pLockedDependencies {
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question: why did this get moved to only when pLockedDependencies is set?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pDependencyGraph is only used within this if-statement. Felt unnecessary to me to build the dependency graph earlier if the execution never got to the point where we actually use it

/// See property description for more details on the usage of MarkedForUpdate
ClassMethod MarkResourceForUpdate(
resourceName As %String,
marking As %Boolean = 1)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is there a use case for this method when marking would be set to 0?

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not currently but for what the method is doing I felt it made sense to have the capability work both ways.

@isc-eneil
Copy link
Copy Markdown
Collaborator

isc-eneil commented May 5, 2026

@isc-jlechtne mind adding your test cases to the PR description? Thanks!
Also, I took a look and left a few nits about comments. Looks good!

Comment thread src/cls/IPM/Storage/ResourceReference.cls Outdated
Comment thread src/cls/IPM/Storage/ResourceReference.cls Outdated
Comment thread tests/integration_tests/Test/PM/Integration/Update.cls Outdated
Comment thread tests/integration_tests/Test/PM/Integration/Update.cls Outdated
Copy link
Copy Markdown
Collaborator

@isc-dchui isc-dchui left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The only thing not already mentioned is that "addresses" is not actually one of the magic github closing words so won't auto-link the issue. You'll need "fixes" or "resolves". Also more detail in the description would be nice!

Copy link
Copy Markdown
Collaborator

@isc-cborbonm isc-cborbonm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

looks good to me :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

IPM Update Resource Conflict

4 participants