Skip to content

FOUR-32683: Preserve PM Block task context in Web Entry redirects - #1928

Open
eiresendez wants to merge 3 commits into
developfrom
task/FOUR-32683
Open

FOUR-32683: Preserve PM Block task context in Web Entry redirects#1928
eiresendez wants to merge 3 commits into
developfrom
task/FOUR-32683

Conversation

@eiresendez

@eiresendez eiresendez commented Aug 17, 2026

Copy link
Copy Markdown
Contributor

Issue & Reproduction Steps

An authenticated Web Entry that transitions into a PM Block creates the child request and task correctly, but the redirect flow retains the parent request ID while applying the child task node ID. This produces an invalid Web Entry URL, a 404 configuration request, and an interstitial that remains loading indefinitely.

  1. Import the test_pm_block_6789.json fixture attached to FOUR-32683.
  2. Start the parent process through its authenticated Web Entry.
  3. Submit the first form and continue until the PM Block creates its child task.
  4. Observe that the failing flow combines the parent request ID with the child task node ID.

Solution

  • Resolve the complete next assigned task before processing Web Entry socket redirects.
  • Pass the target task ID, element ID, and process request ID through Web Entry hard redirects.
  • Preserve the existing numeric task-ID redirect contract outside Web Entry.
  • Redirect tasks without Web Entry availability to the standard task form.
  • Add focused regression tests for child-request, fallback, websocket, and compatibility paths.

How to Test

  • Run TaskWebEntryRedirect.spec.js and TaskSelfServiceLock.spec.js.
  • Start the attached process through its authenticated Web Entry and submit until it reaches the PM Block.
  • Confirm that the child task opens without a stale request ID, 404 response, or infinite interstitial.
  • Complete the child task and confirm that the parent request resumes and can finish.

Related Tickets & Packages

ci:deploy
ci:package-webentry:task/FOUR-32683
.

@cypress

cypress Bot commented Aug 17, 2026

Copy link
Copy Markdown

screen-builder    Run #2357

Run Properties:  status check failed Failed #2357  •  git commit 3dbb40093a: FOUR-32683: Preserve PM Block task context in Web Entry redirects
Project screen-builder
Branch Review task/FOUR-32683
Run status status check failed Failed #2357
Run duration 46m 16s
Commit git commit 3dbb40093a: FOUR-32683: Preserve PM Block task context in Web Entry redirects
Committer Eleazar Resendez
View all properties for this run ↗︎

Test results
Tests that failed  Failures 2
Tests that were flaky  Flaky 0
Tests that did not run due to a developer annotating a test with .skip  Pending 17
Tests that did not run due to a failure in a mocha hook  Skipped 4
Tests that passed  Passing 389
View all changes introduced in this branch ↗︎

Tests for review

Failed  DatePicker.spec.js • 1 failed test • CI - Chrome

View Output

Test Artifacts
Date Picker > Date time picker validate when the user enter a string instead of a valid date Test Replay Screenshots
Failed  ComputedFields.spec.js • 1 failed test • CI - Chrome

View Output

Test Artifacts
Computed fields > Focuses the first field that has an error Test Replay Screenshots

@processmaker-sonarqube

Copy link
Copy Markdown

@nolanpro

Copy link
Copy Markdown
Contributor

QA server K8S was successfully deployed https://ci-d106cbcdc2.engk8s.processmaker.net

@eiresendez eiresendez self-assigned this Aug 18, 2026
@nolanpro

Copy link
Copy Markdown
Contributor

QA server K8S was successfully deployed https://ci-d106cbcdc2.engk8s.processmaker.net

@eiresendez
eiresendez requested a review from CarliPinell August 18, 2026 17:03
@eiresendez

Copy link
Copy Markdown
Contributor Author

@nolanpro @sanjacornelius @CarliPinell

The Decisions SonarQube migration is also blocking this PR, but the failure has two separate causes:

  • The old SonarQube server passed commit 962d07d with 46.7% coverage on new code. The current commit 22734e1 reports 49.2%, but the new Decisions Quality Gate now requires at least 80%. The LCOV report was generated and imported successfully; however, Screen Builder’s Sonar workflow only merges Cypress coverage. The focused Jest regression tests added for this PR are not executed or included in the CI coverage report.
  • The single new issue is javascript:S8961 at src/components/task.vue:564. Screen Builder uses Vue 2.6, and SonarSource lists JS-2088, “S8961 should not raise on Vue 2 projects,” as fixed in SonarJS 13.4.

How can we solve this?

Evidence:

@CarliPinell

Copy link
Copy Markdown
Contributor

The code looks good. No observations.

@CarliPinell

Copy link
Copy Markdown
Contributor

Tested on Built environment the process completes succesfully

image

@CarliPinell

Copy link
Copy Markdown
Contributor

Unit Tests passed
image

@CarliPinell CarliPinell left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Tested and approved.

@ryancooley

Copy link
Copy Markdown
Contributor

I have updated the new SonarQube quality gate. Re-running tests.

@nolanpro

Copy link
Copy Markdown
Contributor

QA server K8S was successfully deployed https://ci-d106cbcdc2.engk8s.processmaker.net

@decisions-sonarqube

Copy link
Copy Markdown

Quality Gate failed Quality Gate failed

Failed conditions
1 New issue
1 New Maintainability Issues (required ≤ 0)

See analysis details on SonarQube

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE SonarQube for IDE

@eiresendez

Copy link
Copy Markdown
Contributor Author

Hi @sanjacornelius and @ryancooley — SonarQube is reporting S8961 because the new redirect event is not declared in an emits option. However, Screen Builder targets Vue 2 (^2.6.12, currently resolved to 2.7.16), while explicit emits is primarily a Vue 3 convention and is supported in Vue 2.7 only for type-checking, without runtime behavior. This also appears inconsistent with the existing codebase: task.vue has 21 $emit calls covering 10 event names, and the repository has 175 similar findings across 61 files.

Could you advise how I should proceed? It seems S8961 may be incorrectly enabled for this Vue 2 project, so marking this finding as a false positive or disabling the rule for Screen Builder’s quality profile may be more appropriate than adding a partial Vue 3-style emits declaration solely to satisfy the quality gate.

@eiresendez

Copy link
Copy Markdown
Contributor Author

In sync with @ryancooley and @sanjacornelius, we will not address this SonarQube finding because Screen Builder currently uses Vue 2, and adding the emits option only here would be inconsistent with the rest of the codebase. The finding will be marked as a false positive.

@nolanpro

Copy link
Copy Markdown
Contributor

QA server K8S was successfully deployed https://ci-d106cbcdc2.engk8s.processmaker.net

@eiresendez

Copy link
Copy Markdown
Contributor Author

I reran the failed checks, but these failures are unrelated to the changes in this PR. The same intermittent Cypress/Vite issue has occurred in other Screen Builder PRs, where the app sometimes does not render and tests time out waiting for common UI elements. This CI stability issue should be addressed in a separate ticket outside the scope of this PR, so please disregard these failed checks when reviewing the changes here.

@nolanpro @sanjacornelius

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.

4 participants