XTLS/Xray-core · error

failed to build inbound config with tag

Error message

failed to build inbound config with tag 

What it means

Top-level Config.Build fails building one inbound detour; the failing inbound's tag is appended and the chained error is the per-inbound Build failure (port, protocol settings, etc.), letting the user locate the broken inbound.

Solutions

  1. Locate the inbound with the reported tag and fix its config
  2. Check protocol, port, and streamSettings fields
Defensive patterns

Strategy: validation

When it happens

Trigger: Thrown at infra/conf/xray.go:669 when the library encounters an invalid state.

Common situations: See trigger scenarios.


AI-assisted analysis of XTLS/Xray-core@7d214f8b09 (2026-08-15). Data as JSON: /api/errors/954a12cae4412141. Report an issue: GitHub.

Appendix: source

Thrown at infra/conf/xray.go:669

			return nil, errors.New("failed to build geodata configuration").Base(err)
		}
		config.App = append(config.App, serial.ToTypedMessage(r))
	}

	var inbounds []InboundDetourConfig

	if len(c.InboundConfigs) > 0 {
		inbounds = append(inbounds, c.InboundConfigs...)
	}

	if len(c.Transport) > 0 {
		return nil, errors.PrintRemovedFeatureError("Global transport config", "streamSettings in inbounds and outbounds")
	}

	for _, rawInboundConfig := range inbounds {
		ic, err := rawInboundConfig.Build()
		if err != nil {
			return nil, errors.New("failed to build inbound config with tag ", rawInboundConfig.Tag).Base(err)
		}
		config.Inbound = append(config.Inbound, ic)
	}

	var outbounds []OutboundDetourConfig

	if len(c.OutboundConfigs) > 0 {
		outbounds = append(outbounds, c.OutboundConfigs...)
	}

	for _, rawOutboundConfig := range outbounds {
		oc, err := rawOutboundConfig.Build()
		if err != nil {
			return nil, errors.New("failed to build outbound config with tag ", rawOutboundConfig.Tag).Base(err)
		}
		config.Outbound = append(config.Outbound, oc)
	}

View on GitHub (pinned to 7d214f8b09)