Skip to content

fix: deploying production items no longer tries to load unrelated items#978

Open
isc-pbarton wants to merge 1 commit into
mainfrom
fix-deploy-ptd-loads-unrelated
Open

fix: deploying production items no longer tries to load unrelated items#978
isc-pbarton wants to merge 1 commit into
mainfrom
fix-deploy-ptd-loads-unrelated

Conversation

@isc-pbarton

@isc-pbarton isc-pbarton commented Jun 17, 2026

Copy link
Copy Markdown
Collaborator

Description

Fixes #977

The code path leading to the bug is: User tries to deploy a change through the deployment manager, while having an unrelated item in the Git repository. It calls the source control extension OnAfterSave hooks. OnAfterSave calls GetModifiedItemsAfterSave. For an unknown reason it goes through the code path for edits from an IDE rather than the Interoperability Portal (not worth tracing down, as it should work either way). GetModifiedItemsAfterSave recompiles the production to regenerate the Ens_Config.Item table so we can query it to find if items were added/deleted. (MODIFICATION HERE.) The recompile calls the source control extension OnAfterCompile hooks, which calls RefreshUncommitted, which calls ExternalNameToInternalName, which does a test load of each modified item in the git repo, which fails for some totally unrelated item. Since the load fails inside of a compile, the compile returns a failure, the whole deployment ends up failing.

Where I say MODIFICATION HERE: we new %SourceControl to break the chain. We should not be calling source control hooks when doing that compile.

Testing

Unit test case replicates reported bug. Before the fix it failed, now it succeeds.

Checklist

  • This branch has the latest changes from the main branch rebased or merged.
  • [N/A] Web UI has been built (any changes in git-webui/src have matching changes in git-webui/release)
  • CHANGELOG.md entry added if appropriate.
  • [N/A] Documentation has been/will be updated

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 49.25%. Comparing base (52eb53e) to head (5fd665d).

Additional details and impacted files
@@            Coverage Diff             @@
##             main     #978      +/-   ##
==========================================
+ Coverage   49.24%   49.25%   +0.01%     
==========================================
  Files          22       22              
  Lines        3300     3301       +1     
==========================================
+ Hits         1625     1626       +1     
  Misses       1675     1675              

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

Deploying production attempts to load unrelated items

2 participants