Fix VSD fails to load on the 1st of the month
What does this MR do and why?
Updates the time periods used on the VSD page, we should calculate date for the current month to date, unless it's the 1st of the month. On the 1st, we should show the previous month as our first time period.
Note: the bugfunctional behaviour in #413872 (closed) occurs with the vsd_graphql_dora_and_flow_metrics
feature flag enabled, but this fix will apply to both the graphql and the REST queries so we have the same behaviour.
Screenshots or screen recordings
Screenshots are required for UI changes, and strongly recommended for all other merge requests.
Before | After |
---|---|
![]() |
![]() |
How to set up and validate locally
You will need a GitLab Ultimate license
- Create a group
- Seed cycle analytics data
- Seed dora metrics data
- Visit the Value streams dashboard
- Apply this patch to test the new behaviour (simulate the 1st of the month)
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #413872 (closed)
Merge request reports
Activity
changed milestone to %16.1
assigned to @ekigbo
marked the checklist item I have evaluated the MR acceptance checklist for this MR. as completed
Diff for testing:
On this branch
diff --git a/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue b/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue index f5707d0d57b5..1ba5112a880c 100644 --- a/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue +++ b/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue @@ -35,7 +35,8 @@ import { } from '../utils'; import ComparisonTable from './comparison_table.vue'; -const now = generateValueStreamDashboardStartDate(); +const fakeDate = new Date('June 1, 2023 11:13:00'); +const now = generateValueStreamDashboardStartDate(fakeDate); const DASHBOARD_TIME_PERIODS = generateDateRanges(now); const CHART_TIME_PERIODS = generateChartTimePeriods(now);
On the master branch
diff --git a/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue b/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue index c8deb182aea8..5edcd841f38c 100644 --- a/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue +++ b/ee/app/assets/javascripts/analytics/dashboards/components/comparison_chart.vue @@ -34,7 +34,7 @@ import { } from '../utils'; import ComparisonTable from './comparison_table.vue'; -const now = new Date(); +const now = new Date('June 1, 2023 11:13:00'); const DASHBOARD_TIME_PERIODS = generateDateRanges(now); const CHART_TIME_PERIODS = generateChartTimePeriods(now);
Edited by Ezekiel Kigbo1 Warning featureaddition and featureenhancement merge requests normally have a documentation change. Consider adding a documentation update or confirming the documentation plan with the Technical Writer counterpart.
For more information, see:
- The Handbook page on merge request types.
- The definition of done documentation.
Reviewer roulette
Changes that require review have been detected!
Please refer to the table below for assigning reviewers and maintainers suggested by Danger in the specified category:
Category Reviewer Maintainer frontend Diana Zubova (
@dzubova
) (UTC+2, 8 hours behind@ekigbo
)Miguel Rincon (
@mrincon
) (UTC+2, 8 hours behind@ekigbo
)To spread load more evenly across eligible reviewers, Danger has picked a candidate for each review slot, based on their timezone. Feel free to override these selections if you think someone else would be better-suited or use the GitLab Review Workload Dashboard to find other available reviewers.
To read more on how to use the reviewer roulette, please take a look at the Engineering workflow and code review guidelines. Please consider assigning a reviewer or maintainer who is a domain expert in the area of the merge request.
Once you've decided who will review this merge request, assign them as a reviewer! Danger does not automatically notify them for you.
If needed, you can retry the
danger-review
job that generated this comment.Generated by
Dangeradded workflowin dev label and removed workflowready for development label
added featureenhancement label
added typefeature label and removed typebug label
Bundle size analysis [beta]
This compares changes in bundle size for entry points between the commits 14056c9a and 7a1bbf8b
Special assetsEntrypoint / Name Size before Size after Diff Diff in percent average 4.12 MB 4.12 MB - 0.0 % mainChunk 3 MB 3 MB - 0.0 %
Note: We do not have exact data for 14056c9a. So we have used data from: 4d335405.
The intended commit has no webpack pipeline, so we chose the last commit with one before it.Please look at the full report for more details
Read more about how this report works.
Generated by
DangerAllure report
allure-report-publisher
generated test report!e2e-test-on-gdk:
test report for 7a1bbf8bexpand test summary
+-----------------------------------------------------------------------+ | suites summary | +------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------+--------+--------+---------+-------+-------+--------+ | Framework sanity | 0 | 0 | 1 | 0 | 1 | ➖ | | Manage | 1 | 0 | 0 | 0 | 1 | ✅ | | Govern | 2 | 0 | 0 | 0 | 2 | ✅ | | Create | 8 | 0 | 1 | 0 | 9 | ✅ | | Plan | 4 | 0 | 0 | 0 | 4 | ✅ | | Monitor | 4 | 0 | 0 | 0 | 4 | ✅ | | Data Stores | 2 | 0 | 0 | 1 | 2 | ❗ | +------------------+--------+--------+---------+-------+-------+--------+ | Total | 21 | 0 | 2 | 1 | 23 | ❗ | +------------------+--------+--------+---------+-------+-------+--------+
e2e-review-qa:
test report for 7a1bbf8bexpand test summary
+-----------------------------------------------------------------------+ | suites summary | +------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------+--------+--------+---------+-------+-------+--------+ | Govern | 2 | 0 | 0 | 0 | 2 | ✅ | | Plan | 50 | 0 | 1 | 0 | 51 | ✅ | | Data Stores | 2 | 0 | 0 | 1 | 2 | ❗ | | Create | 8 | 0 | 1 | 0 | 9 | ✅ | | Manage | 1 | 0 | 0 | 0 | 1 | ✅ | | Framework sanity | 0 | 0 | 1 | 0 | 1 | ➖ | | Monitor | 4 | 0 | 0 | 0 | 4 | ✅ | +------------------+--------+--------+---------+-------+-------+--------+ | Total | 67 | 0 | 3 | 1 | 70 | ❗ | +------------------+--------+--------+---------+-------+-------+--------+
added 123 commits
-
e630044d...0615fdc3 - 122 commits from branch
master
- 66145316 - Fix VSD failure on first day of month
-
e630044d...0615fdc3 - 122 commits from branch
- Resolved by Tristan Read
Hi @apennells, would you be free to review this small fix?
requested review from @apennells
added workflowin review label and removed workflowin dev label
- Resolved by Tristan Read
- Resolved by Tristan Read
- Resolved by Tristan Read
removed review request for @apennells
added 129 commits
-
66145316...0fe10429 - 127 commits from branch
master
- 1a4295db - Fix VSD failure on first day of month
- 7a1bbf8b - Remove unused parameter
-
66145316...0fe10429 - 127 commits from branch
@ekigbo Some end-to-end (E2E) tests have been selected based on the stage label on this MR. If not run already, please run thee2e:package-and-test-ee
job in theqa
stage and review the results before merging this MR. (E2E tests are not run automatically on some MRs due to runner resource constraints.)If you would like to run all e2e tests, please apply the pipeline:run-all-e2e label and restart the pipeline.
Once done, please apply the
emoji on this comment.For any questions or help in reviewing the E2E test results, please reach out on the internal #quality Slack channel.
requested review from @tristan.read
@tristan.read
, thanks for approving this merge request.This is the first time the merge request is approved. To ensure full test coverage, a new pipeline will be started shortly.
For more info, please refer to the following links:
added pipeline:mr-approved label
enabled an automatic merge when the pipeline for 15ed604f succeeds
mentioned in commit f49d3bc6
added workflowstaging-canary label and removed workflowin review label
added workflowcanary label and removed workflowstaging-canary label
added workflowstaging label and removed workflowcanary label
added workflowproduction label and removed workflowstaging label
added workflowpost-deploy-db-staging label and removed workflowproduction label
added workflowpost-deploy-db-production label and removed workflowpost-deploy-db-staging label
added releasedcandidate label
mentioned in merge request kubitus-project/kubitus-installer!2224 (merged)
added releasedpublished label and removed releasedcandidate label