klesh commented on code in PR #8972:
URL: https://github.com/apache/devlake/pull/8972#discussion_r3522493592


##########
backend/plugins/jira/impl/impl.go:
##########
@@ -249,6 +251,22 @@ func (p Jira) PrepareTaskData(taskCtx plugin.TaskContext, 
options map[string]int
                Options:        &op,
                ApiClient:      jiraApiClient,
                JiraServerInfo: *info,
+               Board:          scope,
+       }
+
+       // Look up the DevLake project this board belongs to via 
project_mapping.
+       // This is best-effort: if the board is not yet mapped (e.g. first run 
or
+       // manual trigger outside a blueprint) we leave DevLakeProjectName 
empty.
+       if scope != nil {

Review Comment:
   I see why you did it – the `projectName` is not available for the data 
source plugin.
   However, the solution seems too hacky and ad hoc.
   We need a better solution:
   1. adding the `projectName` to the `DataSourcePluginBlueprintV200` interface
   2. adding a new user-definable column to `Board` and using it instead of the 
`projectName` variable.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to