thunderclient / thunder-client-support

Thunder Client is a lightweight Rest API Client Extension for VS Code.
https://www.thunderclient.com
Other
3.62k stars 128 forks source link

Collection requests don't run in a defined order #1425

Closed AlekStyk closed 9 months ago

AlekStyk commented 9 months ago

Describe the bug Requests order defined in a collections folder is different from order displayed after Run all on a selected folder. Any modification to a collections folders requests (manual rearrangement, duplication or removal) ends with the same incorrect final order of requests after Run all. Only way to fix this behavior is to remove problematic folder along with every request inside.

To Reproduce

  1. Add a new collection.
  2. Add a new folder inside a collection.
  3. Add any number of new requests (greater than 1).
  4. Use Run all and verify the order of requests.

There is no specific way to always reproduce this problem. I have not been able to identify the cause. It has happened to multiple folders in the same collection which had over 900 requests inside. I attach the photo of a collection where the defined order is POST - DELETE - POST - DELETE... but final order after Run all is different.

obraz

Expected behavior Order of requests defined in a collections folder is the same as order of requests after Run all.

Platform:

Are you using the free version/paid version/trial: Paid version

rangav commented 9 months ago

Thanks @AlekStyk for reporting the issue, will look into it.

can you please confirm your subscription using below form, Thanks. https://www.thunderclient.com/contact

rangav commented 9 months ago

I just now verified it, the order is correct to me

Screenshot 2023-11-27 at 19 13 35
rangav commented 9 months ago

I am closing this issue as we cannot re-produce the issue, feel free to continue the discussion.

AlekStyk commented 4 months ago

Hello! Unfortunately, the issue still persists. The issue is annoying and appears more and more often when there are a very large number of requests in the collection. However, I have further verified the problem.

The problem is with sorting requests in a folder. Upon verifying the sortNum in the JSON file, it is noticeable that values are being incorrectly assigned. The most often occurs when I create requests by duplicating them. And then, when I try to add more requests using the "New request" option.

I attach the photo of a collection where the requests arranged in the folder are not sorted the same way in Run all. Requests that should be at the end in Run all are at positions 5 and 7, which is not correct.

test

Thank you!

rangav commented 4 months ago

@AlekStyk I think its better to schedule a call to address this issue.

Can you please let me know your availability using below form https://www.thunderclient.com/contact

AlekStyk commented 4 months ago

Unfortunately, I wont be able to show you an example from my project, as these are sensitive data. However, I managed to replicate this issue locally using some random data.

I am sending a json file of the collection in the attachment. Please follow my steps to reproduce the issue. thunder-collection_test.json

  1. Import the json file to a new project.

  2. Go to the last requests in the order test folder.

  3. Duplicate the last two requests twice:

  4. Then, using the New Request option, add a new test request:

5.Verify the order after clicking Run all

You can notice that the last request added using the Add Request option is not in the correct order.

My example is simple, but its easy to notice the rearrange. In a large project with many requests, the mixing up of requests is significantly worse.

rangav commented 4 months ago

Thanks @AlekStyk for sharing info. will verify and get back to you.

rangav commented 4 months ago

cant reproduce the error

Screenshot 2024-04-24 at 12 11 11
rangav commented 4 months ago

better to do a call and show me the bug using this test collection. ( don't need use your real collection )

AlekStyk commented 4 months ago

OK, i just filled out the contact form

rangav commented 4 months ago

This bug is fixed and published to the marketplace. Please update to v2.21.15.

You can see all the features released in this update https://github.com/rangav/thunder-client-support/releases/tag/v2.21.15

Please test it and let me know your feedback

AlekStyk commented 4 months ago

I don't reproduce the issue anymore, it's ok! Thank you!

rangav commented 4 months ago

Thanks @AlekStyk for the confirmation.