We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 920ff42 commit c4416ceCopy full SHA for c4416ce
download_analytics/metrics.py
@@ -110,10 +110,16 @@ def _version_element_order_key(version):
110
last_component = None
111
last_numeric = None
112
for component in version.split('.', 2):
113
- numeric = RE_NUMERIC.match(component).group(0)
114
- components.append(int(numeric))
115
- last_component = component
116
- last_numeric = numeric
+ if RE_NUMERIC.match(component):
+ try:
+ numeric = RE_NUMERIC.match(component).group(0)
+ components.append(int(numeric))
117
+ last_component = component
118
+ last_numeric = numeric
119
+ except AttributeError:
120
+ # From time to time this errors out in github actions
121
+ # while it shouldn't enter the `if`.
122
+ pass
123
124
components.append(last_component[len(last_numeric):])
125
0 commit comments