This is an automated email from the ASF dual-hosted git repository.
abeizn pushed a commit to branch fix-6510
in repository https://gitbox.apache.org/repos/asf/incubator-devlake.git
The following commit(s) were added to refs/heads/fix-6510 by this push:
new 8f5c5940e fix: panic during github_graphql task when grabbing
deployments
8f5c5940e is described below
commit 8f5c5940ef0faf4afd24089ba922f14110d9f879
Author: abeizn <[email protected]>
AuthorDate: Fri Nov 24 17:25:21 2023 +0800
fix: panic during github_graphql task when grabbing deployments
---
.../plugins/github_graphql/tasks/deployment_collector_extractor.go | 5 -----
1 file changed, 5 deletions(-)
diff --git
a/backend/plugins/github_graphql/tasks/deployment_collector_extractor.go
b/backend/plugins/github_graphql/tasks/deployment_collector_extractor.go
index 8d7e03e38..fa8db34e4 100644
--- a/backend/plugins/github_graphql/tasks/deployment_collector_extractor.go
+++ b/backend/plugins/github_graphql/tasks/deployment_collector_extractor.go
@@ -104,15 +104,11 @@ func CollectAndExtractDeployments(taskCtx
plugin.SubTaskContext) errors.Error {
if collectorWithState.Since != nil {
since = helper.DateTime{Time: *collectorWithState.Since}
}
- enableSince := false
err =
collectorWithState.InitGraphQLCollector(helper.GraphqlCollectorArgs{
GraphqlClient: data.GraphqlClient,
PageSize: 100,
BuildQuery: func(reqData *helper.GraphqlRequestData)
(interface{}, map[string]interface{}, error) {
- if enableSince {
- return nil, nil, nil
- }
query := &GraphqlQueryDeploymentWrapper{}
variables := make(map[string]interface{})
if reqData == nil {
@@ -138,7 +134,6 @@ func CollectAndExtractDeployments(taskCtx
plugin.SubTaskContext) errors.Error {
for _, deployment := range deployments {
//Skip deployments with createdAt earlier than
'since'
if deployment.CreatedAt.Before(since.Time) {
- enableSince = true
continue
}
githubDeployment, err :=
convertGithubDeployment(deployment, data.Options.ConnectionId,
data.Options.GithubId)