You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@devlake.apache.org by ab...@apache.org on 2024/08/28 10:32:26 UTC
(incubator-devlake) branch main updated: fix: work logs no code data (#7977)
This is an automated email from the ASF dual-hosted git repository.
abeizn pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
The following commit(s) were added to refs/heads/main by this push:
new 985aee7ad fix: work logs no code data (#7977)
985aee7ad is described below
commit 985aee7ad4a0a3daeb7d121b65120dcc3aaae1ed
Author: abeizn <zi...@merico.dev>
AuthorDate: Wed Aug 28 18:32:20 2024 +0800
fix: work logs no code data (#7977)
* fix: work logs no code data
* fix: oss migration logs
---
backend/server/services/init.go | 2 +-
grafana/dashboards/WorkLogs.json | 13 +++++++------
2 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/backend/server/services/init.go b/backend/server/services/init.go
index df6308fad..894ffa09a 100644
--- a/backend/server/services/init.go
+++ b/backend/server/services/init.go
@@ -141,7 +141,7 @@ func ExecuteMigration() errors.Error {
statusLock.Lock()
if serviceStatus == SERVICE_STATUS_MIGRATING {
statusLock.Unlock()
- return errors.BadInput.New("already migrating")
+ return errors.BadInput.New("There is a migration in progress.")
}
if serviceStatus == SERVICE_STATUS_READY {
statusLock.Unlock()
diff --git a/grafana/dashboards/WorkLogs.json b/grafana/dashboards/WorkLogs.json
index d025e6d5d..d546f01c2 100644
--- a/grafana/dashboards/WorkLogs.json
+++ b/grafana/dashboards/WorkLogs.json
@@ -18,7 +18,7 @@
"editable": true,
"fiscalYearStartMonth": 0,
"graphTooltip": 0,
- "id": 20,
+ "id": 47,
"links": [],
"liveNow": false,
"panels": [
@@ -566,6 +566,7 @@
"showValue": "auto",
"stacking": "normal",
"tooltip": {
+ "maxHeight": 600,
"mode": "single",
"sort": "none"
},
@@ -704,6 +705,7 @@
"values": true
},
"tooltip": {
+ "maxHeight": 600,
"mode": "single",
"sort": "none"
}
@@ -787,7 +789,7 @@
"editorMode": "code",
"format": "table",
"rawQuery": true,
- "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n)\n\nSELECT count(distinct c.sha)\nFROM commits c\njoin _accounts a on c.author_id = a.account_id\nwhere $__timeFilter(authored_date)\n",
+ "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name, u.email\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n)\n\nSELECT count(distinct c.sha)\nFROM commits c\njoin _accounts a on c.author_id = a.email\nwhere $__timeFilter(authored_date)\n",
"refId": "A",
"sql": {
"columns": [
@@ -860,7 +862,7 @@
"editorMode": "code",
"format": "table",
"rawQuery": true,
- "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n),\n\n\n_commits as (\n SELECT distinct DATE_FORMAT(authored_date, '%d/%m/%Y') as Date, authored_date as Time, 'Finish a commit' as Activity, concat(message, ' #', sha) as Details, a.name as Name, c.additions, c.deletions\n FROM commits c\n join _accounts a o [...]
+ "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name, u.email\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n),\n\n\n_commits as (\n SELECT distinct DATE_FORMAT(authored_date, '%d/%m/%Y') as Date, authored_date as Time, 'Finish a commit' as Activity, concat(message, ' #', sha) as Details, a.name as Name, c.additions, c.deletions\n FROM commits c\n join _acc [...]
"refId": "A",
"sql": {
"columns": [
@@ -1109,6 +1111,7 @@
"valueSize": 12
},
"tooltip": {
+ "maxHeight": 600,
"mode": "single",
"sort": "none"
},
@@ -1231,7 +1234,7 @@
"editorMode": "code",
"format": "table",
"rawQuery": true,
- "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n),\n\n\n_commits as (\n SELECT distinct DATE_FORMAT(authored_date, '%d/%m/%Y') as Date, authored_date as Time, 'Finish a commit' as Activity, concat(message, ' #', sha) as Details, a.name as Name, c.additions, c.deletions, c.sha\n FROM commits c\n join _accou [...]
+ "rawSql": "with _accounts as (\n select ua.account_id, ua.user_id, u.name, u.email\n from accounts a \n join user_accounts ua on a.id = ua.account_id\n join users u on ua.user_id = u.id\n where ua.user_id in ($users)\n),\n\n\n_commits as (\n SELECT distinct DATE_FORMAT(authored_date, '%d/%m/%Y') as Date, authored_date as Time, 'Finish a commit' as Activity, concat(message, ' #', sha) as Details, a.name as Name, c.additions, c.deletions, c.sha\n FROM commits c\n jo [...]
"refId": "A",
"sql": {
"columns": [
@@ -1414,7 +1417,6 @@
"list": [
{
"current": {
- "isNone": true,
"selected": false,
"text": "None",
"value": ""
@@ -1446,7 +1448,6 @@
},
"datasource": "mysql",
"definition": "select concat(users.name, '--', users.id) from users left join team_users on users.id = team_users.user_id where team_users.team_id in ($team)",
- "error": {},
"hide": 0,
"includeAll": true,
"label": "User",