Skip to content

Commit

Permalink
Minor iterator print fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
frikky committed Nov 27, 2024
1 parent fb55e48 commit 203f342
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
7 changes: 5 additions & 2 deletions db-connector.go
Original file line number Diff line number Diff line change
Expand Up @@ -6818,7 +6818,10 @@ func GetUserApps(ctx context.Context, userId string) ([]WorkflowApp, error) {
if err != nil {

if !strings.Contains(fmt.Sprintf("%s", err), "cannot load field") {
log.Printf("[ERROR] Failed fetching user apps (1): %v", err)

if !strings.Contains(fmt.Sprintf("%s", err), "no more items") {
log.Printf("[ERROR] Failed fetching user apps (1): %v", err)
}

if strings.Contains("no matching index found", fmt.Sprintf("%s", err)) {
log.Printf("[ERROR] No more apps for %s in user app load? Breaking: %s.", userId, err)
Expand Down Expand Up @@ -6848,7 +6851,7 @@ func GetUserApps(ctx context.Context, userId string) ([]WorkflowApp, error) {
break
}

if err != iterator.Done {
if err != iterator.Done && err != nil {
log.Printf("[ERROR] Failed fetching user apps (2): %v", err)
}

Expand Down
3 changes: 2 additions & 1 deletion shared.go
Original file line number Diff line number Diff line change
Expand Up @@ -24496,6 +24496,7 @@ func GetExternalClient(baseUrl string) *http.Client {
}
}

// Normal proxying?
if (len(httpProxy) > 0 || len(httpsProxy) > 0) && baseUrl != "http://shuffle-backend:5001" {
//client = &http.Client{}
if len(httpProxy) > 0 && httpProxy != "noproxy" {
Expand Down Expand Up @@ -29128,7 +29129,7 @@ func checkExecutionStatus(ctx context.Context, exec *WorkflowExecution) *Workflo
singleHttpItem := HTTPOutput{}
err := json.Unmarshal([]byte(result.Result), &singleHttpItem)
if err != nil {
log.Printf("[WARNING] Failed unmarshalling http result for %s: %s", result.Action.Label, err)
//log.Printf("[WARNING] Failed unmarshalling http result for %s: %s", result.Action.Label, err)
//continue
} else {
listUnmarshalled = []HTTPOutput{singleHttpItem}
Expand Down

0 comments on commit 203f342

Please sign in to comment.