You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe the bug
We are seeing Nullpointer exceptions for some of our OpenAI plugins when registering plugin to a kernel object.
This exception is not causing plugin registration to fail. However, it does appear constantly in logs which might need to be cleaned up or suppressed?
We use the method: .
await kernelWithOpenAIEndpoint.kernel.ImportPluginFromOpenApiAsync(
plugin.Key,
plugin.Value.ToStream(),
new OpenApiFunctionExecutionParameters()
{
HttpClient = client
});
Event time | 1/2/2025, 9:23:32.2170333 AM (Local time) |
-- | -- | --
Message | Object reference not set to an instance of an object. |
Exception type | System.NullReferenceException |
Failed method | Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.ConvertOperationIdToValidFunctionName |
Custom Properties
0 | MembershipOffersPlugin |
-- | -- | --
2 | Object reference not set to an instance of an object. |
ActionName | Microsoft.Partner.Portals.FrontdoorServices.Controllers.CoPilotController.GetAnswerEvents (Partner.Portals.FrontdoorServices) |
TraceId | 13a860c902901a19ec29b74516009d65 |
ActionId | 10e6f1f3-517a-4735-8e23-810b9b041f68 |
SpanId | 0ac273d0b40e5af0 |
AspNetCoreEnvironment | PROD |
OriginalFormat | Something went wrong while rendering the Rest function. Function: {0}.{1}. Error: {2} |
FormattedMessage | Something went wrong while rendering the Rest function. Function: MembershipOffersPlugin.(null). Error: Object reference not set to an instance of an object. |
RequestId | 4000ecf5-0000-8d00-b63f-84710c7967bb |
ParentId | d89546fb70f68f99 |
RequestPath | /portal/api/v1/copilot/chatEvents |
CategoryName | Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions
System.NullReferenceException: at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.ConvertOperationIdToValidFunctionName (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3) at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.CreateRestApiFunction (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3) at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions+d__6.MoveNext (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3)
To Reproduce
Steps to reproduce the behavior:
Register a plugin to the kernel where given method can have a null object.
Example plugin used where it failed:
MembershipOffersPlugin: {
PluginId: "7759a288-5a45-43ae-9c1c-ddcb38fb5b1f",
NameForHuman: "Membership Purchase and Offers",
NameForModel: "MembershipOffersPlugin",
DescriptionForHuman: "Plugin for answering partner's questions in membership workspace related to buy now, renew now, purchase and eligible offers for programs like Solutions Partner Designation, MAPS, Legacy Gold, Legacy Silver, Partner launch benefits, Partner success core benefits, Partner Success Expanded benefits, ISV Success and Training Partner",
DescriptionForModel: "Membership Purchase and Offers plugin must ALWAYS be invoked in Membership workspace. It can provide answers for questions regarding 'Membership purchase' such as 'help me make a purchase', 'status of buy now button', 'reason buy now button is disabled', 'when will the buy now button be enabled', 'Why buy now button is disabled?', 'Why renew now button is disabled?'. This plugin gives content as well as sources. If using this plugin, you MUST always cite the sources inline in your response.",
},
Expected behavior
Plugin registration shouldn't result in this nullpointer exception.
Screenshots
If applicable, add screenshots to help explain your problem.
Platform
OS: [e.g. Windows, Mac]
IDE: [e.g. Visual Studio, VS Code]
Language: [e.g. C#, Python]
Source:
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
prajwalpyakurelMS
changed the title
.Net: Bug:
Bug:NullPointer Exceptions during plugin registration (Registration and invocation still works, but this show up in logs constantly)
Jan 2, 2025
Describe the bug
We are seeing Nullpointer exceptions for some of our OpenAI plugins when registering plugin to a kernel object.
This exception is not causing plugin registration to fail. However, it does appear constantly in logs which might need to be cleaned up or suppressed?
We use the method: .
Event time | 1/2/2025, 9:23:32.2170333 AM (Local time) | -- | -- | -- Message | Object reference not set to an instance of an object. | Exception type | System.NullReferenceException | Failed method | Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.ConvertOperationIdToValidFunctionName |await kernelWithOpenAIEndpoint.kernel.ImportPluginFromOpenApiAsync(
plugin.Key,
plugin.Value.ToStream(),
new OpenApiFunctionExecutionParameters()
{
HttpClient = client
});
Custom Properties
System.NullReferenceException: at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.ConvertOperationIdToValidFunctionName (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3) at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions.CreateRestApiFunction (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3) at Microsoft.SemanticKernel.Plugins.OpenApi.OpenApiKernelExtensions+d__6.MoveNext (Microsoft.SemanticKernel.Plugins.OpenApi, Version=1.3.1.0, Culture=neutral, PublicKeyToken=f300afd708cefcd3)
To Reproduce
Steps to reproduce the behavior:
Register a plugin to the kernel where given method can have a null object.
Example plugin used where it failed:
MembershipOffersPlugin: {
PluginId: "7759a288-5a45-43ae-9c1c-ddcb38fb5b1f",
NameForHuman: "Membership Purchase and Offers",
NameForModel: "MembershipOffersPlugin",
DescriptionForHuman: "Plugin for answering partner's questions in membership workspace related to buy now, renew now, purchase and eligible offers for programs like Solutions Partner Designation, MAPS, Legacy Gold, Legacy Silver, Partner launch benefits, Partner success core benefits, Partner Success Expanded benefits, ISV Success and Training Partner",
DescriptionForModel: "Membership Purchase and Offers plugin must ALWAYS be invoked in Membership workspace. It can provide answers for questions regarding 'Membership purchase' such as 'help me make a purchase', 'status of buy now button', 'reason buy now button is disabled', 'when will the buy now button be enabled', 'Why buy now button is disabled?', 'Why renew now button is disabled?'. This plugin gives content as well as sources. If using this plugin, you MUST always cite the sources inline in your response.",
},
Expected behavior
Plugin registration shouldn't result in this nullpointer exception.
Screenshots
If applicable, add screenshots to help explain your problem.
Platform
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: