Skip to content

src: Parse takes the context, ParseContext is removed - #49

Merged
Insei merged 1 commit into
mainfrom
parse-context
Oct 18, 2026
Merged

Insei merged 1 commit into
mainfrom
parse-context

Conversation

@Insei

@Insei Insei commented Oct 18, 2026

Copy link
Copy Markdown
Owner

Manager.Parse takes the context as the first argument, ParseContext is removed: the context of the requests to the remote storages is not forgotten, and the API has one method instead of two.

Breaking change:

  • Parse(conf) → Parse(context.Background(), conf)
  • ParseContext(ctx, conf) → Parse(ctx, conf)

The documentation, README, examples, tests and e2e are updated, the migration note is in docs/features/manager.md.

Signed-off-by: Dmitriy Aleksandrov <goodmobiledevices@gmail.com>
@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (839ec8b) to head (991784f).

Additional details and impacted files
@@            Coverage Diff            @@
##              main       #49   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files           31        31           
  Lines         2582      2581    -1     
=========================================
- Hits          2582      2581    -1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@github-actions

Copy link
Copy Markdown
Contributor

Benchmark diff: 839ec8b → 5184d1e (10 runs)

goos: linux
goarch: amd64
pkg: github.com/insei/tinyconf
cpu: AMD EPYC 7763 64-Core Processor                
                    │  base.txt   │              head.txt              │
                    │   sec/op    │   sec/op     vs base               │
Parse-4               8.595µ ± 1%   8.580µ ± 3%       ~ (p=0.529 n=10)
Parse_SubConfig-4     3.026µ ± 0%   3.041µ ± 0%  +0.51% (p=0.005 n=10)
Current-4             55.14n ± 0%   55.21n ± 0%  +0.14% (p=0.009 n=10)
Current_SubConfig-4   98.06n ± 0%   98.30n ± 1%  +0.24% (p=0.002 n=10)
geomean               612.4n        613.4n       +0.18%

                    │    base.txt    │               head.txt                │
                    │      B/op      │     B/op      vs base                 │
Parse-4               4.899Ki ± 0%     4.899Ki ± 0%       ~ (p=0.211 n=10)
Parse_SubConfig-4     1.367Ki ± 0%     1.367Ki ± 0%       ~ (p=1.000 n=10) ¹
Current-4               0.000 ± 0%       0.000 ± 0%       ~ (p=1.000 n=10) ¹
Current_SubConfig-4     0.000 ± 0%       0.000 ± 0%       ~ (p=1.000 n=10) ¹
geomean                            ²                 +0.00%                ²
¹ all samples are equal
² summaries must be >0 to compute geomean

                    │   base.txt   │              head.txt               │
                    │  allocs/op   │ allocs/op   vs base                 │
Parse-4               139.0 ± 0%     139.0 ± 0%       ~ (p=1.000 n=10) ¹
Parse_SubConfig-4     44.00 ± 0%     44.00 ± 0%       ~ (p=1.000 n=10) ¹
Current-4             0.000 ± 0%     0.000 ± 0%       ~ (p=1.000 n=10) ¹
Current_SubConfig-4   0.000 ± 0%     0.000 ± 0%       ~ (p=1.000 n=10) ¹
geomean                          ²               +0.00%                ²
¹ all samples are equal
² summaries must be >0 to compute geomean

pkg: github.com/insei/tinyconf/drivers
                │  base.txt   │              head.txt              │
                │   sec/op    │   sec/op     vs base               │
Parse_Drivers-4   76.24µ ± 2%   75.10µ ± 2%  -1.50% (p=0.023 n=10)

                │   base.txt   │            head.txt            │
                │     B/op     │     B/op      vs base          │
Parse_Drivers-4   32.04Ki ± 0%   32.04Ki ± 0%  ~ (p=0.628 n=10)

                │  base.txt  │            head.txt            │
                │ allocs/op  │ allocs/op   vs base            │
Parse_Drivers-4   645.0 ± 0%   645.0 ± 0%  ~ (p=1.000 n=10) ¹
¹ all samples are equal

@Insei
Insei merged commit 646f3ef into main Oct 18, 2026
4 checks passed
@Insei
Insei deleted the parse-context branch October 18, 2026 14:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants