aa-structures 3.2.2__tar.gz → 3.3.1__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.
Files changed (235) hide show
  1. {aa_structures-3.2.2 → aa_structures-3.3.1}/PKG-INFO +4 -4
  2. {aa_structures-3.2.2 → aa_structures-3.3.1}/pyproject.toml +3 -3
  3. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/__init__.py +1 -1
  4. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tasks.py +68 -43
  5. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/integration/test_tasks.py +2 -2
  6. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/test_tasks.py +27 -22
  7. {aa_structures-3.2.2 → aa_structures-3.3.1}/LICENSE +0 -0
  8. {aa_structures-3.2.2 → aa_structures-3.3.1}/README.md +0 -0
  9. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/admin.py +0 -0
  10. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/app_settings.py +0 -0
  11. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/apps.py +0 -0
  12. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/auth_hooks.py +0 -0
  13. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/checks.py +0 -0
  14. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/constants.py +0 -0
  15. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/__init__.py +0 -0
  16. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/__init__.py +0 -0
  17. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/billing_embeds.py +0 -0
  18. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/corporate_embeds.py +0 -0
  19. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/helpers.py +0 -0
  20. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/main.py +0 -0
  21. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/moonmining_embeds.py +0 -0
  22. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/orbital_embeds.py +0 -0
  23. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/skyhook_embeds.py +0 -0
  24. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/sov_embeds.py +0 -0
  25. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/structures_embeds.py +0 -0
  26. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/tower_embeds.py +0 -0
  27. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_embeds/war_embeds.py +0 -0
  28. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_timers.py +0 -0
  29. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/notification_types.py +0 -0
  30. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/serializers.py +0 -0
  31. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/sovereignty.py +0 -0
  32. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/core/starbases.py +0 -0
  33. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/forms.py +0 -0
  34. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/helpers.py +0 -0
  35. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/de/LC_MESSAGES/django.mo +0 -0
  36. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/de/LC_MESSAGES/django.po +0 -0
  37. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/django.pot +0 -0
  38. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/en/LC_MESSAGES/django.mo +0 -0
  39. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/en/LC_MESSAGES/django.po +0 -0
  40. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/es/LC_MESSAGES/django.mo +0 -0
  41. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/es/LC_MESSAGES/django.po +0 -0
  42. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/fr_FR/LC_MESSAGES/django.mo +0 -0
  43. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/fr_FR/LC_MESSAGES/django.po +0 -0
  44. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/it_IT/LC_MESSAGES/django.mo +0 -0
  45. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/it_IT/LC_MESSAGES/django.po +0 -0
  46. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ja/LC_MESSAGES/django.mo +0 -0
  47. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ja/LC_MESSAGES/django.po +0 -0
  48. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ko_KR/LC_MESSAGES/django.mo +0 -0
  49. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ko_KR/LC_MESSAGES/django.po +0 -0
  50. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ru/LC_MESSAGES/django.mo +0 -0
  51. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/ru/LC_MESSAGES/django.po +0 -0
  52. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/uk/LC_MESSAGES/django.mo +0 -0
  53. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/uk/LC_MESSAGES/django.po +0 -0
  54. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/zh_Hans/LC_MESSAGES/django.mo +0 -0
  55. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/locale/zh_Hans/LC_MESSAGES/django.po +0 -0
  56. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/management/commands/__init__.py +0 -0
  57. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/management/commands/structures_load_eve.py +0 -0
  58. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/management/commands/structures_preload_eveuniverse.py +0 -0
  59. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/management/commands/structures_update_poco_planets.py +0 -0
  60. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/managers.py +0 -0
  61. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0001_initial_new.py +0 -0
  62. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0002_remove_eveuniverse_relation_names.py +0 -0
  63. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0003_add_localization_and_unique_key.py +0 -0
  64. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0004_improve_localization.py +0 -0
  65. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0005_add_notification_types.py +0 -0
  66. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0006_add_ownercharacter_disabled.py +0 -0
  67. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0007_add_notificationtypes_skyhook_metenox.py +0 -0
  68. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0008_add_notificationtypes_skyhook_metenox.py +0 -0
  69. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/0009_add_project_goal_notifications.py +0 -0
  70. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/migrations/__init__.py +0 -0
  71. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/__init__.py +0 -0
  72. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/eveuniverse.py +0 -0
  73. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/notifications.py +0 -0
  74. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/owners.py +0 -0
  75. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/structures_1.py +0 -0
  76. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/models/structures_2.py +0 -0
  77. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/providers.py +0 -0
  78. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/css/global.css +0 -0
  79. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/css/main.css +0 -0
  80. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/css/public.css +0 -0
  81. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/css/statistics.css +0 -0
  82. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/css/structures.css +0 -0
  83. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/bars-rotate-fade-black-36.svg +0 -0
  84. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/bars-rotate-fade-white-36.svg +0 -0
  85. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/eve_symbol_128.png +0 -0
  86. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/0h.png +0 -0
  87. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/0l.png +0 -0
  88. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/0m.png +0 -0
  89. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/0r.png +0 -0
  90. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/0s.png +0 -0
  91. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/1h.png +0 -0
  92. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/1l.png +0 -0
  93. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/1m.png +0 -0
  94. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/1r.png +0 -0
  95. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/1s.png +0 -0
  96. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/2h.png +0 -0
  97. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/2l.png +0 -0
  98. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/2m.png +0 -0
  99. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/2r.png +0 -0
  100. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/2s.png +0 -0
  101. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/3h.png +0 -0
  102. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/3l.png +0 -0
  103. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/3m.png +0 -0
  104. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/3r.png +0 -0
  105. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/3s.png +0 -0
  106. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/4h.png +0 -0
  107. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/4l.png +0 -0
  108. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/4m.png +0 -0
  109. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/4s.png +0 -0
  110. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/5h.png +0 -0
  111. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/5l.png +0 -0
  112. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/5m.png +0 -0
  113. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/5s.png +0 -0
  114. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/6h.png +0 -0
  115. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/6l.png +0 -0
  116. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/6m.png +0 -0
  117. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/7h.png +0 -0
  118. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/7l.png +0 -0
  119. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/7m.png +0 -0
  120. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/8h.png +0 -0
  121. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/8l.png +0 -0
  122. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/8m.png +0 -0
  123. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/blank.png +0 -0
  124. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/circle.png +0 -0
  125. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/dustwheel.png +0 -0
  126. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/h.png +0 -0
  127. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/l.png +0 -0
  128. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/m.png +0 -0
  129. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/noship.png +0 -0
  130. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/r.png +0 -0
  131. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/tyrannis.png +0 -0
  132. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/tyrannis_blue.png +0 -0
  133. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/tyrannis_darkred.png +0 -0
  134. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/tyrannis_default.png +0 -0
  135. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/panel/tyrannis_revelations.png +0 -0
  136. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/img/structures_logo.png +0 -0
  137. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/js/global.js +0 -0
  138. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/js/public.js +0 -0
  139. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/js/statistics.js +0 -0
  140. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/js/structures.js +0 -0
  141. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/vendor/datatables/plugins/dataTables.rowGroup.min.js +0 -0
  142. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/vendor/datatables/plugins/datetime.js +0 -0
  143. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/vendor/datatables/plugins/filterDropDown.min.js +0 -0
  144. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/vendor/datatables/plugins/rowGroup.bootstrap.min.css +0 -0
  145. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/static/structures/vendor/datatables/plugins/rowGroup.dataTables.min.css +0 -0
  146. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/base.html +0 -0
  147. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/fitting_assets.html +0 -0
  148. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/fitting_gfx.html +0 -0
  149. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/poco_details.html +0 -0
  150. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/starbase_detail.html +0 -0
  151. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/structure_details.html +0 -0
  152. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/tab_general_detail.html +0 -0
  153. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/modals/tab_services_detail.html +0 -0
  154. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/menu.html +0 -0
  155. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/public/poco_list.html +0 -0
  156. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/statistics/structure_summary.html +0 -0
  157. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/structures/active_tags.html +0 -0
  158. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/structures/jump_gate_list.html +0 -0
  159. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/structures/orbital_list.html +0 -0
  160. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/structures/starbase_list.html +0 -0
  161. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/partials/structures/structure_list.html +0 -0
  162. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/public.html +0 -0
  163. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/statistics.html +0 -0
  164. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/structures.html +0 -0
  165. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/templatetags/detail_title.html +0 -0
  166. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/templatetags/list_asset.html +0 -0
  167. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/templatetags/list_item.html +0 -0
  168. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/templatetags/list_tax_item.html +0 -0
  169. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templates/structures/templatetags/list_title.html +0 -0
  170. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templatetags/__init__.py +0 -0
  171. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/templatetags/structures.py +0 -0
  172. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/__init__.py +0 -0
  173. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/__init__.py +0 -0
  174. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/notification_embeds/__init__.py +0 -0
  175. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/notification_embeds/test_helpers.py +0 -0
  176. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/notification_embeds/test_main.py +0 -0
  177. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_notification_structuretimers.py +0 -0
  178. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_notification_types.py +0 -0
  179. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_notifications_timers.py +0 -0
  180. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_serializers.py +0 -0
  181. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_sovereignty.py +0 -0
  182. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/core/test_starbases.py +0 -0
  183. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/integration/__init__.py +0 -0
  184. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/integration/test_views.py +0 -0
  185. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/__init__.py +0 -0
  186. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_eveuniverse.py +0 -0
  187. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_notifications_1.py +0 -0
  188. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_notifications_2.py +0 -0
  189. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_notifications_3.py +0 -0
  190. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_notifications_discord.py +0 -0
  191. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_1.py +0 -0
  192. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_2.py +0 -0
  193. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_3.py +0 -0
  194. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_4.py +0 -0
  195. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_5.py +0 -0
  196. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_owners_6.py +0 -0
  197. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/models/test_structures.py +0 -0
  198. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/test_admin.py +0 -0
  199. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/test_helpers.py +0 -0
  200. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/test_managers_1.py +0 -0
  201. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/test_managers_2.py +0 -0
  202. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/__init__.py +0 -0
  203. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/constants.py +0 -0
  204. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/create_eveuniverse.py +0 -0
  205. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/entities.json +0 -0
  206. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/esi_data.json +0 -0
  207. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/eveuniverse.json +0 -0
  208. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/factories.py +0 -0
  209. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/generate_notifications.py +0 -0
  210. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/generate_notifications_2.py +0 -0
  211. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/generate_structures.py +0 -0
  212. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/helpers.py +0 -0
  213. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/load_eveuniverse.py +0 -0
  214. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/tasks_loadtest.py +0 -0
  215. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/testdata/test_generate_structures.py +0 -0
  216. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/__init__.py +0 -0
  217. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/test_public.py +0 -0
  218. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/test_service_status.py +0 -0
  219. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/test_statistics.py +0 -0
  220. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/test_structures.py +0 -0
  221. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/tests/views/utils.py +0 -0
  222. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/urls.py +0 -0
  223. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/__init__.py +0 -0
  224. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/common.py +0 -0
  225. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/public.py +0 -0
  226. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/statistics.py +0 -0
  227. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/status.py +0 -0
  228. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/views/structures.py +0 -0
  229. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/__init__.py +0 -0
  230. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/core.py +0 -0
  231. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/managers.py +0 -0
  232. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/models.py +0 -0
  233. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/tests/__init__.py +0 -0
  234. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/tests/test_core.py +0 -0
  235. {aa_structures-3.2.2 → aa_structures-3.3.1}/structures/webhooks/tests/test_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: aa-structures
3
- Version: 3.2.2
3
+ Version: 3.3.1
4
4
  Summary: App for managing Eve Online structures with Alliance Auth.
5
5
  Author-email: Erik Kalkoken <kalkoken87@gmail.com>
6
6
  Requires-Python: >=3.8
@@ -20,14 +20,14 @@ Classifier: Programming Language :: Python :: 3.12
20
20
  Classifier: Topic :: Internet :: WWW/HTTP
21
21
  Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
22
22
  License-File: LICENSE
23
- Requires-Dist: allianceauth-app-utils>=1.27
23
+ Requires-Dist: allianceauth-app-utils>=1.29.1
24
24
  Requires-Dist: allianceauth>=4,<5
25
25
  Requires-Dist: dhooks-lite>=1.0
26
- Requires-Dist: django-eveuniverse>=1.5.2
26
+ Requires-Dist: django-eveuniverse>=1.6
27
27
  Requires-Dist: django-multiselectfield
28
28
  Requires-Dist: django-navhelper
29
29
  Requires-Dist: pytz!=2022.2
30
- Requires-Dist: redis-simple-mq>=1.0
30
+ Requires-Dist: redis-simple-mq>=1.1
31
31
  Requires-Dist: humanize>=4.7
32
32
  Project-URL: Changelog, https://gitlab.com/ErikKalkoken/aa-structures/-/blob/master/CHANGELOG.md
33
33
  Project-URL: Documentation, https://aa-structures.readthedocs.io/en/latest/
@@ -26,14 +26,14 @@ classifiers = [
26
26
  "Topic :: Internet :: WWW/HTTP :: Dynamic Content",
27
27
  ]
28
28
  dependencies = [
29
- "allianceauth-app-utils>=1.27",
29
+ "allianceauth-app-utils>=1.29.1",
30
30
  "allianceauth>=4,<5",
31
31
  "dhooks-lite>=1.0",
32
- "django-eveuniverse>=1.5.2",
32
+ "django-eveuniverse>=1.6",
33
33
  "django-multiselectfield",
34
34
  "django-navhelper",
35
35
  "pytz!=2022.2",
36
- "redis-simple-mq>=1.0",
36
+ "redis-simple-mq>=1.1",
37
37
  "humanize>=4.7",
38
38
  ]
39
39
 
@@ -3,5 +3,5 @@
3
3
  # pylint: disable = invalid-name
4
4
  default_app_config = "structures.apps.StructuresConfig"
5
5
 
6
- __version__ = "3.2.2"
6
+ __version__ = "3.3.1"
7
7
  __title__ = "Structures"
@@ -2,14 +2,15 @@
2
2
 
3
3
  from typing import Iterable, Optional
4
4
 
5
- from celery import chain, shared_task
5
+ from celery import Task, chain, shared_task
6
6
 
7
7
  from django.contrib.auth.models import User
8
+ from django.db.models import QuerySet
8
9
 
9
10
  from allianceauth.notifications import notify
10
11
  from allianceauth.services.hooks import get_extension_logger
11
12
  from allianceauth.services.tasks import QueueOnce
12
- from app_utils.esi import fetch_esi_status
13
+ from app_utils.esi import retry_task_on_esi_error_and_offline
13
14
  from app_utils.logging import LoggerAddTag
14
15
 
15
16
  from . import __title__
@@ -19,6 +20,7 @@ from .models import (
19
20
  EveSovereigntyMap,
20
21
  FuelAlertConfig,
21
22
  JumpFuelAlertConfig,
23
+ Notification,
22
24
  Owner,
23
25
  Webhook,
24
26
  )
@@ -35,19 +37,14 @@ def update_all_structures():
35
37
  Main task for starting regular update of all structures
36
38
  and related data from ESI.
37
39
  """
38
- if not fetch_esi_status().is_ok:
39
- logger.warning("ESI currently not available. Aborting.")
40
- return
41
40
  chain(update_sov_map.si(), update_structures.si()).delay()
42
41
 
43
42
 
44
- @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
45
- def update_sov_map():
43
+ @shared_task(bind=True, base=QueueOnce, time_limit=STRUCTURES_TASKS_TIME_LIMIT)
44
+ def update_sov_map(self: Task):
46
45
  """Update sovereignty map from ESI."""
47
- if not fetch_esi_status().is_ok:
48
- logger.warning("ESI currently not available. Aborting.")
49
- return
50
- EveSovereigntyMap.objects.update_or_create_all_from_esi()
46
+ with retry_task_on_esi_error_and_offline(self):
47
+ EveSovereigntyMap.objects.update_or_create_all_from_esi()
51
48
 
52
49
 
53
50
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
@@ -68,7 +65,7 @@ def update_structures():
68
65
 
69
66
 
70
67
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
71
- def update_all_for_owner(owner_pk, user_pk: Optional[int] = None):
68
+ def update_all_for_owner(owner_pk: int, user_pk: Optional[int] = None):
72
69
  """Update structures and notifications for owner from ESI."""
73
70
  chain(
74
71
  update_structures_for_owner.si(owner_pk, user_pk),
@@ -77,44 +74,64 @@ def update_all_for_owner(owner_pk, user_pk: Optional[int] = None):
77
74
 
78
75
 
79
76
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
80
- def update_structures_for_owner(owner_pk, user_pk: Optional[int] = None):
77
+ def update_structures_for_owner(owner_pk: int, user_pk: Optional[int] = None):
81
78
  """Fetch all structures for owner and update related corp assets from ESI."""
82
- if not fetch_esi_status().is_ok:
83
- logger.warning("ESI currently not available. Aborting.")
84
- else:
85
- chain(
86
- update_structures_esi_for_owner.si(owner_pk, user_pk),
87
- update_structures_assets_for_owner.si(owner_pk, user_pk),
88
- ).delay()
79
+ chain(
80
+ update_structures_esi_for_owner.si(owner_pk, user_pk),
81
+ update_structures_assets_for_owner.si(owner_pk, user_pk),
82
+ ).delay()
89
83
 
90
84
 
91
- @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
92
- def update_structures_esi_for_owner(owner_pk, user_pk: Optional[int] = None):
93
- """Update all structures for owner for ESI."""
85
+ @shared_task(
86
+ bind=True,
87
+ base=QueueOnce,
88
+ once={"keys": ["owner_pk"], "graceful": True},
89
+ time_limit=STRUCTURES_TASKS_TIME_LIMIT,
90
+ )
91
+ def update_structures_esi_for_owner(
92
+ self: Task, owner_pk: int, user_pk: Optional[int] = None
93
+ ):
94
+ """Update all structures for an owner from ESI.
95
+
96
+ Optionally notify user_pk about the result.
97
+ """
94
98
  owner = Owner.objects.get(pk=owner_pk)
95
- owner.update_structures_esi(_get_user(user_pk))
99
+ with retry_task_on_esi_error_and_offline(self):
100
+ owner.update_structures_esi(_get_user(user_pk))
96
101
 
97
102
 
98
- @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
99
- def update_structures_assets_for_owner(owner_pk, user_pk: Optional[int] = None):
100
- """Update all related assets for owner."""
103
+ @shared_task(
104
+ bind=True,
105
+ base=QueueOnce,
106
+ once={"keys": ["owner_pk"], "graceful": True},
107
+ time_limit=STRUCTURES_TASKS_TIME_LIMIT,
108
+ )
109
+ def update_structures_assets_for_owner(
110
+ self: Task, owner_pk: int, user_pk: Optional[int] = None
111
+ ):
112
+ """Update all related assets for an owner from ESI.
113
+
114
+ Optionally notify user_pk about the result.
115
+ """
101
116
  owner = Owner.objects.get(pk=owner_pk)
102
- owner.update_asset_esi(_get_user(user_pk))
117
+ with retry_task_on_esi_error_and_offline(self):
118
+ owner.update_asset_esi(_get_user(user_pk))
103
119
 
104
120
 
105
121
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
106
122
  def fetch_all_notifications():
107
123
  """Fetch notifications for all owners and send new fuel notifications."""
108
- for owner in Owner.objects.all():
109
- if owner.is_active:
110
- owner.update_is_up()
111
- process_notifications_for_owner.apply_async(
112
- kwargs={"owner_pk": owner.pk}, priority=TASK_PRIORITY_HIGH
113
- )
124
+ for owner in Owner.objects.filter(is_active=True):
125
+ owner.update_is_up()
126
+ process_notifications_for_owner.apply_async(
127
+ kwargs={"owner_pk": owner.pk}, priority=TASK_PRIORITY_HIGH
128
+ )
129
+
114
130
  for config_pk in FuelAlertConfig.objects.filter(is_enabled=True).values_list(
115
131
  "pk", flat=True
116
132
  ):
117
133
  send_structure_fuel_notifications_for_config.delay(config_pk)
134
+
118
135
  for config_pk in JumpFuelAlertConfig.objects.filter(is_enabled=True).values_list(
119
136
  "pk", flat=True
120
137
  ):
@@ -124,9 +141,6 @@ def fetch_all_notifications():
124
141
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
125
142
  def process_notifications_for_owner(owner_pk: int, user_pk: Optional[int] = None):
126
143
  """Fetch all notification for owner from ESI and processes them."""
127
- if not fetch_esi_status().is_ok:
128
- logger.warning("ESI currently not available. Aborting.")
129
- return
130
144
  chain(
131
145
  fetch_notification_for_owner.si(owner_pk=owner_pk, user_pk=user_pk).set(
132
146
  priority=TASK_PRIORITY_HIGH
@@ -143,11 +157,22 @@ def process_notifications_for_owner(owner_pk: int, user_pk: Optional[int] = None
143
157
  ).delay()
144
158
 
145
159
 
146
- @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
147
- def fetch_notification_for_owner(owner_pk: int, user_pk: Optional[int] = None):
148
- """Fetch notifications from ESI."""
160
+ @shared_task(
161
+ bind=True,
162
+ base=QueueOnce,
163
+ once={"keys": ["owner_pk"], "graceful": True},
164
+ time_limit=STRUCTURES_TASKS_TIME_LIMIT,
165
+ )
166
+ def fetch_notification_for_owner(
167
+ self: Task, owner_pk: int, user_pk: Optional[int] = None
168
+ ):
169
+ """Fetch notifications from ESI.
170
+
171
+ Optionally notify user_pk about the result.
172
+ """
149
173
  owner = Owner.objects.get(pk=owner_pk)
150
- owner.fetch_notifications_esi(_get_user(user_pk))
174
+ with retry_task_on_esi_error_and_offline(self):
175
+ owner.fetch_notifications_esi(_get_user(user_pk))
151
176
 
152
177
 
153
178
  @shared_task(time_limit=STRUCTURES_TASKS_TIME_LIMIT)
@@ -157,7 +182,7 @@ def update_notifications_structure_relations(owner_pk: int) -> int:
157
182
  Returns number of updated notifications.
158
183
  """
159
184
  owner = Owner.objects.get(pk=owner_pk)
160
- notif_need_update_qs = owner.notification_set.filter(
185
+ notif_need_update_qs: QuerySet[Notification] = owner.notification_set.filter(
161
186
  notif_type__in=NotificationType.structure_related(), structures__isnull=True
162
187
  )
163
188
  notif_need_update_count = notif_need_update_qs.count()
@@ -213,7 +238,7 @@ def send_queued_messages_for_webhooks(webhooks: Iterable[Webhook]):
213
238
  )
214
239
 
215
240
 
216
- @shared_task(base=QueueOnce)
241
+ @shared_task(base=QueueOnce, time_limit=STRUCTURES_TASKS_TIME_LIMIT)
217
242
  def send_messages_for_webhook(webhook_pk: int) -> None:
218
243
  """Send all currently queued messages for given webhook to Discord."""
219
244
  Webhook.objects.send_queued_messages_for_webhook(webhook_pk)
@@ -10,8 +10,8 @@ from django.utils.timezone import now
10
10
  from eveuniverse.models import EvePlanet, EveSolarSystem
11
11
 
12
12
  from app_utils.django import app_labels
13
- from app_utils.esi import EsiStatus
14
13
  from app_utils.esi_testing import EsiClientStub, EsiEndpoint
14
+ from app_utils.testing import reset_celery_once_locks
15
15
 
16
16
  from structures import tasks
17
17
  from structures.core.notification_types import NotificationType
@@ -54,7 +54,6 @@ TASKS_PATH = "structures.tasks"
54
54
  @patch(OWNERS_PATH + ".STRUCTURES_FEATURE_CUSTOMS_OFFICES", True)
55
55
  @patch(OWNERS_PATH + ".STRUCTURES_FEATURE_STARBASES", True)
56
56
  @patch("structures.webhooks.core.dhooks_lite.Webhook.execute", spec=True)
57
- @patch(TASKS_PATH + ".fetch_esi_status", lambda: EsiStatus(True, 99, 60))
58
57
  @patch(MANAGERS_PATH + ".esi")
59
58
  @patch(OWNERS_PATH + ".esi")
60
59
  class TestTasks(TestCase):
@@ -62,6 +61,7 @@ class TestTasks(TestCase):
62
61
  def setUpClass(cls):
63
62
  super().setUpClass()
64
63
  load_eveuniverse()
64
+ reset_celery_once_locks("structures")
65
65
 
66
66
  def test_should_fetch_new_upwell_structure_from_esi(
67
67
  self, mock_esi_2, mock_esi, mock_execute
@@ -3,9 +3,12 @@ from unittest.mock import patch
3
3
  from django.contrib.auth.models import User
4
4
  from django.test import TestCase, override_settings
5
5
 
6
- from app_utils.esi import EsiStatus
7
6
  from app_utils.testdata_factories import UserFactory
8
- from app_utils.testing import NoSocketsTestCase, generate_invalid_pk
7
+ from app_utils.testing import (
8
+ NoSocketsTestCase,
9
+ generate_invalid_pk,
10
+ reset_celery_once_locks,
11
+ )
9
12
 
10
13
  from structures import tasks
11
14
  from structures.core.notification_types import NotificationType
@@ -24,37 +27,40 @@ MODULE_PATH = "structures.tasks"
24
27
  MODULE_PATH_MODELS_OWNERS = "structures.models.owners"
25
28
 
26
29
 
30
+ @override_settings(CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True)
27
31
  @patch(MODULE_PATH + ".Webhook.send_queued_messages", spec=True)
28
32
  class TestSendMessagesForWebhook(TestCase):
29
33
  @classmethod
30
- def setUpClass(cls): # Can not be setUpTestData due to conflict with redis client
34
+ def setUpClass(cls):
31
35
  super().setUpClass()
32
36
  cls.webhook = WebhookFactory()
37
+ reset_celery_once_locks("structures")
33
38
 
34
39
  def test_normal(self, mock_send_queued_messages):
35
- tasks.send_messages_for_webhook(self.webhook.pk)
40
+ tasks.send_messages_for_webhook.delay(self.webhook.pk)
36
41
  self.assertEqual(mock_send_queued_messages.call_count, 1)
37
42
 
38
43
  def test_invalid_pk(self, mock_send_queued_messages):
39
- tasks.send_messages_for_webhook(generate_invalid_pk(Webhook))
44
+ tasks.send_messages_for_webhook.delay(generate_invalid_pk(Webhook))
40
45
  self.assertEqual(mock_send_queued_messages.call_count, 0)
41
46
 
42
47
  def test_disabled_webhook(self, mock_send_queued_messages):
43
48
  self.webhook.is_active = False
44
49
  self.webhook.save()
45
50
 
46
- tasks.send_messages_for_webhook(self.webhook.pk)
51
+ tasks.send_messages_for_webhook.delay(self.webhook.pk)
47
52
  self.assertEqual(mock_send_queued_messages.call_count, 0)
48
53
 
49
54
 
50
55
  @override_settings(CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True)
51
56
  @patch(MODULE_PATH + ".Owner.update_structures_esi", spec=True)
52
- class TestUpdateStructuresEsi(NoSocketsTestCase):
57
+ class TestUpdateStructuresEsi(TestCase):
53
58
  @classmethod
54
59
  def setUpClass(cls):
55
60
  super().setUpClass()
56
61
  cls.user = UserMainDefaultOwnerFactory()
57
62
  cls.owner = OwnerFactory(user=cls.user, is_alliance_main=True)
63
+ reset_celery_once_locks("structures")
58
64
 
59
65
  def test_call_structure_update_with_owner_only(self, mock_update_structures_esi):
60
66
  """TODO: Investigate how to call the top level method that contains the chains()"""
@@ -85,12 +91,13 @@ class TestUpdateStructuresEsi(NoSocketsTestCase):
85
91
 
86
92
  @override_settings(CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True)
87
93
  @patch(MODULE_PATH + ".update_structures_for_owner", spec=True)
88
- class TestUpdateStructuresForOwner(NoSocketsTestCase):
94
+ class TestUpdateStructuresForOwner(TestCase):
89
95
  @classmethod
90
96
  def setUpClass(cls):
91
97
  super().setUpClass()
92
98
  cls.user = UserMainDefaultOwnerFactory()
93
99
  cls.owner = OwnerFactory(user=cls.user, is_alliance_main=True)
100
+ reset_celery_once_locks("structures")
94
101
 
95
102
  def test_can_update_structures_for_all_owners(
96
103
  self, mock_update_structures_for_owner
@@ -117,19 +124,22 @@ class TestUpdateStructuresForOwner(NoSocketsTestCase):
117
124
  self.assertSetEqual(owner_pks, {self.owner.pk})
118
125
 
119
126
 
127
+ # TODO: Investigate how to call the top level method that contains the chains()
128
+
129
+
120
130
  @override_settings(CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True)
121
- class TestUpdateOwnerAsset(NoSocketsTestCase):
131
+ class TestUpdateOwnerAsset(TestCase):
122
132
  @classmethod
123
133
  def setUpClass(cls):
124
134
  super().setUpClass()
125
135
  cls.user = UserMainDefaultOwnerFactory()
126
136
  cls.owner = OwnerFactory(user=cls.user, is_alliance_main=True)
137
+ reset_celery_once_locks("structures")
127
138
 
128
139
  @patch(MODULE_PATH + ".Owner.update_asset_esi")
129
140
  def test_call_structure_asset_update_with_owner_and_user(
130
141
  self, mock_update_asset_esi
131
142
  ):
132
- """TODO: Investigate how to call the top level method that contains the chains()"""
133
143
  tasks.update_structures_assets_for_owner(self.owner.pk, self.user.pk)
134
144
  first, _ = mock_update_asset_esi.call_args
135
145
  self.assertEqual(first[0], self.user)
@@ -138,19 +148,14 @@ class TestUpdateOwnerAsset(NoSocketsTestCase):
138
148
  def test_call_structure_asset_update_with_owner_and_ignores_invalid_user(
139
149
  self, mock_update_asset_esi
140
150
  ):
141
- """TODO: Investigate how to call the top level method that contains the chains()"""
142
151
  tasks.update_structures_assets_for_owner(
143
152
  self.owner.pk, generate_invalid_pk(User)
144
153
  )
145
154
  first, _ = mock_update_asset_esi.call_args
146
155
  self.assertIsNone(first[0])
147
156
 
148
- @override_settings(
149
- CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True
150
- )
151
157
  def test_raises_exception_if_owner_is_unknown(self):
152
158
  with self.assertRaises(Owner.DoesNotExist):
153
- """TODO: Investigate how to call the top level method that contains the chains()"""
154
159
  tasks.update_structures_assets_for_owner(
155
160
  owner_pk=generate_invalid_pk(Owner)
156
161
  )
@@ -317,15 +322,15 @@ class TestUpdateNotificationsStructureRelations(NoSocketsTestCase):
317
322
  self.assertEqual(result, 0)
318
323
 
319
324
 
320
- @patch(MODULE_PATH + ".fetch_esi_status", lambda: EsiStatus(True))
321
- class TestOtherTasks(NoSocketsTestCase):
325
+ @override_settings(CELERY_ALWAYS_EAGER=True, CELERY_EAGER_PROPAGATES_EXCEPTIONS=True)
326
+ class TestOtherTasks(TestCase):
322
327
  @patch(
323
328
  MODULE_PATH + ".EveSovereigntyMap.objects.update_or_create_all_from_esi",
324
329
  spec=True,
325
330
  )
326
331
  def test_should_call_update_sov_map_from_esi(self, mock_update_from_esi):
327
332
  # when
328
- tasks.update_sov_map()
333
+ tasks.update_sov_map.delay()
329
334
  # then
330
335
  self.assertTrue(mock_update_from_esi.called)
331
336
 
@@ -334,7 +339,7 @@ class TestOtherTasks(NoSocketsTestCase):
334
339
  # given
335
340
  owner = OwnerFactory()
336
341
  # when
337
- tasks.fetch_notification_for_owner(owner.pk)
342
+ tasks.fetch_notification_for_owner.delay(owner.pk)
338
343
  # then
339
344
  self.assertTrue(mock_fetch_notifications_esi.called)
340
345
 
@@ -346,7 +351,7 @@ class TestOtherTasks(NoSocketsTestCase):
346
351
  # given
347
352
  owner = OwnerFactory()
348
353
  # when
349
- tasks.send_new_notifications_for_owner(owner.pk)
354
+ tasks.send_new_notifications_for_owner.delay(owner.pk)
350
355
  # then
351
356
  self.assertTrue(mock_send_new_notifications.called)
352
357
  self.assertTrue(mock_send_queued_messages_for_webhooks.called)
@@ -359,7 +364,7 @@ class TestOtherTasks(NoSocketsTestCase):
359
364
  # given
360
365
  config = FuelAlertConfigFactory()
361
366
  # when
362
- tasks.send_structure_fuel_notifications_for_config(config.pk)
367
+ tasks.send_structure_fuel_notifications_for_config.delay(config.pk)
363
368
  # then
364
369
  self.assertTrue(mock_send_new_notifications.called)
365
370
  self.assertTrue(mock_send_queued_messages_for_webhooks.called)
@@ -372,7 +377,7 @@ class TestOtherTasks(NoSocketsTestCase):
372
377
  # given
373
378
  config = JumpFuelAlertConfigFactory()
374
379
  # when
375
- tasks.send_jump_fuel_notifications_for_config(config.pk)
380
+ tasks.send_jump_fuel_notifications_for_config.delay(config.pk)
376
381
  # then
377
382
  self.assertTrue(mock_send_new_notifications.called)
378
383
  self.assertTrue(mock_send_queued_messages_for_webhooks.called)
File without changes
File without changes