{"record":{"id":"b756295df4ef152f","repo":"netbirdio/netbird","slug":"refresh-v4-rules-w","errorCode":null,"errorMessage":"refresh v4 rules: %w","messagePattern":"refresh v4 rules: %w","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"client/firewall/nftables/manager_linux.go","lineNumber":357,"sourceCode":"\t}\n\treturn r.DeleteRouteRule(rule)\n}\n\n// routerForRuleID picks the router holding the rule with the given id, using\n// the supplied lookup. If the cached maps disagree (or both miss), it refreshes\n// from the kernel once and re-checks before falling back to the v4 router.\nfunc (m *Manager) routerForRuleID(id string, has func(*router, string) bool) (*router, error) {\n\tif has(m.router, id) {\n\t\treturn m.router, nil\n\t}\n\tif m.hasIPv6() && has(m.router6, id) {\n\t\treturn m.router6, nil\n\t}\n\tif !m.hasIPv6() {\n\t\treturn m.router, nil\n\t}\n\tif err := m.router.refreshRulesMap(); err != nil {\n\t\treturn nil, fmt.Errorf(\"refresh v4 rules: %w\", err)\n\t}\n\tif err := m.router6.refreshRulesMap(); err != nil {\n\t\treturn nil, fmt.Errorf(\"refresh v6 rules: %w\", err)\n\t}\n\tif has(m.router6, id) && !has(m.router, id) {\n\t\treturn m.router6, nil\n\t}\n\treturn m.router, nil\n}\n\nfunc (m *Manager) IsServerRouteSupported() bool {\n\treturn true\n}\n\nfunc (m *Manager) IsStateful() bool {\n\treturn true\n}\n","sourceCodeStart":339,"sourceCodeEnd":375,"githubUrl":"https://github.com/netbirdio/netbird/blob/93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c/client/firewall/nftables/manager_linux.go#L339-L375","documentation":"Error \"refresh v4 rules: %w\" thrown in netbirdio/netbird.","triggerScenarios":"Thrown at client/firewall/nftables/manager_linux.go:357 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":[],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"93e97f4bf1ad715072dcb3fb6cdb1763431b5a9c","analyzedAt":"2026-08-16T03:09:19.136Z","schemaVersion":2},"datasetVersion":"2026-08-16T08:17:34.114Z"}