openshift-helm-charts / development

0 stars 17 forks source link

Unbound variable in our Test Workflows scripts #291

Closed komish closed 10 months ago

komish commented 10 months ago
2023-11-03T03:54:58.5075864Z Feature: Report only submission # tests/functional/behave_features/HC-12_report_without_chart.feature:1
2023-11-03T03:54:58.5077169Z   Partners, redhat and community users can publish their chart by submitting
2023-11-03T03:54:59.7515838Z   error-free report that was generated by chart-verifier.
2023-11-03T03:54:59.7517009Z   @partners @smoke @full
2023-11-03T03:54:59.7519677Z   Scenario Outline: [HC-12-001] A partner or redhat associate submits an error-free report -- @1.1   # tests/functional/behave_features/HC-12_report_without_chart.feature:16
2023-11-03T03:54:59.7522034Z     Given the vendor "hashicorp" has a valid identity as "partners"                                  # tests/functional/behave_features/steps/implementation.py:6
2023-11-03T03:54:59.7524551Z     And an error-free report is used in "tests/data/common/partner/report.yaml"                      # tests/functional/behave_features/steps/implementation.py:149
2023-11-03T03:55:03.1858473Z     When the user sends a pull request with the report                                               # tests/functional/behave_features/steps/implementation.py:268
2023-11-03T03:55:04.1691558Z     Then the user sees the pull request is merged                                                    # tests/functional/behave_features/steps/implementation.py:281
2023-11-03T03:57:46.2594994Z     And the index.yaml file is updated with an entry for the submitted chart                         # tests/functional/behave_features/steps/implementation.py:288
2023-11-03T03:57:47.7532014Z     And a release is published with report only                                                      # tests/functional/behave_features/steps/implementation.py:293
2023-11-03T03:58:03.1554926Z       Traceback (most recent call last):
2023-11-03T03:58:03.1568614Z         File "/home/runner/work/development/development/tests/functional/behave_features/common/utils/chart_certification.py", line 271, in check_release_result
2023-11-03T03:58:03.1570253Z           release = get_release_by_tag(self.secrets, expected_tag)
2023-11-03T03:58:03.1571925Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/retrying.py", line 49, in wrapped_f
2023-11-03T03:58:03.1573151Z           return Retrying(*dargs, **dkw).call(f, *args, **kw)
2023-11-03T03:58:03.1574516Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/retrying.py", line 212, in call
2023-11-03T03:58:03.1575627Z           raise attempt.get()
2023-11-03T03:58:03.1576810Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/retrying.py", line 247, in get
2023-11-03T03:58:03.1578014Z           six.reraise(self.value[0], self.value[1], self.value[2])
2023-11-03T03:58:03.1579831Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/six.py", line 719, in reraise
2023-11-03T03:58:03.1581121Z           raise value
2023-11-03T03:58:03.1582761Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/retrying.py", line 200, in call
2023-11-03T03:58:03.1584152Z           attempt = Attempt(fn(*args, **kwargs), attempt_number, False)
2023-11-03T03:58:03.1585795Z         File "/home/runner/work/development/development/tests/functional/behave_features/common/utils/github.py", line 66, in get_release_by_tag
2023-11-03T03:58:03.1587013Z           raise Exception("Release not published")
2023-11-03T03:58:03.1587547Z       Exception: Release not published
2023-11-03T03:58:03.1588102Z       
2023-11-03T03:58:03.1588625Z       During handling of the above exception, another exception occurred:
2023-11-03T03:58:03.1589276Z       
2023-11-03T03:58:03.1589621Z       Traceback (most recent call last):
2023-11-03T03:58:03.1591012Z         File "/home/runner/work/development/development/tests/functional/behave_features/common/utils/chart_certification.py", line 299, in check_release_result
2023-11-03T03:58:03.1592542Z           raise AssertionError(e)
2023-11-03T03:58:03.1593046Z       AssertionError: Release not published
2023-11-03T03:58:03.1593531Z       
2023-11-03T03:58:03.1594039Z       During handling of the above exception, another exception occurred:
2023-11-03T03:58:03.1595652Z       
2023-11-03T03:58:03.1596039Z       Traceback (most recent call last):
2023-11-03T03:58:03.1597508Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/behave/model.py", line 1329, in run
2023-11-03T03:58:03.1599363Z           match.run(runner.context)
2023-11-03T03:58:03.1600667Z         File "/home/runner/work/development/development/ve1/lib/python3.9/site-packages/behave/matchers.py", line 98, in run
2023-11-03T03:58:03.1602535Z           self.func(context, *args, **kwargs)
2023-11-03T03:58:03.1603723Z         File "tests/functional/behave_features/steps/implementation.py", line 295, in release_is_published
2023-11-03T03:58:03.1604955Z           context.workflow_test.check_release_result(release_type=Release_Type.REPORT_ONLY)
2023-11-03T03:58:03.1606829Z         File "/home/runner/work/development/development/tests/functional/behave_features/common/utils/chart_certification.py", line 935, in check_release_result
2023-11-03T03:58:03.1608267Z           super().check_release_result(
2023-11-03T03:58:03.1609786Z         File "/home/runner/work/development/development/tests/functional/behave_features/common/utils/chart_certification.py", line 307, in check_release_result
2023-11-03T03:58:03.1611409Z           f"repos/{self.secrets.test_repo}/releases/{release_id}",
2023-11-03T03:58:03.1612410Z       UnboundLocalError: local variable 'release_id' referenced before assignment

This was discovered in the "Test Workflows" action, where we run smoke tests on PRs.