Add multi teams support and update seat management tab to suppoft filter when clicking a card.
1, add teams support like multi-team dashboards. 2, for seat managemnet, display more cards and when click a card, it will filter the data, only show filter data in below tables.
This pull request introduces several changes to the project, focusing on adding support for multiple teams, improving error handling, and updating configurations. The most important changes include updates to environment variables, modifications to the Dockerfile, enhancements in API handling, and new components for multi-team metrics.
Environment Variable Updates:
.env: UpdatedVUE_APP_GITHUB_ORGtoCopilotDemoand addedVUE_APP_SHOW_MULTIPLE_TEAMSto support multiple teams. [1] [2]README.md: Documented the newVUE_APP_SHOW_MULTIPLE_TEAMSenvironment variable.
Dockerfile Modifications:
Dockerfile: Changed the base image tonode:22, added commands to update thecaniuse-litedatabase, fix ESLint errors, and handle build errors.Dockerfile: Added command to start the Nginx server.
API Enhancements:
src/api/GitHubApi.ts: Refactored API calls to handle multiple teams, added error handling, and improved the fetching of team metrics. [1] [2]
Component Updates for Multi-Team Support:
src/components/MainComponent.vue: Integrated a newMultiTeamsMetricsViewercomponent and updated logic to handle multiple teams. [1] [2] [3] [4] [5] [6]src/components/MetricsViewer.vue: Combined data by day for better visualization and updated charts accordingly. [1] [2]
Minor Updates:
public/assets/app-config.js: AddedVUE_APP_SHOW_MULTIPLE_TEAMSto the configuration.src/App.vue: Updated footer text and version number. [1] [2]src/api/MetricsToUsageConverter.ts: Commented out debug logs.
I'll work on the merge
Hi @DevOps-zhuang,
I was trying to use multi teams support which is implemented in this branch before it gets merged into the main branch. While attempting to build a Docker image using the code from this branch, I encountered the following error:
[nuxi] ERROR Nuxt Build Error: Could not resolve "../api/GitHubApi" from "app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts"
10.89 file: /app/app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89
10.89 file: app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89 at getRollupError (node_modules/rollup/dist/es/shared/parseAst.js:396:41)
10.89 at error (node_modules/rollup/dist/es/shared/parseAst.js:392:42)
10.89 at ModuleLoader.handleInvalidResolvedId (node_modules/rollup/dist/es/shared/node-entry.js:20212:24)
10.89 at node_modules/rollup/dist/es/shared/node-entry.js:20172:26
Could you please look into this and suggest a resolution? Alternatively, let me know if any dependencies or configurations need to be updated for this feature to work seamlessly when building Docker images.
Thanks & Regards, Satish
the merge is not complete on this, it needs more changes
I think the issue is caused that this branch version is not using he Nuxt framework. I you needed, I can share my docker image so that you can use it quickly? Thanks.
Jun Qian.
发件人: Pardhusri Satish Babu Obulasetti @.> 发送时间: 2025年3月21日 17:39 收件人: github-copilot-resources/copilot-metrics-viewer @.> 抄送: Junqian Zhuang @.>; Mention @.> 主题: Re: [github-copilot-resources/copilot-metrics-viewer] Add multi teams support and update seat management tab to suppoft filter when clicking a card. (PR #177)
Hi @DevOps-zhuanghttps://github.com/DevOps-zhuang,
I was trying to use multi teams support which is implemented in this branch before it gets merged into the main branch. While attempting to build a Docker image using the code from this branch, I encountered the following error:
[nuxi] ERROR Nuxt Build Error: Could not resolve "../api/GitHubApi" from "app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts"
10.89 file: /app/app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89
10.89 file: app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89 at getRollupError (node_modules/rollup/dist/es/shared/parseAst.js:396:41)
10.89 at error (node_modules/rollup/dist/es/shared/parseAst.js:392:42)
10.89 at ModuleLoader.handleInvalidResolvedId (node_modules/rollup/dist/es/shared/node-entry.js:20212:24)
10.89 at node_modules/rollup/dist/es/shared/node-entry.js:20172:26
Could you please look into this and suggest a resolution? Alternatively, let me know if any dependencies or configurations need to be updated for this feature to work seamlessly when building Docker images.
Thanks & Regards, Satish
― Reply to this email directly, view it on GitHubhttps://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2742826050, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AM4XDKDCF3N4YQBCDRH7LUT2VPMZTAVCNFSM6AAAAABZAGEWV2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDONBSHAZDMMBVGA. You are receiving this because you were mentioned.Message ID: @.***> [图像已被发件人删除。 paobulas]paobulas left a comment (github-copilot-resources/copilot-metrics-viewer#177)https://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2742826050
Hi @DevOps-zhuanghttps://github.com/DevOps-zhuang,
I was trying to use multi teams support which is implemented in this branch before it gets merged into the main branch. While attempting to build a Docker image using the code from this branch, I encountered the following error:
[nuxi] ERROR Nuxt Build Error: Could not resolve "../api/GitHubApi" from "app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts"
10.89 file: /app/app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89
10.89 file: app/components/MultiTeamsMetricsViewer.vue?vue&type=script&lang.ts
10.89 at getRollupError (node_modules/rollup/dist/es/shared/parseAst.js:396:41)
10.89 at error (node_modules/rollup/dist/es/shared/parseAst.js:392:42)
10.89 at ModuleLoader.handleInvalidResolvedId (node_modules/rollup/dist/es/shared/node-entry.js:20212:24)
10.89 at node_modules/rollup/dist/es/shared/node-entry.js:20172:26
Could you please look into this and suggest a resolution? Alternatively, let me know if any dependencies or configurations need to be updated for this feature to work seamlessly when building Docker images.
Thanks & Regards, Satish
― Reply to this email directly, view it on GitHubhttps://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2742826050, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AM4XDKDCF3N4YQBCDRH7LUT2VPMZTAVCNFSM6AAAAABZAGEWV2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDONBSHAZDMMBVGA. You are receiving this because you were mentioned.Message ID: @.***>
@DevOps-zhuang could you please share me the docker image?
@DevOps-zhuang could you please share me the docker image?
will send you
@DevOps-zhuang could you please share me the docker image?
docker login -u metricviewer -p XXX copilotx.azurecr.io
docker pull copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport
Hi @DevOps-zhuang,
Thank you for sharing the Docker image.
Unfortunately, I am unable to get any output from the web page when using your Docker image (copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport).
Docker output log:
paobulas@ubuntu ~/workspace/GitHub-Copilot-Metrics/copilot-metrics-viewer-zhuang
% docker run -p 8080:80 --env-file ./.env copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport
/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: Getting the checksum of /etc/nginx/conf.d/default.conf
10-listen-on-ipv6-by-default.sh: info: Enabled listen on IPv6 in /etc/nginx/conf.d/default.conf
/docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/99-config-app.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
2025/03/27 16:00:59 [notice] 1#1: using the "epoll" event method
2025/03/27 16:00:59 [notice] 1#1: nginx/1.27.2
2025/03/27 16:00:59 [notice] 1#1: built by gcc 12.2.0 (Debian 12.2.0-14)
2025/03/27 16:00:59 [notice] 1#1: OS: Linux 6.8.0-1021-azure
2025/03/27 16:00:59 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576
2025/03/27 16:00:59 [notice] 1#1: start worker processes
2025/03/27 16:00:59 [notice] 1#1: start worker process 31
2025/03/27 16:00:59 [notice] 1#1: start worker process 32
2025/03/27 16:00:59 [notice] 1#1: start worker process 33
2025/03/27 16:00:59 [notice] 1#1: start worker process 34
2025/03/27 16:00:59 [notice] 1#1: start worker process 35
2025/03/27 16:00:59 [notice] 1#1: start worker process 36
2025/03/27 16:00:59 [notice] 1#1: start worker process 37
2025/03/27 16:00:59 [notice] 1#1: start worker process 38
2025/03/27 16:00:59 [notice] 1#1: start worker process 39
2025/03/27 16:00:59 [notice] 1#1: start worker process 40
2025/03/27 16:00:59 [notice] 1#1: start worker process 41
2025/03/27 16:00:59 [notice] 1#1: start worker process 42
172.17.0.1 - - [27/Mar/2025:16:01:05 +0000] "GET /assets/app-config.js HTTP/1.1" 200 447 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:02:03 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:07:07 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
Could you please help me resolve this issue? Or have I missed something here?
Are u tying against organization? It support organization level, and the .env should be look like below: The VUE_APP_SHOW_MULTIPLE_TEAMS=true
@.***
发件人: Pardhusri Satish Babu Obulasetti @.> 发送时间: 2025年3月28日 0:14 收件人: github-copilot-resources/copilot-metrics-viewer @.> 抄送: Junqian Zhuang @.>; Mention @.> 主题: Re: [github-copilot-resources/copilot-metrics-viewer] Add multi teams support and update seat management tab to suppoft filter when clicking a card. (PR #177)
Hi @DevOps-zhuanghttps://github.com/DevOps-zhuang,
Thank you for sharing the Docker image.
Unfortunately, I am unable to get any output from the web page when using your Docker image (copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport).
Docker output log:
@.*** ~/workspace/GitHub-Copilot-Metrics/copilot-metrics-viewer-zhuang
% docker run -p 8080:80 --env-file ./.env copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport
/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: Getting the checksum of /etc/nginx/conf.d/default.conf
10-listen-on-ipv6-by-default.sh: info: Enabled listen on IPv6 in /etc/nginx/conf.d/default.conf
/docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/99-config-app.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
2025/03/27 16:00:59 [notice] 1#1: using the "epoll" event method
2025/03/27 16:00:59 [notice] 1#1: nginx/1.27.2
2025/03/27 16:00:59 [notice] 1#1: built by gcc 12.2.0 (Debian 12.2.0-14)
2025/03/27 16:00:59 [notice] 1#1: OS: Linux 6.8.0-1021-azure
2025/03/27 16:00:59 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576
2025/03/27 16:00:59 [notice] 1#1: start worker processes
2025/03/27 16:00:59 [notice] 1#1: start worker process 31
2025/03/27 16:00:59 [notice] 1#1: start worker process 32
2025/03/27 16:00:59 [notice] 1#1: start worker process 33
2025/03/27 16:00:59 [notice] 1#1: start worker process 34
2025/03/27 16:00:59 [notice] 1#1: start worker process 35
2025/03/27 16:00:59 [notice] 1#1: start worker process 36
2025/03/27 16:00:59 [notice] 1#1: start worker process 37
2025/03/27 16:00:59 [notice] 1#1: start worker process 38
2025/03/27 16:00:59 [notice] 1#1: start worker process 39
2025/03/27 16:00:59 [notice] 1#1: start worker process 40
2025/03/27 16:00:59 [notice] 1#1: start worker process 41
2025/03/27 16:00:59 [notice] 1#1: start worker process 42
172.17.0.1 - - [27/Mar/2025:16:01:05 +0000] "GET /assets/app-config.js HTTP/1.1" 200 447 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:02:03 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:07:07 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
Screenshot.from.2025-03-27.21-37-22.png (view on web)https://github.com/user-attachments/assets/cae2cbcd-8f62-414d-89de-62c1ed67dc4e
Could you please help me resolve this issue? Or have I missed something here?
― Reply to this email directly, view it on GitHubhttps://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2758616352, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AM4XDKBBZT5DWOZEEDZYL3L2WQPVPAVCNFSM6AAAAABZAGEWV2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDONJYGYYTMMZVGI. You are receiving this because you were mentioned.Message ID: @.***> [图像已被发件人删除。 paobulas]paobulas left a comment (github-copilot-resources/copilot-metrics-viewer#177)https://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2758616352
Hi @DevOps-zhuanghttps://github.com/DevOps-zhuang,
Thank you for sharing the Docker image.
Unfortunately, I am unable to get any output from the web page when using your Docker image (copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport).
Docker output log:
@.*** ~/workspace/GitHub-Copilot-Metrics/copilot-metrics-viewer-zhuang
% docker run -p 8080:80 --env-file ./.env copilotx.azurecr.io/copilot/copilot-metrics-viewer:2025-0226-MultiTeamsSupport
/docker-entrypoint.sh: /docker-entrypoint.d/ is not empty, will attempt to perform configuration
/docker-entrypoint.sh: Looking for shell scripts in /docker-entrypoint.d/
/docker-entrypoint.sh: Launching /docker-entrypoint.d/10-listen-on-ipv6-by-default.sh
10-listen-on-ipv6-by-default.sh: info: Getting the checksum of /etc/nginx/conf.d/default.conf
10-listen-on-ipv6-by-default.sh: info: Enabled listen on IPv6 in /etc/nginx/conf.d/default.conf
/docker-entrypoint.sh: Sourcing /docker-entrypoint.d/15-local-resolvers.envsh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/20-envsubst-on-templates.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/30-tune-worker-processes.sh
/docker-entrypoint.sh: Launching /docker-entrypoint.d/99-config-app.sh
/docker-entrypoint.sh: Configuration complete; ready for start up
2025/03/27 16:00:59 [notice] 1#1: using the "epoll" event method
2025/03/27 16:00:59 [notice] 1#1: nginx/1.27.2
2025/03/27 16:00:59 [notice] 1#1: built by gcc 12.2.0 (Debian 12.2.0-14)
2025/03/27 16:00:59 [notice] 1#1: OS: Linux 6.8.0-1021-azure
2025/03/27 16:00:59 [notice] 1#1: getrlimit(RLIMIT_NOFILE): 1048576:1048576
2025/03/27 16:00:59 [notice] 1#1: start worker processes
2025/03/27 16:00:59 [notice] 1#1: start worker process 31
2025/03/27 16:00:59 [notice] 1#1: start worker process 32
2025/03/27 16:00:59 [notice] 1#1: start worker process 33
2025/03/27 16:00:59 [notice] 1#1: start worker process 34
2025/03/27 16:00:59 [notice] 1#1: start worker process 35
2025/03/27 16:00:59 [notice] 1#1: start worker process 36
2025/03/27 16:00:59 [notice] 1#1: start worker process 37
2025/03/27 16:00:59 [notice] 1#1: start worker process 38
2025/03/27 16:00:59 [notice] 1#1: start worker process 39
2025/03/27 16:00:59 [notice] 1#1: start worker process 40
2025/03/27 16:00:59 [notice] 1#1: start worker process 41
2025/03/27 16:00:59 [notice] 1#1: start worker process 42
172.17.0.1 - - [27/Mar/2025:16:01:05 +0000] "GET /assets/app-config.js HTTP/1.1" 200 447 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:02:03 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:07:07 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET / HTTP/1.1" 304 0 "-" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
172.17.0.1 - - [27/Mar/2025:16:08:25 +0000] "GET /assets/app-config.js HTTP/1.1" 304 0 "http://localhost:8080/" "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/134.0.0.0 Safari/537.36" "-"
Screenshot.from.2025-03-27.21-37-22.png (view on web)https://github.com/user-attachments/assets/cae2cbcd-8f62-414d-89de-62c1ed67dc4e
Could you please help me resolve this issue? Or have I missed something here?
― Reply to this email directly, view it on GitHubhttps://github.com/github-copilot-resources/copilot-metrics-viewer/pull/177#issuecomment-2758616352, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AM4XDKBBZT5DWOZEEDZYL3L2WQPVPAVCNFSM6AAAAABZAGEWV2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDONJYGYYTMMZVGI. You are receiving this because you were mentioned.Message ID: @.***>
@DevOps-zhuang,
I am using it for organization only. Still I am unable to see any metrics.
Please find my .env file details below:
# Determines if mocked data should be used instead of making API calls.
NUXT_PUBLIC_IS_DATA_MOCKED=false
# Determines the scope of the API calls.
# Can be 'enterprise' or 'organization' to target API calls to an enterprise or an organization respectively.
NUXT_PUBLIC_SCOPE=organization
# Determines the enterprise or organization name to target API calls.
NUXT_PUBLIC_GITHUB_ORG=<My organization name>
NUXT_PUBLIC_GITHUB_ENT=
# Determines the team name if exists to target API calls.
NUXT_PUBLIC_GITHUB_TEAM=
NUXT_PUBLIC_USING_GITHUB_AUTH=false
# Determines the GitHub Personal Access Token to use for API calls.
# Create with scopes copilot, manage_billing:copilot or manage_billing:enterprise, read:enterprise AND read:org
NUXT_GITHUB_TOKEN=<my pat token>
NUXT_SESSION_PASSWORD=TOUXIQsPl5kbCJ0qnBV2R7i56Nft42Gl
# for Github OAuth
# NUXT_OAUTH_GITHUB_CLIENT_ID=
# NUXT_OAUTH_GITHUB_CLIENT_SECRET=
# Determines if the application should support multiple teams.
VUE_APP_SHOW_MULTIPLE_TEAMS=true
# to use a corporate proxy
# HTTP_PROXY=http://proxy.company.com:8080
@karpikpl @paobulas Thanks's for your support, I just update the latest code to support NUXT, it works on my machines now, can you check the latest code? the branch is same: https://github.com/DevOps-zhuang/copilot-metrics-viewer/tree/add-multi-teams-support
@paobulas thanks's for your patience, for the docker image I provides, please use the old .env, which is like below. and I just updated my branch to support NUXT, hope it can run on your environment with the latest change as well, thanks. Uploading .env.md…
docke image is also built based on this branch, I already tested it, it works. https://github.com/DevOps-zhuang/copilot-metrics-viewer/pkgs/container/copilot-metrics-viewer/385109083?tag=add-multi-teams-support
@DevOps-zhuang i tested changes from your branch and the data is displayed in table. However it was observed that panels below the table are not reflecting as per selection.
@DevOps-zhuang i tested changes from your branch and the data is displayed in table. However it was observed that panels below the table are not reflecting as per selection.
Thanks, you found a bug! it worked in non-Nuxt version, and for Nuxt version, I need to do some changes, I am fixing it now, thanks for your test!
@DevOps-zhuang During testing I found differnce between 'Total Suggestions' in Home page and in 'Multi-Teams' page and corresponding metrics.
I’m unable to find an API that lists teams in GitHub Enterprise to find Teams slug. Is this the reason to not support 'Multi-Teams' at enterprise level? Any idea if the API is in development?
@DevOps-zhuang During testing I found differnce between 'Total Suggestions' in Home page and in 'Multi-Teams' page and corresponding metrics. Yes, it is always different, for organization level. the 'Total Suggestions' in Home (Metric Page) is always grater than the one in 'Mulit-Teams' page. the main scenarios are not limited to below:
- there are copilot seats belong to Organization directly, not belong to team. 2)for some teams, or some days for some teams, there are less than 5 copilot seats, so there is no metric fetched from github API, so it is not counted in team level, however, such data are in organization level.
I’m unable to find an API that lists teams in GitHub Enterprise to find Teams slug. Is this the reason to not support 'Multi-Teams' at enterprise level? Any idea if the API is in development? Yes, your observation is quite good! there is no API to get teams from enterprise level, since teams are always in organization level. it is teams-->organization-->enterprise. so we don't support 'Multi-teams' against enterprise level.
but, there is one specified enterprise called dedicated enterprise/copilot standalone, with such enterprise, there is no organization at all. so teams are within enterprise level. I am considering adding support for it in future. need more design, since it takes effort to tell it is 'normal' enterprise or 'dedicated' enterprise.
And, since we support Nuxt now, you can change the URL in the brower to fetch for more organization, even special team. like https://[youserver]/orgs/[yourorgname], it will show multi-teams support for specified org.
thanks for your test and observation!
@DevOps-zhuang Is this feature ready? If so, could you please merge it into the main branch?
Also, are there any plans to implement health checks on the dashboard to surface backend errors?
@DevOps-zhuang - I've merged team metrics - can you test? I don't have access to an org that's big enough :/
@karpikpl I did a quick test, and it works, and I am adding more comments:
-
it is better to add a table view to compare more teams, as a add-on to current graph reports.
-
since the API support fetching more than 28 days, like >60 days. however, in my test, it is still fixed to 28 days,
and I am also posting some snapshot from my branch, just FYI>
@DevOps-zhuang so what happens when you change the time range? on my mock data, changing the dates does apply to teams tab.
I can add multi-teams tab, I was worried it's going to be a lot of API calls
1, curre tly, by default, it will show latest 28 days metrics. like for today, it is 7/15 to 8/11 on my real test.
2, once I select the date range, like 06/15 to 8/11. it works. like below:
3. when I selected time ranger which is not valid, like older than 05/02, a 422 error occurs, like below
so I am wonderring maybe it is better to just limit the time range to the scope the API get by default, disable the otehr selection, just like the below. anyway, it works now, maybe I can add such limit later this week.