spine-tools/spine-items

Generalize the concept of label in `ProjectItemResource` and use it everywhere?

spine-o-bot opened this issue · 2 comments

In GitLab by @manuelma on Dec 5, 2020, 11:06

This came up in #32. The point of this issue is so that discussion is not lost after we close #32. Here are the key points:

Currently, labels contain the file name or leaf path elements that are needed to identify a file. If a file is renamed, these labels become obsolete. What kind of labels would persist over file renames?

I don't know, the idea was that the user first defines a label and then attaches a file path to that label. So the label is persistent. Because labels can be 'whatever we want' in order to identify a file (not necessarily the basename).

So you're basically proposing we make the labels more like references to files? This would actually make the file resources more persistent over copying a project to another system where the input files are in different places. You'd just need to point DC to the new file locations. To streamline things, Toolbox should propose initial labels for files, e.g. the file name as we have now.

I believe hiding the actual absolute path behind a (user-editable) label is an excellent idea. I am now thinking that perhaps all file resources should be 'transient'.

In GitLab by @manuelma on Dec 5, 2020, 22:13

changed title from Generalize the concept of label in ProjectItemResource and use it everywhere to Generalize the concept of label in ProjectItemResource and use it everywhere{+?+}

In GitLab by @PekkaSavolainen on Dec 22, 2020, 12:59

moved to spine-tools/Spine-Toolbox#936