3ds-cpe-emed / ws3dx-dotnet

C# client SDKs for Dassault Systèmes 3DEXPERIENCE web services.
MIT License
14 stars 1 forks source link

Unable to use dsEng Expand R2023x FD04 #49

Open AndreasX10D opened 2 weeks ago

AndreasX10D commented 2 weeks ago

class: ws3dx.dseng.core.service.EngItemService method: Expand

In 2024x_fd02 repo, the Expand method uses PostIndividualNoMask, but 2023x_fd04 uses PostIndividual.

Using PostIndividual, I get a "No Mask Schema Definition" error message. Changing to PostIndividualNoMask fixes the problem.

AndreasX10D commented 2 weeks ago

Seems there is a deeper problem with the Expand method. There is no class implementing the IExpandResponse interface, causing the deserialization to fail.

3ds-cpe-emed commented 2 weeks ago

Hi @AndreasX10D thanks for raising this. I am actually working on a major update that will require .NET 8.0. This will bring a more robust Deserialization engine/approach. Regarding the Expand one of the main issues is that there is no defined fixed json schema for it. So, at the moment if you need to use it you will need to provide your own implementation.

AndreasX10D commented 2 weeks ago

Thanks for letting me know! And thanks for this piece of fantastic code. I'll write my own implementation of Expand and looking forward to an updated version in the future.

3ds-cpe-emed commented 2 weeks ago

Thanks . I am always looking for improvement feedback or contributions. If there is no change in plans I hope to have time for a first version with the new release ready for the dseng (Engineering) corpus by the end of this week or at the beginning of next. The other corpus (dsmfg, ...) will follow but later on.

3ds-cpe-emed commented 1 week ago

@AndreasX10D please check the current major refactoring branch here /dev/net8/main_oc_2024x_fd02 . Please check the Expand Unit Test in file EngItemService_EngItem_UnitTest.cs .

In the future I intend to extend both the Expand response (deserialization) schema with a more strict schema (rather than just returning object/JsonElement) and also the input request schema (payload) particularly for filtering. Any ideas are welcomed.