Skip to content

Commit

Permalink
bugfix for empty breakdowns (this time for real)
Browse files Browse the repository at this point in the history
  • Loading branch information
ausgerechnet committed Nov 25, 2024
1 parent 750a860 commit be70195
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cads/mmda/constellation.py
Original file line number Diff line number Diff line change
Expand Up @@ -435,6 +435,8 @@ def get_collocation_discourseme_scores_2(collocation_id, discourseme_description
# discourseme items
discourseme_items = CollocationDiscoursemeItem.query.filter_by(collocation_id=collocation_id, discourseme_description_id=discourseme_description_id)
df_discourseme_items = DataFrame([CollocationItemOut().dump(discourseme_item) for discourseme_item in discourseme_items])
if len(df_discourseme_items) == 0:
continue
df_discourseme_items = expand_scores_dataframe(df_discourseme_items)
df_discourseme_items['discourseme_id'] = discourseme_id
df_discourseme_items['source'] = 'discourseme_items'
Expand Down

0 comments on commit be70195

Please sign in to comment.