taipy icon indicating copy to clipboard operation
taipy copied to clipboard

Data nodes with cycle scope are duplicated in the data node selector

Open AlexandreSajus opened this issue 1 year ago • 2 comments

image

In this example, I created two scenarios with different cycles. last_two_years and prediction_year are data nodes with cycle scope. They are present twice in the data node selector which is confusing

They should be regrouped by cycle in an expandable

AlexandreSajus avatar Nov 06 '23 10:11 AlexandreSajus

@AlexandreSajus can you share some simple code showing the issue ?

FredLL-Avaiga avatar Feb 26 '24 16:02 FredLL-Avaiga

@AlexandreSajus can you share some simple code showing the issue ?

Creating a simple code for this is hard since you need a scenario with cycles involved and scenario visual elements. I found the issue using this project: https://github.com/Avaiga/demo-yearly-prediction

AlexandreSajus avatar Feb 27 '24 09:02 AlexandreSajus

@AlexandreSajus @FredLL-Avaiga, I just add the same issue on a data node selector. Does anyone have a graphical workaround for that bug until it is fixed? Especially if the priority is low, cause this prevents me using cycles. The only workaround I have is not to use cycles in my project which is a pain for me.

I have many input files in my scenarios and every time I create a new scenario, I have to manually detect and define the month. Then I need to manage by myself all the input data node files with a complete naming convention to match the month. As an alternative I can use a specific input widget for that and ask my customer to declare the current month, but the UX is not good enough. Finally, I need to update all my inputs data nodes to make them point to a correct file.

Any better way?

bobbyshermi avatar Apr 24 '24 11:04 bobbyshermi

Can you create a simple example that shows the issue? That would help fixing it quickly

FredLL-Avaiga avatar Apr 24 '24 12:04 FredLL-Avaiga

Thank you for your reactive answer @FredLL-Avaiga.

Trying to create a minimal reproductible piece of code, I just realized that I was using a wrong scope in my scenario. Sorry about that.

Then I looked at your code @AlexandreSajus 's code trying to understand your use case. And I believe you made a mistake as well in your md file. You are explicitly using not display_cycles. So that makes sense the cycles don't appear in your selector.

I guess there is no bug in the end.

bobbyshermi avatar Apr 24 '24 12:04 bobbyshermi

NICE FIND, indeed I probably copied something from somewhere else without thinking

AlexandreSajus avatar Apr 29 '24 03:04 AlexandreSajus

@AlexandreSajus Thinking is the key then... 🤣

bobbyshermi avatar May 27 '24 10:05 bobbyshermi

@AlexandreSajus Thinking is the key then... 🤣

I try not to do that as much as possible, just takes too much energy

AlexandreSajus avatar May 27 '24 11:05 AlexandreSajus