The error returned by 'MakeReview' is ignored. Always check return values from service methods to handle potential failures correctly and ensure the process exits with the correct status code.
The error returned by 'MakeReview' is ignored. Always check return values from service methods to handle potential failures correctly and ensure the process exits with the correct status code.
Service methods should return errors instead of calling 'log.Fatalf'. Terminating the process from within a service layer makes it difficult to test and prevents callers from performing cleanups.
Service methods should return errors instead of calling 'log.Fatalf'. Terminating the process from within a service layer makes it difficult to test and prevents callers from performing cleanups.
The 'ctx' parameter is ignored; 'context.Background()' is used instead. Use the provided context to ensure that cancellation signals and timeouts are properly propagated.
The 'ctx' parameter is ignored; 'context.Background()' is used instead. Use the provided context to ensure that cancellation signals and timeouts are properly propagated.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
378d008a91to9bd7d363ba9bd7d363batodb1ecd1e64@@ -92,2 +116,2 @@c.File, c.Line, c.Message, "---")}pierreService := pierre.New(ai, git)pierreService.MakeReview(context.Background(), cfg.Repo.Owner, cfg.Repo.Repo, cfg.Repo.PRID)The error returned by 'MakeReview' is ignored. Always check return values from service methods to handle potential failures correctly and ensure the process exits with the correct status code.
@@ -0,0 +10,4 @@// Fetch Diff using positional args from shared RepoArgsdiff, err := s.git.GetDiff(organisation, repo, prID)if err != nil {log.Fatalf("Error fetching diff: %v", err)Service methods should return errors instead of calling 'log.Fatalf'. Terminating the process from within a service layer makes it difficult to test and prevents callers from performing cleanups.
@@ -0,0 +14,4 @@}// Run Logiccomments, err := s.judgePR(context.Background(), diff)The 'ctx' parameter is ignored; 'context.Background()' is used instead. Use the provided context to ensure that cancellation signals and timeouts are properly propagated.
@@ -0,0 +16,4 @@// Run Logiccomments, err := s.judgePR(context.Background(), diff)if err != nil {log.Fatalf("Error judging PR: %v", err)Return the error to the caller instead of using 'log.Fatalf'. Library and service code should not dictate process termination.
db1ecd1e64to9d49d94eff