Mercurial > gemma
diff pkg/imports/sr.go @ 1338:5bb1e3c1f364
merges
author | Fadi Abbud <fadi.abbud@intevation.de> |
---|---|
date | Mon, 26 Nov 2018 09:01:21 +0100 |
parents | 53057ab27ff2 785f14264426 |
children | 8d59457a5651 |
line wrap: on
line diff
--- a/pkg/imports/sr.go Fri Nov 23 15:46:07 2018 +0100 +++ b/pkg/imports/sr.go Mon Nov 26 09:01:21 2018 +0100 @@ -80,8 +80,8 @@ } func (srJobCreator) StageDone( + ctx context.Context, tx *sql.Tx, - ctx context.Context, id int64, ) error { _, err := tx.ExecContext(ctx, srStageDoneSQL, id) @@ -165,8 +165,8 @@ } func (sr *SoundingResult) Do( + ctx context.Context, importID int64, - ctx context.Context, conn *sql.Conn, feedback Feedback, ) error { @@ -188,7 +188,7 @@ return err } - if err := m.Validate(conn, ctx); err != nil { + if err := m.Validate(ctx, conn); err != nil { return common.ToError(err) } @@ -204,7 +204,7 @@ } if len(xyz) == 0 { - return errors.New("XYZ does not contain any vertices.") + return errors.New("XYZ does not contain any vertices") } // Is there a boundary shapefile in the ZIP archive? @@ -241,7 +241,7 @@ feedback.Info("Triangulate...") start = time.Now() - tin, err := octree.GenerateTinByID(conn, ctx, id, epsg) + tin, err := octree.GenerateTinByID(ctx, conn, id, epsg) feedback.Info("triangulation took %s", time.Since(start)) if err != nil { return err @@ -285,7 +285,7 @@ } // Store for potential later removal. - if err = track(tx, ctx, importID, "waterway.sounding_results", id); err != nil { + if err = track(ctx, tx, importID, "waterway.sounding_results", id); err != nil { return err }