Clone/Remove In Progress Queue Items

I would like the ability when testing to be able to remove an In Progress Queue Item.
Our framework won’t add items to queue as long as there is a Queue Item that is New or In Progress, and the only option to get moving is to remove the queue and add it again.
If something breaks in production we again have to delete the queue and add it again to get the robot to work!
By the way the developers doesn’t have that role available, so it is time consuming for the developer to get a hold of the administrator!
Please give us the “power” to assist our robots. If I know that the In Progress item is dead/abandoned then I would like to remove it. Having to wait for hours is not one of my virtues.
I would also like to be able to clone an In Progress item, why is that not an option, when you can clone a New/Failed/Success. To me that doesn’t make any sense. Please explain!

Thats a very brute force approach… it also nukes your history.
There are simpler solututions to this, for example just make a very quick app where someone can enter a folder and queue name and tell it to delete the in progress item.

I’ve myself made a tampermonkey script in the past to do this by adding a button in the Orchestrator Ui.

You can also make your framework more robust so queue items can never be left in progress unless the executor hard crashes.
In development its easy to avoid by using test cases and mocks to not actually add the test item you want to use to a queue, instead just building it in code.

I agree it should be way easier to fail an in progress queue item, but I think you are already doing it in a difficult way…

Main issue I have is there is no way, either via robot or API, to set a queue item status to abandoned so we can have ways of ‘cleaning up’ queues should an item get stuck due to a hard crash.

I would disagree of a requirement to clone an in progress item however, I am not sure of the use case for this, but I can agree that it is an arbitrary restriction.

I see I need to explain some of it a bit more.
In production we don’t see this issue, because the framework is buildt like it is.
But in UAT we tend to do things by hand on first run (Test data doesn’t represent production data) and sometimes there are crashes, and we stop the robot. Now we have the In Progress QI.

Due to the fact that we are using “Enforce unique references” on the queue, we can’t add that item again from production data.

I get the idea about Unit testing, we do so when testing, but not as extensive as when getting 20 rows of real data from a source.

Now back to the line about

There are simpler solututions to this, for example just make a very quick app where someone can enter a folder and queue name and tell it to delete the in progress item.

But how do you delete an In Progress item? I haven’t found this option.

Sure, different ways of approaching things, I still think you can solve that issue via test cases as they can be for more than unit testing but I digress, I’m not here to second guess your entire way of working, but perhaps more to suggest some minor adjustments whilst this is something not facilitated by the Ui.

Regarding the App, you connect it to an RPA process that would handle grabbing the item and then setting the status to failed, at that point it can be cloned (this could even be an option for the app).

You could also make this an attended bot but that assumes the developer is connected to the same tenant you are testing in, hence why I suggest the App.

Can be a super simple background process to do this I think.

I posted this years ago. Still nothing from UiPath.

We also need to be able to retry and/or clone an In Progress queue item so that we can manage when a Job faults.

It is a kluge way to do it, but if you left click the 3 dots beside the In Progress queue item, then right click just to the right of the greyed out Clone option and select inspect. You will get the inspect/console window for your browser, since you right clicked off to the right of the Clone button you should see in the top window that the clone button is already highlighted. Find the tag disabled=“true” and double click it so that it highlights the entire disabled=“true” and hit delete, click somewhere else so your cursor moves and you should see the Clone button is no longer greyed out, hit clone and clone your in progress queue item…

@jason.tohlen,

Is this real thing :scream: let me give it a try. This is very much needed.

Thanks,
Ashok :slightly_smiling_face:

I can’t believe it, but it works!
We’ve built a little process to set In Progress Queue Items to Failed with ‘set transaction status’-activity. After that you can retry or clone the queue item.
And you can set the time, after a In Progress Queue Item is set to Abandonnend by the orchestrator.

Wow this is truly a gold nugget. Thanks for sharing with the community. It didnt work for me with clone but it worked with retry item.

We added the ability to delete InProgress queue items via the UI in Automation Cloud: Orchestrator - July 2024

The feature will also be present in 2024.10 Automation Suite, but not in the Standalone or older versions.

Happy days!

Question on a minor doom scenario: lets say an over eager developer sets a queue item from in progress to failed while a bot is actually executing it. Direct execution won’t be impacted, but how will it affect the set transaction status activity when invoked on an incorrect status? Will it overwrite of just throw an exception?

@Jeroen_van_Loon,

It will not throw any exception and overwrite whatever status set by Set Transaction Status Activity.

Hi CosminV, The feature is much appreciated! Good job!

I have a challenge related to this feature.
We have a queue, which we turned on “Enforce unique references” (this is a good feature for some processes). In case of failure, we can retry them, which is fine. But there are some weird occasions when robot is stuck and we had to “kill” the robot.

So, we need to “delete” the “in progress” transaction. But, then we can’t retry it, or clone it, or added it back into the queue because the “unique reference” rule.

Do you know how can we solve this issue?

Thanks!
Hellitonwoo

Hi @Hellitonwoo_Wilhelmsen,

I have solved it with a xaml called ClearInProgress, this will take all In Progress QueueItems and set them as Failed.
Hope this will help you. From Failed you can retry the QueueItem.
ClearInProgress.xaml (13.9 KB)

This is insane ! Thanks a lot for sharing it, and the best thing is… it works !! :exploding_head: :exploding_head: :exploding_head:

이미 이게 가능하다는 걸 알게 된 뒤에 이 게시물을 보게 되니 신기하네요.
다른 개발자들도 Inspector에 들어갈 필요 없이 그 개선 사항을 사용할 수 있도록 Tampermonkey 스크립트나 다른 유형의 확장 프로그램이 나오면 좋겠네요 :smiling_face_with_sunglasses::+1:t2:

안녕하세요, @mateuszmacheta님.
아래는 사용할 수 있는 간단한 스크립트입니다. YOURORG와 YOURORC를 바꾸는 걸 잊지 마세요. Orchestrator URL을 확인해 보세요.
스크립트를 개선할 수도 있습니다. GPT를 사용해 만들었고, 제가 있는 곳에서는 작동하는 것을 확인했습니다 :slight_smile:

// ==UserScript==
// @name         Enable Clone Buttons on Cloud.UiPath.com
// @namespace    http://tampermonkey.net/
// @version      1.0
// @description  cloud.uipath.com의 복제 버튼에서 'disabled' 속성을 제거합니다
// @author       Michael Dyhr Iversen
// @match        https://cloud.uipath.com/YOURORG/YOURORC/orchestrator_/queues/*
// @grant        none
// ==/UserScript==

(function() {
    'use strict';

    // 복제 버튼을 활성화하는 함수
    function enableCloneButtons() {
        const buttons = document.querySelectorAll('button[data-cy="clone"][disabled]');
        buttons.forEach(button => {
            button.removeAttribute('disabled');
        });
    }

    function enableRetryButtons() {
        const buttons = document.querySelectorAll('button[data-cy="retry-items"][disabled]');
        buttons.forEach(button => {
            button.removeAttribute('disabled');
        });
    }

    // 최초 로드 시 실행
    enableCloneButtons();
    //enableRetryButtons();

    // 선택 사항: 버튼이 동적으로 추가되는 경우를 위해 DOM 변경을 감시
    const observer = new MutationObserver(() => {
        enableCloneButtons();
        //enableRetryButtons();
    });

observer.observe(document.body, { childList: true, subtree: true });
})();

진행 중인 큐 항목이 실패하는 문제로 아직도 어려움을 겪고 있나요?

인증 토큰이 필요하기 때문에 Tampermonkey를 통해 Orchestrator로 API 호출을 보내거나 Orchestrator에서 API 호출을 실행하는 것은 훨씬 더 어렵지만, 토큰을 어디서 찾는지 알면 실제로 충분히 가능합니다.

안녕하세요 @Jon_Smith,

대기 중인 모든 항목을 실패 처리하는 기능을 기본 프레임워크 코드에 구현한 이후로는 이 문제가 거의 발생하지 않습니다. 따라서 개발자는 항상 해당 워크플로를 사용할 수 있습니다.

저는 API 호출을 보내기 위해 Tampermonkey를 사용하지 않습니다. UiPath UI에서 숨겨진 "Clone"을 재정의하도록 위 흐름을 만들 뿐입니다.

하하, 의견 고마워요. 제 클라이언트 환경에서는 Tampermonkey 확장 프로그램을 사용할 수 없다는 걸 알게 됐어요. 그래도 최소한 개발자 콘솔에 붙여넣을 수 있도록 스크립트를 한 줄짜리로 다시 작성해 볼 수도 있겠네요.
편집:

(()=>{const e=()=>document.querySelectorAll('button[data-cy="clone"][disabled],button[data-cy="clone"][aria-disabled]').forEach(b=>{b.removeAttribute('disabled');b.removeAttribute('aria-disabled');b.disabled=!1});e();new MutationObserver(e).observe(document.body,{childList:!0,subtree:!0});})();

편집 2: 작동이 멈춰 스크립트를 업데이트했습니다.