‘List’ object not callable for dict string: integer : <p>I’m encountering this issue where I have a dict: map-x-to-y = {} and fill it with values such as map-x-to-y[some-string] = counter. </p>

<p>But afterwards, If i try to call sorted I keep on getting ‘list’ object not callable error. </p>

<p>I tried with OrderedDict and with sorted and none of this works.
Also, I checked the type of map-x-to-y and it is ‘dict’. </p>

<p>My goal is to sort map-x-to-y in a descending order by value. </p>
