{"record":{"id":"683a1ee20c73f1e0","repo":"hyperledger/fabric","slug":"could-not-get-application-config-for-channel-s","errorCode":null,"errorMessage":"could not get application config for channel %s","messagePattern":"could not get application config for channel (.+?)","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"core/chaincode/lifecycle/deployedcc_infoprovider.go","lineNumber":231,"sourceCode":"\t}\n\n\tif !exists {\n\t\t// Implicit collections are a v2.0 lifecycle concept, if the chaincode is not in the new lifecycle, return nothing\n\t\treturn nil, nil\n\t}\n\n\treturn vc.ChaincodeImplicitCollections(channelName)\n}\n\n// ChaincodeImplicitCollections assumes the chaincode exists in the new lifecycle and returns the implicit collections\nfunc (vc *ValidatorCommitter) ChaincodeImplicitCollections(channelName string) ([]*pb.StaticCollectionConfig, error) {\n\tchannelConfig := vc.Resources.ChannelConfigSource.GetStableChannelConfig(channelName)\n\tif channelConfig == nil {\n\t\treturn nil, errors.Errorf(\"could not get channelconfig for channel %s\", channelName)\n\t}\n\tac, ok := channelConfig.ApplicationConfig()\n\tif !ok {\n\t\treturn nil, errors.Errorf(\"could not get application config for channel %s\", channelName)\n\t}\n\n\torgs := ac.Organizations()\n\timplicitCollections := make([]*pb.StaticCollectionConfig, 0, len(orgs))\n\tfor _, org := range orgs {\n\t\timplicitCollections = append(implicitCollections, vc.GenerateImplicitCollectionForOrg(org.MSPID()))\n\t}\n\n\treturn implicitCollections, nil\n}\n\n// GenerateImplicitCollectionForOrg generates implicit collection for the org\nfunc (vc *ValidatorCommitter) GenerateImplicitCollectionForOrg(mspid string) *pb.StaticCollectionConfig {\n\t// set Required/MaxPeerCount to 0 if it is other org's implicit collection (mspid does not match peer's local mspid)\n\t// set Required/MaxPeerCount to the config values if it is the peer org's implicit collection (mspid matches peer's local mspid)\n\trequiredPeerCount := 0\n\tmaxPeerCount := 0\n\tif mspid == vc.CoreConfig.LocalMSPID {","sourceCodeStart":213,"sourceCodeEnd":249,"githubUrl":"https://github.com/hyperledger/fabric/blob/2736b63f8fd5932511d56fe68b7039d15977f7f6/core/chaincode/lifecycle/deployedcc_infoprovider.go#L213-L249","documentation":"Thrown by ChaincodeImplicitCollections when the channel config exists but ApplicationConfig() returns ok=false — the channel's config has no Application group. Implicit collections are built per application organization, so app config is mandatory.","triggerScenarios":"Calling ChaincodeImplicitCollections on a channel whose config bundle lacks an Application section (orderer-only config, malformed configtx, or Application group stripped by a config update).","commonSituations":"Channels created from a configtx profile without an Application section; consortium/system-channel-style configs misused as application channels; config update removing all application orgs.","solutions":["Update the channel config to include an Application group with at least the member organizations.","Regenerate the channel artifact from a configtx.yaml profile that defines Application: Organizations and Capabilities.","Validate the current config with configtxlator to confirm the Application group is present.","Skip implicit collection generation for channels that intentionally have no application config."],"exampleFix":"// configtx.yaml - before (no Application section)\nProfiles:\n  MyChannel:\n    Orderer: ...\n// after\nProfiles:\n  MyChannel:\n    Orderer: ...\n    Application:\n      Organizations:\n        - *Org1","handlingStrategy":"validation","validationCode":"ac, ok := vc.Resources.ChannelConfigSource.GetStableChannelConfig(channelName).ApplicationConfig()\nif !ok || len(ac.Organizations()) == 0 {\n    return fmt.Errorf(\"channel %s has no application orgs; implicit collections unavailable\", channelName)\n}","typeGuard":null,"tryCatchPattern":"ccs, err := vc.ChaincodeImplicitCollections(channelName)\nif err != nil && strings.Contains(err.Error(), \"could not get application config\") {\n    return nil, fmt.Errorf(\"fix channel %s config to include Application group: %w\", channelName, err)\n}","preventionTips":["Create application channels from profiles that include an Application section with orgs.","Inspect committed config with configtxlator before defining collections.","Reject config updates that would remove the Application group."],"tags":["fabric","channel-config","collections"],"backgroundTag":"missing-application-config","analyzedSha":"2736b63f8fd5932511d56fe68b7039d15977f7f6","analyzedAt":"2026-09-04T08:52:36.465Z","contentChangedAt":"2026-09-04T08:52:36.465Z","schemaVersion":2},"datasetVersion":"2026-09-08T15:18:49.778Z"}