[#1687][PORT][SkillConversationIdFactory] Add SkillConversationIdFactory to Python #1691
Add this suggestion to a batch that can be applied as a single commit. This suggestion is invalid because no changes were made to the code. Suggestions cannot be applied while the pull request is closed. Suggestions cannot be applied while viewing a subset of changes. Only one suggestion per line can be applied in a batch. Add this suggestion to a batch that can be applied as a single commit. Applying suggestions on deleted lines is not supported. You must change the existing code in this line in order to create a valid suggestion. Outdated suggestions cannot be applied. This suggestion has been applied or marked resolved. Suggestions cannot be applied from pending reviews. Suggestions cannot be applied on multi-line comments. Suggestions cannot be applied while the pull request is queued to merge. Suggestion cannot be applied right now. Please check back later.
Fixes #1687
Description
This PR introduces the SkillConversationIdFactory class ported from DotNet, adding/updating the necessary functionality to support the new and legacy methods to be backward compatible.
New unit tests were added as well as updating the existing ones to support the new functionality.
Specific Changes
SkillConversationIdFactory
class that inherits fromConversationIdFactoryBase
with the new functionality.ConversationIdFactoryBase
class to deprecate theget_conversation_reference
and introduce theget_skill_conversation_reference
method.@abstractmethod
decorator was removed, so the user is not warned to implement the new method and the legacy one (Addressing a breaking change), the usage of the decorator was removed from the rest of the methods to maintain consistency, if any method is not implemented from the Base class it will throw aNotImplemented
error.SkillHandler
class to support the newget_skill_conversation_reference
method and be backward compatible with the legacy onetest_skill_conversation_id_factory.py
file to support the new SkillConversationIdFactory class.test_skill_dialog.py
andtest_skill_http_client.py
files to support the new SkillConversationIdFactory functionality instead of the legacy one.test_skill_handler.py
to replace all the tests that were using the legacy functionality to start using the new one.test_legacy_conversation_id_factory
were ported from DotNet.Testing
The following images show the test passing locally and in the CI pipelines.
