Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Galasa is duplicating run info returned to "galasactl runs get" #2049

Open
Tom-Slattery opened this issue Nov 11, 2024 · 4 comments
Open

Galasa is duplicating run info returned to "galasactl runs get" #2049

Tom-Slattery opened this issue Nov 11, 2024 · 4 comments
Assignees
Labels
defect Something isn't working

Comments

@Tom-Slattery
Copy link

Describe the bug

Galasactl runs get returns many more runs for test runs that failed due to resource limitations and were requeued by the Galasa Ecosystem. Identified this bug with @eamansour and found that it also applied to the Galasa team's ecosystem.

There also seems to be no indication that a test that has run into a resource limitation error has been requeued, as far as the Galasa RAS is concerned the test is still running. This results in the test being returned by Galasactl runs get with the --active flag when the test has actually long since terminated.

Steps to reproduce

  1. Create a Galasa test class that uses a resource that is limited
  2. Make the test fail due to ResourceLimitation and let it be requeued to run by the Galasa ecosystem a few times
  3. Allow the test to run
  4. Use Galasactl runs get to get list of runs from the last few days
  5. You should see that there are many more runs than there should be for the test that was requeued. There will be many more runs returned to Galasactl runs get than there are entries for couchdb.

Expected behavior

Runs get should return correct number of tests, ideally returning only actively running tests with --active flag

@eamansour
Copy link
Member

eamansour commented Nov 11, 2024

Looks like the duplication of results is a client-side defect in galasactl - added a bit more logging locally and ran galasactl runs get --age 1w, and the results received from the API server were far fewer than the results printed out in the final summary view.

In this example, the API server returned 751 runs:

2024/11/11 18:38:52 Requesting page '1' 
2024/11/11 18:38:53 Received 100 results for page 1 - Number of results: 100
2024/11/11 18:38:53 Requesting page '2' 
2024/11/11 18:38:53 Received 100 results for page 2 - Number of results: 200
2024/11/11 18:38:53 Requesting page '3' 
2024/11/11 18:38:53 Received 100 results for page 3 - Number of results: 300
2024/11/11 18:38:53 Requesting page '4' 
2024/11/11 18:38:53 Received 100 results for page 4 - Number of results: 400
2024/11/11 18:38:53 Requesting page '5' 
2024/11/11 18:38:53 Received 100 results for page 5 - Number of results: 500
2024/11/11 18:38:53 Requesting page '6' 
2024/11/11 18:38:53 Received 100 results for page 6 - Number of results: 600
2024/11/11 18:38:53 Requesting page '7' 
2024/11/11 18:38:54 Received 100 results for page 7 - Number of results: 700
2024/11/11 18:38:54 Requesting page '8' 
2024/11/11 18:38:54 Received 51 results for page 8 - Number of results: 751
2024/11/11 18:38:54 Expected total: 751

But the final summary view showed a total of 1563 runs:

Total:1563 Passed:109 Failed:13 EnvFail:600 Active:841

@techcobweb techcobweb added the defect Something isn't working label Nov 13, 2024
@techcobweb techcobweb self-assigned this Nov 25, 2024
@techcobweb
Copy link
Contributor

This is a client-side issue in the reporting of the tests in the formatting.

@techcobweb
Copy link
Contributor

Fix is here: galasa-dev/cli#310

@techcobweb techcobweb moved this from 🔖 3 Iteration Backlog to 🏗 2 In progress in galasa-dev team Dec 2, 2024
@techcobweb
Copy link
Contributor

delivered

@techcobweb techcobweb moved this from 🏗 2 In progress to ✅ Done - in iteration in galasa-dev team Dec 2, 2024
@techcobweb techcobweb moved this from ✅ Done - in iteration to Done - in previous release in galasa-dev team Dec 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect Something isn't working
Projects
Status: Done - in previous release
Development

No branches or pull requests

3 participants