MCPcopy Create free account
hub / github.com/bufbuild/buf / getParsedRefForInputConfig

Method getParsedRefForInputConfig

private/buf/buffetch/ref_parser.go:522–537  ·  view source on GitHub ↗
(
	ctx context.Context,
	inputConfig bufconfig.InputConfig,
	allowedFormats []string,
)

Source from the content-addressed store, hash-verified

520}
521
522func (a *refParser) getParsedRefForInputConfig(
523 ctx context.Context,
524 inputConfig bufconfig.InputConfig,
525 allowedFormats []string,
526) (internal.ParsedRef, error) {
527 parsedRef, err := a.fetchRefParser.GetParsedRefForInputConfig(
528 ctx,
529 inputConfig,
530 internal.WithAllowedFormats(allowedFormats...),
531 )
532 if err != nil {
533 return nil, err
534 }
535 a.checkDeprecated(parsedRef)
536 return parsedRef, nil
537}
538
539func (a *refParser) checkDeprecated(parsedRef internal.ParsedRef) {
540 format := parsedRef.Format()

Calls 3

checkDeprecatedMethod · 0.95
WithAllowedFormatsFunction · 0.92

Tested by

no test coverage detected