-
Notifications
You must be signed in to change notification settings - Fork 11
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Create Types for untyped nodes #286
base: main
Are you sure you want to change the base?
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for starting this @rohitkrsoni
Just a couple of comments here. Will you also look into writing the serialization implementation as well?
@@ -0,0 +1,24 @@ | |||
from .untyped_node import UntypedNode | |||
|
|||
class UntypedDictionary(UntypedNode): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
class UntypedDictionary(UntypedNode): | |
class UntypedObject(UntypedNode): |
Is there any reason to not call it UntypedObject
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Initially, I though of adding it as UntypedObject
but in python we call it dictionary which stores key-value pairs similar to HashMap
in Java
. https://docs.python.org/3/tutorial/datastructures.html#dictionaries
I can change it back to Object
if you like.
Thanks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't have strong opinion on this one. It's better to align with what the language thinks is best.
Maybe @shemogumbe can weigh in on the naming here..
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My view is - arrays
and objects
instead of list
and dict
might create confusion as the codebase of the project using python client will have lists and dictionaries.
open for suggestions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rohitkrsoni Lets keep this as is for now since the it makes sense for the language to have the naming as so and then start working on the serialization bits. In the event of any feedback before we merge, we can do a renaming.
Are you able to work on the serialization bits with this branch as a source?
Yes I will look into serialization implementation as well, but first I need to get my head around it. |
No worries. It would be great if we can get that started as well before we merge this one to avoid any unwanted regressions. |
Sure, will start that as well. I'm afraid we might need to put this on hold for some time. |
Quality Gate passedIssues Measures |
@rohitkrsoni @andrueastman just noticing this was a bit forgotten about. How can we get this finalized? (who's expecting what at this point?) |
@baywet I was waiting for a confirmation on weather to define it as After that we need to work on serialization ticket. Thanks |
This pull request has conflicting changes, the author must resolve the conflicts before this pull request can be merged. |
Overview
This PR adds Untyped nodes classes to support microsoft/kiota#4385
Related Issue
Fixes #285