Skip to content

[Master] -Revert Changes- 'Greater Than' Withholding Tax Calculation Rule is not applied correctly in Withholding Tax Posting Setup.#9650

Merged
Alexander-Ya merged 1 commit into
microsoft:mainfrom
DhavalMore88:bugs/Bug-642326-Main-Revert-Greater-Than-Withholding-Tax-Calc
Jul 22, 2026
Merged

[Master] -Revert Changes- 'Greater Than' Withholding Tax Calculation Rule is not applied correctly in Withholding Tax Posting Setup.#9650
Alexander-Ya merged 1 commit into
microsoft:mainfrom
DhavalMore88:bugs/Bug-642326-Main-Revert-Greater-Than-Withholding-Tax-Calc

Conversation

@DhavalMore88

@DhavalMore88 DhavalMore88 commented Jul 22, 2026

Copy link
Copy Markdown
Contributor

AB#642326

Revert changes of PR #9515

@github-actions github-actions Bot added AL: Apps (W1) Add-on apps for W1 From Fork Pull request is coming from a fork labels Jul 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

Could not find linked issues in the pull request description. Please make sure the pull request description contains a line that contains 'Fixes #' followed by the issue number being fixed. Use that pattern for every issue you want to link.

@github-actions github-actions Bot added the Finance GitHub request for Finance area label Jul 22, 2026
@DhavalMore88 DhavalMore88 changed the title Revert WHT Changes [Master] -Revert Changes- 'Greater Than' Withholding Tax Calculation Rule is not applied correctly in Withholding Tax Posting Setup. Jul 22, 2026
@DhavalMore88
DhavalMore88 marked this pull request as ready for review July 22, 2026 08:30
@DhavalMore88
DhavalMore88 requested a review from a team July 22, 2026 08:30
@github-actions github-actions Bot added the Linked Issue is linked to a Azure Boards work item label Jul 22, 2026
@github-actions github-actions Bot added this to the Version 29.0 milestone Jul 22, 2026
@github-actions

Copy link
Copy Markdown
Contributor

$\textbf{🟡\ Medium\ Severity\ —\ Breaking\ Changes}$

The public (non-local) procedure ShouldCreateWithholdingTax(InvoiceAmount: Decimal; WithholdingPostingSetup: Record "Withholding Tax Posting Setup"): Boolean is deleted outright from codeunit 6785 "Withholding Tax Mgmt." instead of being marked [Obsolete(...)] and forwarded. This codeunit and procedure were introduced and shipped in a prior release (PR #9515, already merged to main before this revert), so if that version has been released to customers, external extensions calling ShouldCreateWithholdingTax will fail to compile with no deprecation warning. Per BCQuality guidance, a superseded published procedure should be kept in place with an [Obsolete] tag naming the replacement and only deleted after the deprecation window elapses, rather than deleted in the same change that stops using it internally. If this codeunit/procedure has not yet been released in a shipped version (i.e. no released baseline includes PR #9515), this does not apply per microsoft/knowledge/breaking-changes/unreleased-symbol-change-is-not-a-breaking-change.md — verify release status before acting on this finding.

Knowledge:

Line mapping was unavailable, so this was posted as an issue comment.

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.12.4

@github-actions

Copy link
Copy Markdown
Contributor

$\textbf{🟡\ Medium\ Severity\ —\ Testing}$

GreaterThanRuleBelowThresholdCreatesWHTEntryOnPurchaseInvoice and GreaterThanRuleAboveThresholdDoesNotCreateWHTEntryOnPurchaseInvoice, along with their shared helper CreateWHTPostingSetupWithCalcRule, VerifyWHTEntryExists, VerifyWHTEntryDoesNotExist, and UpdateWHTCertificateNosOnPurchSetup, are deleted from ERMWithholdingTaxTestsI.Codeunit.al. These tests were added specifically to cover AB#642326 ('Greater Than' Withholding Tax Calculation Rule not applied correctly) and are the only tests exercising the 'Greater than' calculation rule end-to-end. Removing them alongside the production-code revert eliminates the regression guard that would otherwise fail and flag this exact reintroduction of the bug.

Recommendation:

  • if the revert is intentional, the tests should be reverted too only after confirming the underlying behavior is meant to regress; otherwise both the production code and the tests should be restored together.

Line mapping was unavailable, so this was posted as an issue comment.

👍 useful · ❤️ especially valuable · 👎 wrong - reply with why · AL review agent v1.12.4

@DhavalMore88
DhavalMore88 enabled auto-merge July 22, 2026 15:57
@DhavalMore88
DhavalMore88 added this pull request to the merge queue Jul 22, 2026
@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jul 22, 2026
@Alexander-Ya
Alexander-Ya added this pull request to the merge queue Jul 22, 2026
Merged via the queue into microsoft:main with commit 096090d Jul 22, 2026
275 of 280 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

AL: Apps (W1) Add-on apps for W1 Finance GitHub request for Finance area From Fork Pull request is coming from a fork Linked Issue is linked to a Azure Boards work item

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants