-
Notifications
You must be signed in to change notification settings - Fork 668
Deprecate DayOfWeek Enum node #8311
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
Conversation
|
@aparajit-pratap I wonder if you have some insight into the original code here and could help with the review. |
|
@gregmarr FYI. These nodes are deprecated in Dynamo. |
|
Are you deprecating the |
|
TS doesn't have anything for handling a node of type |
|
@gregmarr This is Deprecating DayOfWeek enum. I got this when I ran this node in cogs |
|
@ramramps Okay, not sure how we're handling that, can you share the Graph? |
|
@gregmarr The graph is attached in this PR. |
|
Ah, right, it just creates a function node for it, and we execute it as a no-param function, which picks up all the enums in the system. |
|
@gregmarr please note that AVP does not yet create functions in the library for enums, just thought I'd mention it if you're looking into this. |
|
So I guess the question is, why is this being deprecated? |
|
Question for @Racel - why this node is deprecated? |
|
What @ramramps said. We want to reduce the complexity of the node library, and no one could figure out a good reason why people would use these nodes in the first place. Looking at analytics, the most frequently used node was used ~300 times in the past 2 years over 10,000,000 nodes that have been created. |
|
yes @Racel. I am ok with deprecating this node. |
|
@Racel @ramramps @QilongTang @mjkkirschner If someone did need comprehensive datetime arithmetic capabilitites, can we point them to a package? |
|
@jnealb The nodes we are deprecating aren't of any real value. They create a DayOfWeek object that can not be used in any other node. Users can utilize the 'DayOfWeek' node (which we are not deprecating) to retrieve the specific Day of the week for any given datetime. |
|
@Racel They can use them in comparisons with the result of the output of the |
|
Ah. You are right, but you could also convert the output of DayOfWeek to a string and do a string comparison. I don’t think the comparison argument is enough to keep the nodes that are barely used over the past 2 years. We hope to be deprecating more OOTB nodes that have little utility. |
|
As long as they can continue to use the enum value in a CBN, that's probably good enough. |
|
@ramramps any idea why doesn't the |
|
@aparajit-pratap the IsVisible attribute is enough - but it only hides the node, it does not apply the obsolete message. |
|
@aparajit-pratap as mike mentioned, obsolete message is not applied to any enums (or something we missed). |
|
Yes, of course. I guess my next question would be why doesn't applying the attribute on the enum apply to all of its members? |
|
@aparajit-pratap parseEnumType traverse all fieldInfo. Also, it is possible to set few fields as obsolete and leave the remaining. |
|
@mjkkirschner @QilongTang @aparajit-pratap let me know if this is good to merge. |
|
@ramramps changes look good, can you run the self service tests though to make sure no regression with other zero touch import? |
|
@mjkkirschner done. |
|
Thanks @ramramps LGTM as well. Merging this to get a build early |


Purpose
This PR sets the DayOfWeek node as deprecated in Dynamo. DayOfWeek node is enum, and hence a new constructor is added to check for obsolete property on Enum fields.
Samplegraph
Declarations
Check these if you believe they are true
*.resxfilesReviewers
(FILL ME IN) Reviewer 1 (If possible, assign the Reviewer for the PR)
(FILL ME IN, optional) Any additional notes to reviewers or testers.
FYIs
(FILL ME IN, Optional) Names of anyone else you wish to be notified of