[bidi] [dotnet] Use events JsonTypeInfo for deserialization#16402
[bidi] [dotnet] Use events JsonTypeInfo for deserialization#16402nvborisenko merged 1 commit intoSeleniumHQ:trunkfrom
Conversation
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
||||||||||||||
User description
Improves how we deserialize event json data, providing JsonTypeInfo directly instead of context.
💥 What does this PR do?
Improves how we deserialize event json data, providing JsonTypeInfo directly instead of context.
🔄 Types of changes
PR Type
Enhancement
Description
Replace JsonSerializerContext with specific JsonTypeInfo for event deserialization
Update all BiDi module event subscription methods
Simplify Broker event type mapping implementation
Remove unused Type property from CommandInfo class
Diagram Walkthrough
File Walkthrough
BrowsingContextModule.cs
Update event subscriptions with specific JsonTypeInfodotnet/src/webdriver/BiDi/BrowsingContext/BrowsingContextModule.cs
JsonContextwith specificJsonContext.EventTypefor all eventsubscriptions
context, and prompt events
Broker.cs
Refactor Broker to use JsonTypeInfo directlydotnet/src/webdriver/BiDi/Communication/Broker.cs
JsonSerializerContext
LogModule.cs
Update log event subscriptionsdotnet/src/webdriver/BiDi/Log/LogModule.cs
JsonContext.LogEntryNetworkModule.cs
Update network event subscriptionsdotnet/src/webdriver/BiDi/Network/NetworkModule.cs
fetchError, and authRequired events
ScriptModule.cs
Update script event subscriptionsdotnet/src/webdriver/BiDi/Script/ScriptModule.cs