GameSentenceMiner 2.5.2__py3-none-any.whl → 2.5.3__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
GameSentenceMiner/anki.py CHANGED
@@ -191,8 +191,14 @@ def get_last_anki_card() -> AnkiCard | dict:
191
191
  added_ids = invoke('findNotes', query='added:1')
192
192
  if not added_ids:
193
193
  return {}
194
- last_note = AnkiCard.from_dict(invoke('notesInfo', notes=[added_ids[-1]])[0])
195
- return last_note
194
+
195
+ card_dict = invoke('notesInfo', notes=[added_ids[-1]])[0]
196
+ try:
197
+ return AnkiCard.from_dict(card_dict)
198
+ except Exception as e:
199
+ logger.error(f"Error fetching last card: {e}")
200
+ logger.info(card_dict)
201
+ raise e
196
202
 
197
203
 
198
204
  def add_wildcards(expression):
@@ -88,11 +88,8 @@ class SceneItemsResponse:
88
88
  @dataclass
89
89
  class AnkiCard:
90
90
  noteId: int
91
- profile: str
92
91
  tags: list[str]
93
92
  fields: dict[str, dict[str, str]]
94
- modelName: str
95
- mod: int
96
93
  cards: list[int]
97
94
  alternatives = {
98
95
  "word_field": ["Front", "Word", "TargetWord", "Expression"],
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: GameSentenceMiner
3
- Version: 2.5.2
3
+ Version: 2.5.3
4
4
  Summary: A tool for mining sentences from games. Update: Multi-Line Mining! Fixed!
5
5
  Author-email: Beangate <bpwhelan95@gmail.com>
6
6
  License: MIT License
@@ -1,12 +1,12 @@
1
1
  GameSentenceMiner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
2
- GameSentenceMiner/anki.py,sha256=0-L2D8M69dZcanzRGAcQH2_b2yc1VCXT3rSyit8j57w,12088
2
+ GameSentenceMiner/anki.py,sha256=1VoWT1f5u98eYbXK7U4l8wpg_uL1nBPviNg4Q1YTCBg,12231
3
3
  GameSentenceMiner/config_gui.py,sha256=PzzLX-OwK71U5JSFaxup0ec0oWBWaF6AeCXs0m13HK0,56762
4
4
  GameSentenceMiner/configuration.py,sha256=kyvNCkZSZcqXbGjak8lb_GyhhjN8tIfb7eEfusz_M8A,16038
5
5
  GameSentenceMiner/electron_messaging.py,sha256=fBk9Ipo0jg2OZwYaKe1Qsm05P2ftrdTRGgFYob7ZA-k,139
6
6
  GameSentenceMiner/ffmpeg.py,sha256=2dwKbKxw_9sUXud67pPAx_6dGd1j-D99CdqLFVtbhSk,11479
7
7
  GameSentenceMiner/gametext.py,sha256=LORVdE2WEo1CDI8gonc7qxrhbS4KFKXFQVKjhlkpLbc,7368
8
8
  GameSentenceMiner/gsm.py,sha256=cWHJwWHyKsdzo0TXTXREG549MUtlQLyect9S37UK56g,20309
9
- GameSentenceMiner/model.py,sha256=WYLjIS9IEPxaLPwG5c-edfcfBKYzBFpdR3V3Da8MuLg,5277
9
+ GameSentenceMiner/model.py,sha256=bZm-2vkIw4gQCGLB02eDoTtO1Ymb_dnHk0VDJDFO3y8,5228
10
10
  GameSentenceMiner/notification.py,sha256=WeFodBsshhbOagcEfjAJ3kxjUGvBuUAQKEJ8Zf0YO04,2267
11
11
  GameSentenceMiner/obs.py,sha256=8ImXAVUWa4JdzwcBOEFShlZRZzh1dCvdpD1aEGhQfbU,6566
12
12
  GameSentenceMiner/package.py,sha256=YlS6QRMuVlm6mdXx0rlXv9_3erTGS21jaP3PNNWfAH0,1250
@@ -19,9 +19,9 @@ GameSentenceMiner/vad/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3h
19
19
  GameSentenceMiner/vad/silero_trim.py,sha256=-thDIZLuTLra3YBj7WR16Z6JeDgSpge2YuahprBvD8I,1585
20
20
  GameSentenceMiner/vad/vosk_helper.py,sha256=BI_mg_qyrjNbuEJjXSUDoV0FWEtQtEOAPmrrNixnZ_8,5974
21
21
  GameSentenceMiner/vad/whisper_helper.py,sha256=OF4J8TPPoKPJR1uFwrWAZ2Q7v0HJkVvNGmF8l1tACX0,3447
22
- gamesentenceminer-2.5.2.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
23
- gamesentenceminer-2.5.2.dist-info/METADATA,sha256=wdtFHe9Crw0k-LDyLiVb6SvsU9Retr3kI0I4XSVgQtk,5409
24
- gamesentenceminer-2.5.2.dist-info/WHEEL,sha256=tTnHoFhvKQHCh4jz3yCn0WPTYIy7wXx3CJtJ7SJGV7c,91
25
- gamesentenceminer-2.5.2.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
26
- gamesentenceminer-2.5.2.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
27
- gamesentenceminer-2.5.2.dist-info/RECORD,,
22
+ gamesentenceminer-2.5.3.dist-info/licenses/LICENSE,sha256=OXLcl0T2SZ8Pmy2_dmlvKuetivmyPd5m1q-Gyd-zaYY,35149
23
+ gamesentenceminer-2.5.3.dist-info/METADATA,sha256=2FyxGIwSYPDNPlftNrNUJ5T16irg35zuZFhqn3bdIq4,5409
24
+ gamesentenceminer-2.5.3.dist-info/WHEEL,sha256=tTnHoFhvKQHCh4jz3yCn0WPTYIy7wXx3CJtJ7SJGV7c,91
25
+ gamesentenceminer-2.5.3.dist-info/entry_points.txt,sha256=2APEP25DbfjSxGeHtwBstMH8mulVhLkqF_b9bqzU6vQ,65
26
+ gamesentenceminer-2.5.3.dist-info/top_level.txt,sha256=V1hUY6xVSyUEohb0uDoN4UIE6rUZ_JYx8yMyPGX4PgQ,18
27
+ gamesentenceminer-2.5.3.dist-info/RECORD,,