Sorting set by Tag or Status orders objects incorrectly

Hello!
*This bug report is related to this feature request.

The Bug
When ordering a set by a tag, Anytype orders objects based on the order of the tag’s options.
For some reason, the first tag option (index 0) is always ordered last.


In the image above, “500” is the first option, but comes last in the order.

To Reproduce

  1. Create a tag relation
  2. Enable this relation within a set
  3. Ensure the relation has more than one option.
  4. Assign relational values (options) to some objects within the set
  5. Sort the set by the relation
    The first tag option, should show up last (or first if the sort is descending).

Expected Behavior
I expect the set to be ordered, in the order of the tag options.
(Or, in other words, for the first tag option to be first in the order).

System Information:
OS: Microsoft Windows 10 Home (Version 10.0.19042)
Anytype Version 0.21.5

Additional Context
N/A

Thank you for reading, hope you have an amazing day!

6 Likes
  • Shouldn’t the tags be sorted alphabetically?
  • Instead of Ascending / Descending, Would a custom sort order for tags in the sort pop-up suffice? Which would then display the draggable options such as in your feature request

Custom sort for tags is important, but few situations might require the normal sort by tag value. So it might be great if both the options are available :grinning_face_with_smiling_eyes:


Isn’t the In this object a mere suggestion to the user and does not represent any ordering? This is not the case now, as they seem to be considered for the sort from your bug report, but ideally isn’t this how they are supposed to be, just a suggestion to the user? :thinking:

1 Like
  • Shouldn’t the tags be sorted alphabetically?

In other applications (e.g. ClickUp), they’re (by default) sorted by date created — but yes, alphabetical sorting (or at least the option for this) would make a lot of sense!

Custom sort for tags is important, but few situations might require the normal sort by tag value. So it might be great if both the options are available :grinning_face_with_smiling_eyes:

Agreed!

Isn’t the In this object a mere suggestion to the user and does not represent any ordering? This is not the case now, as they seem to be considered for the sort from your bug report, but ideally isn’t this how they are supposed to be, just a suggestion to the user? :thinking:

In many other applications, sorting is based on the order of the tag options, so I assume/d this was intentional. :sweat_smile:

1 Like

@sahilstudio Thank you for your notice! We haven’t implemented this yet, but plan to do that in the future.

1 Like

Thank you!

So the issue with the first tag appearing last, is intentional?

@sahilstudio
As said by Kirill_Lem, this just isn’t implemented yet and you already made a feature request for the feature that would fix this.
I don’t see the need right now for this bug report anymore. Would you be okay with closing this?

1 Like

Thank you, but this topic is in regard to a currently occurring bug, not the requested feature (but the two are related).

The feature request is to have the order of all of the Tag options be arrangeable.

This report states that, when a set is sorted by a Tag (meaning the sorting occurs based on the order of the tag options), the first Tag option (position 1) always appears last (position 5 in the example above).

2 Likes

Got it, thanks for making that clear.

2 Likes

Describe the bug
Setting a sort rule in set view for a tag type relation fails to order the objects correctly. When I add an object with a tag starting with “N”, and one with a tag starting with “C” the first object (with the “N”) will be ordered before the “C” tags. Interestingly, having more varied tags will order correctly, except for the tags starting with “N”.

To Reproduce

  1. Create a custom type.
  2. Add a new custom, tag type relation.
  3. Create 2 objects: the first with a tag starting with “N” and the other one with a tag starting with “C”.
  4. Create a set of that type.
  5. Add a sorting rule to sort the objects by that tag relation in ascending order.

Expected behavior
The objects should be in ascending order.

System Information:

  • OS: Windows 10
  • Anytype Version: 0.21.9

Describe the bug

Sort setting on ‘Tag’ relations not obeyed by Grid view in Sets

To Reproduce

  • Create a set with objects which include a tag relation.
  • Ensure the tag relation has various values.
  • Set the sort on this tag relation.

Expected behavior

The sort should be as per the sort setting for ascending and descending.

Desktop (please complete the following information):

  • OS: Mac OS 11.4
  • Device: MacBook Pro (13-inch, 2017, Four Thunderbolt 3 Ports)
  • Version: 0.18.59

Additional context

na

6 Likes

Same thing happens on “Status” relations.

3 Likes

Hello, Im having the same issue on 0.27.0, Archlinux. The tags seems to just order themselves however they want, completely ignoring the ordering.
Customizable order would probably be the best way to solve it.

3 Likes

@sambouwer this seems similar to the issue we were discussing recently which erroneously assigns tags to the wrong pages when multiple are added, and also subsequently triggered sort order conflicts.

@Ciel List of Tag-related issues you may find this topic relevant.

@ignatovv were these bugs added to our forthcoming product polishing?

2 Likes

This issue is different as this is concerning sorting (also in the topic you linked).

1 Like

Hi! Im not sure how relevant this info is, but I’m not using tags, but instead, status.
And in addition, I dont see anything that seems to describe my issue under “problems with tags in sets”, here it seems to just be having its own idea of where it wants to be. Reassigning the status and such did not seem to help.

1 Like

I’ve adjusted the topic title to reflect both tags and statuses

1 Like

This issue has been added to our issue tracker and was received by the Development Team.