hh-applicant-tool 0.6.9__tar.gz → 0.6.11__tar.gz

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.

Potentially problematic release.


This version of hh-applicant-tool might be problematic. Click here for more details.

Files changed (31) hide show
  1. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/PKG-INFO +1 -1
  2. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/apply_similar.py +57 -24
  3. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/pyproject.toml +1 -1
  4. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/README.md +0 -0
  5. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/__init__.py +0 -0
  6. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/__main__.py +0 -0
  7. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/ai/__init__.py +0 -0
  8. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/ai/blackbox.py +0 -0
  9. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/api/__init__.py +0 -0
  10. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/api/client.py +0 -0
  11. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/api/errors.py +0 -0
  12. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/color_log.py +0 -0
  13. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/constants.py +0 -0
  14. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/jsonc.py +0 -0
  15. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/main.py +0 -0
  16. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/mixins.py +0 -0
  17. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/__init__.py +0 -0
  18. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/authorize.py +0 -0
  19. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/call_api.py +0 -0
  20. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/clear_negotiations.py +0 -0
  21. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/config.py +0 -0
  22. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/delete_telemetry.py +0 -0
  23. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/get_employer_contacts.py +0 -0
  24. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/list_resumes.py +0 -0
  25. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/refresh_token.py +0 -0
  26. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/reply_employers.py +0 -0
  27. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/update_resumes.py +0 -0
  28. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/operations/whoami.py +0 -0
  29. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/telemetry_client.py +0 -0
  30. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/types.py +0 -0
  31. {hh_applicant_tool-0.6.9 → hh_applicant_tool-0.6.11}/hh_applicant_tool/utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: hh-applicant-tool
3
- Version: 0.6.9
3
+ Version: 0.6.11
4
4
  Summary:
5
5
  Author: Senior YAML Developer
6
6
  Author-email: yamldeveloper@proton.me
@@ -4,11 +4,11 @@ import random
4
4
  import time
5
5
  from collections import defaultdict
6
6
  from datetime import datetime, timedelta, timezone
7
- from typing import TextIO
7
+ from typing import Any, TextIO
8
8
 
9
- from ..api.errors import LimitExceeded
10
9
  from ..ai.blackbox import BlackboxChat, BlackboxError
11
- from ..api import ApiError, ApiClient
10
+ from ..api import ApiClient, ApiError
11
+ from ..api.errors import LimitExceeded
12
12
  from ..main import BaseOperation
13
13
  from ..main import Namespace as BaseNamespace
14
14
  from ..mixins import GetResumeIdMixin
@@ -61,14 +61,16 @@ class Namespace(BaseNamespace):
61
61
  sort_point_lng: float | None
62
62
  no_magic: bool
63
63
  premium: bool
64
- responses_count_enabled: bool
64
+
65
65
 
66
66
  def _bool(v: bool) -> str:
67
67
  return str(v).lower()
68
68
 
69
+
69
70
  def _join_list(items: list[Any] | None) -> str:
70
71
  return ",".join(f"{v}" for v in items) if items else ""
71
72
 
73
+
72
74
  class Operation(BaseOperation, GetResumeIdMixin):
73
75
  """Откликнуться на все подходящие вакансии.
74
76
 
@@ -153,16 +155,22 @@ class Operation(BaseOperation, GetResumeIdMixin):
153
155
  type=str,
154
156
  default=None,
155
157
  )
156
- parser.add_argument("--employment", nargs="+", help="Тип занятости (employment)")
158
+ parser.add_argument(
159
+ "--employment", nargs="+", help="Тип занятости (employment)"
160
+ )
157
161
  parser.add_argument("--area", nargs="+", help="Регион (area id)")
158
162
  parser.add_argument("--metro", nargs="+", help="Станции метро (metro id)")
159
163
  parser.add_argument("--professional-role", nargs="+", help="Проф. роль (id)")
160
164
  parser.add_argument("--industry", nargs="+", help="Индустрия (industry id)")
161
165
  parser.add_argument("--employer-id", nargs="+", help="ID работодателей")
162
- parser.add_argument("--excluded-employer-id", nargs="+", help="Исключить работодателей")
166
+ parser.add_argument(
167
+ "--excluded-employer-id", nargs="+", help="Исключить работодателей"
168
+ )
163
169
  parser.add_argument("--currency", help="Код валюты (RUR, USD, EUR)")
164
170
  parser.add_argument("--salary", type=int, help="Минимальная зарплата")
165
- parser.add_argument("--only-with-salary", default=False, action=argparse.BooleanOptionalAction)
171
+ parser.add_argument(
172
+ "--only-with-salary", default=False, action=argparse.BooleanOptionalAction
173
+ )
166
174
  parser.add_argument("--label", nargs="+", help="Метки вакансий (label)")
167
175
  parser.add_argument("--period", type=int, help="Искать вакансии за N дней")
168
176
  parser.add_argument("--date-from", help="Дата публикации с (YYYY-MM-DD)")
@@ -171,14 +179,37 @@ class Operation(BaseOperation, GetResumeIdMixin):
171
179
  parser.add_argument("--bottom-lat", type=float, help="Гео: нижняя широта")
172
180
  parser.add_argument("--left-lng", type=float, help="Гео: левая долгота")
173
181
  parser.add_argument("--right-lng", type=float, help="Гео: правая долгота")
174
- parser.add_argument("--sort-point-lat", type=float, help="Координата lat для сортировки по расстоянию")
175
- parser.add_argument("--sort-point-lng", type=float, help="Координата lng для сортировки по расстоянию")
176
- parser.add_argument("--no-magic", default=False, action=argparse.BooleanOptionalAction, help="Отключить авторазбор текста запроса")
177
- parser.add_argument("--premium", default=False, action=argparse.BooleanOptionalAction, help="Только премиум вакансии")
178
- parser.add_argument("--responses-count-enabled", default=False, action=argparse.BooleanOptionalAction, help="Включить счётчик откликов")
179
- parser.add_argument("--search-field", nargs="+", help="Поля поиска (name, company_name и т.п.)")
180
- parser.add_argument("--clusters", action=argparse.BooleanOptionalAction, help="Включить кластеры (по умолчанию None)")
181
- #parser.add_argument("--describe-arguments", action=argparse.BooleanOptionalAction, help="Вернуть описание параметров запроса")
182
+ parser.add_argument(
183
+ "--sort-point-lat",
184
+ type=float,
185
+ help="Координата lat для сортировки по расстоянию",
186
+ )
187
+ parser.add_argument(
188
+ "--sort-point-lng",
189
+ type=float,
190
+ help="Координата lng для сортировки по расстоянию",
191
+ )
192
+ parser.add_argument(
193
+ "--no-magic",
194
+ default=False,
195
+ action=argparse.BooleanOptionalAction,
196
+ help="Отключить авторазбор текста запроса",
197
+ )
198
+ parser.add_argument(
199
+ "--premium",
200
+ default=False,
201
+ action=argparse.BooleanOptionalAction,
202
+ help="Только премиум вакансии",
203
+ )
204
+ parser.add_argument(
205
+ "--search-field", nargs="+", help="Поля поиска (name, company_name и т.п.)"
206
+ )
207
+ parser.add_argument(
208
+ "--clusters",
209
+ action=argparse.BooleanOptionalAction,
210
+ help="Включить кластеры (по умолчанию None)",
211
+ )
212
+ # parser.add_argument("--describe-arguments", action=argparse.BooleanOptionalAction, help="Вернуть описание параметров запроса")
182
213
 
183
214
  def run(
184
215
  self, args: Namespace, api_client: ApiClient, telemetry_client: TelemetryClient
@@ -245,7 +276,7 @@ class Operation(BaseOperation, GetResumeIdMixin):
245
276
  self.sort_point_lat = args.sort_point_lat
246
277
  self.sort_point_lng = args.sort_point_lng
247
278
  self.clusters = args.clusters
248
- #self.describe_arguments = args.describe_arguments
279
+ # self.describe_arguments = args.describe_arguments
249
280
  self.no_magic = args.no_magic
250
281
  self.premium = args.premium
251
282
  self._apply_similar()
@@ -366,7 +397,9 @@ class Operation(BaseOperation, GetResumeIdMixin):
366
397
  telemetry_data["employers"][employer_id] = employer_data
367
398
 
368
399
  if not do_apply:
369
- logger.debug("Останавливаем рассылку откликов, так как достигли лимита, попробуйте через сутки.")
400
+ logger.debug(
401
+ "Останавливаем рассылку откликов, так как достигли лимита, попробуйте через сутки."
402
+ )
370
403
  break
371
404
 
372
405
  if relations:
@@ -455,13 +488,13 @@ class Operation(BaseOperation, GetResumeIdMixin):
455
488
  "per_page": per_page,
456
489
  "order_by": self.order_by,
457
490
  }
458
-
491
+
459
492
  if self.search:
460
493
  params["text"] = self.search
461
494
  if self.schedule:
462
- params['schedule'] = self.schedule
495
+ params["schedule"] = self.schedule
463
496
  if self.experience:
464
- params['experience'] = self.experience
497
+ params["experience"] = self.experience
465
498
  if self.currency:
466
499
  params["currency"] = self.currency
467
500
  if self.salary:
@@ -471,7 +504,7 @@ class Operation(BaseOperation, GetResumeIdMixin):
471
504
  if self.date_from:
472
505
  params["date_from"] = self.date_from
473
506
  if self.date_to:
474
- params["date_to"] = self.date_to
507
+ params["date_to"] = self.date_to
475
508
  if self.top_lat:
476
509
  params["top_lat"] = self.top_lat
477
510
  if self.bottom_lat:
@@ -510,9 +543,9 @@ class Operation(BaseOperation, GetResumeIdMixin):
510
543
  params["no_magic"] = _bool(self.no_magic)
511
544
  if self.premium is not None:
512
545
  params["premium"] = _bool(self.premium)
513
- if self.responses_count_enabled is not None:
514
- params["responses_count_enabled"] = _bool(self.responses_count_enabled)
515
-
546
+ # if self.responses_count_enabled is not None:
547
+ # params["responses_count_enabled"] = _bool(self.responses_count_enabled)
548
+
516
549
  return params
517
550
 
518
551
  def _get_vacancies(self, per_page: int = 100) -> list[VacancyItem]:
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "hh-applicant-tool"
3
- version = "0.6.9"
3
+ version = "0.6.11"
4
4
  description = ""
5
5
  authors = ["Senior YAML Developer <yamldeveloper@proton.me>"]
6
6
  readme = "README.md"