From 0f5508013d776f8806a87957f80e74c7f74c72eb Mon Sep 17 00:00:00 2001 From: Alan Pearce Date: Mon, 20 May 2024 18:13:07 +0200 Subject: feat(config): print durations and URLs with human values --- internal/importer/options.go | 2 +- internal/importer/package.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'internal/importer') diff --git a/internal/importer/options.go b/internal/importer/options.go index 51a6eb4..8ce684c 100644 --- a/internal/importer/options.go +++ b/internal/importer/options.go @@ -88,7 +88,7 @@ func NewOptionProcessor(infile io.ReadCloser, source *config.Source) (*OptionIng } func (i *OptionIngester) Process(parent context.Context) (<-chan nix.Importable, <-chan error) { - ctx, cancel := context.WithTimeout(parent, i.source.ImportTimeout) + ctx, cancel := context.WithTimeout(parent, i.source.ImportTimeout.Duration) results := make(chan nix.Importable) errs := make(chan error) diff --git a/internal/importer/package.go b/internal/importer/package.go index c10a96d..dbc5854 100644 --- a/internal/importer/package.go +++ b/internal/importer/package.go @@ -105,7 +105,7 @@ func convertToLicense(in map[string]any) *nix.License { } func (i *PackageIngester) Process(parent context.Context) (<-chan nix.Importable, <-chan error) { - ctx, cancel := context.WithTimeout(parent, i.source.ImportTimeout) + ctx, cancel := context.WithTimeout(parent, i.source.ImportTimeout.Duration) results := make(chan nix.Importable) errs := make(chan error) -- cgit 1.4.1