aa-alumni 0.1.6a0__tar.gz → 0.2.0__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 aa-alumni might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2023 Joel Falknau
3
+ Copyright (c) 2021 Joel Falknau
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: aa_alumni
3
- Version: 0.1.6a0
3
+ Version: 0.2.0
4
4
  Summary: Integration with Alliance Auths State System, creates and maintains an Alumni State for past members of an Alliance and/or Corporation
5
5
  Keywords: allianceauth,eveonline
6
6
  Author-email: Joel Falknau <joel.falknau@gmail.com>
@@ -10,6 +10,7 @@ Classifier: Environment :: Web Environment
10
10
  Classifier: Framework :: Celery
11
11
  Classifier: Framework :: Django
12
12
  Classifier: Framework :: Django :: 4.0
13
+ Classifier: Framework :: Django :: 4.2
13
14
  Classifier: Intended Audience :: Developers
14
15
  Classifier: License :: OSI Approved :: MIT License
15
16
  Classifier: Operating System :: OS Independent
@@ -19,13 +20,12 @@ Classifier: Programming Language :: Python :: 3.8
19
20
  Classifier: Programming Language :: Python :: 3.9
20
21
  Classifier: Programming Language :: Python :: 3.10
21
22
  Classifier: Programming Language :: Python :: 3.11
23
+ Classifier: Programming Language :: Python :: 3.12
22
24
  Classifier: Programming Language :: Python :: Implementation :: CPython
23
25
  Classifier: Topic :: Internet :: WWW/HTTP
24
26
  Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
25
27
  Requires-Dist: allianceauth>=3.0.0,<5.0.0
26
- Requires-Dist: django-eveuniverse
27
28
  Requires-Dist: django-solo>=2.0.0,<3.0.0
28
- Requires-Dist: py-cord>=2.0.0,<3.0.0
29
29
  Project-URL: Homepage, https://gitlab.com/tactical-supremacy/aa-alumni
30
30
  Project-URL: Source, https://gitlab.com/tactical-supremacy/aa-alumni
31
31
  Project-URL: Tracker, https://gitlab.com/tactical-supremacy/aa-alumni/-/issues
@@ -44,7 +44,7 @@ Remove/Promote any state with a priority of `1`, Alumni is considered slightly b
44
44
 
45
45
  ### Step 2 - Install from pip
46
46
 
47
- ```bash
47
+ ```shell
48
48
  pip install aa-alumni
49
49
  ```
50
50
 
@@ -70,7 +70,7 @@ CELERYBEAT_SCHEDULE['alumni_run_update_all_models'] = {
70
70
 
71
71
  ### Step 4 - Update AA's State system
72
72
 
73
- ```bash
73
+ ```shell
74
74
  python myauth/manage.py alumni_state
75
75
  ```
76
76
 
@@ -12,7 +12,7 @@ Remove/Promote any state with a priority of `1`, Alumni is considered slightly b
12
12
 
13
13
  ### Step 2 - Install from pip
14
14
 
15
- ```bash
15
+ ```shell
16
16
  pip install aa-alumni
17
17
  ```
18
18
 
@@ -38,7 +38,7 @@ CELERYBEAT_SCHEDULE['alumni_run_update_all_models'] = {
38
38
 
39
39
  ### Step 4 - Update AA's State system
40
40
 
41
- ```bash
41
+ ```shell
42
42
  python myauth/manage.py alumni_state
43
43
  ```
44
44
 
@@ -1,5 +1,5 @@
1
1
  """
2
2
  Integration with Alliance Auths State System, creates and maintains an Alumni State for past members of an Alliance and/or Corporation
3
3
  """
4
- __version__ = "0.1.6a"
4
+ __version__ = "0.2.0"
5
5
  __title__ = "Alumni"
@@ -8,9 +8,7 @@ from .models import (
8
8
  @admin.register(AlumniSetup)
9
9
  class AlumniSetupAdmin(admin.ModelAdmin):
10
10
  search_fields = ['alumni_corporations', ]
11
- filter_horizontal = [
12
- "alumni_corporations",
13
- "alumni_alliances"]
11
+ filter_horizontal = ["alumni_corporations", "alumni_alliances"]
14
12
 
15
13
 
16
14
  @admin.register(CorporationAllianceHistory)
@@ -2,4 +2,4 @@ from django.conf import settings
2
2
 
3
3
  ALUMNI_STATE_NAME = getattr(settings, 'ALUMNI_STATE_NAME', "Alumni")
4
4
 
5
- ALUMNI_TASK_PRIORITY = getattr(settings, 'ALUMNI_TASK_PRIORITY', "7")
5
+ ALUMNI_TASK_PRIORITY = getattr(settings, 'ALUMNI_TASK_PRIORITY', 7)
@@ -7,4 +7,4 @@ class AlumniConfig(AppConfig):
7
7
  default_auto_field = 'django.db.models.BigAutoField'
8
8
  name = "alumni"
9
9
  label = "alumni"
10
- verbose_name = f"alumni v{__version__}"
10
+ verbose_name = f"AA Alumni v{__version__}"
@@ -0,0 +1,42 @@
1
+ # SOME DESCRIPTIVE TITLE.
2
+ # Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
3
+ # This file is distributed under the same license as the PACKAGE package.
4
+ # FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
5
+ #
6
+ #, fuzzy
7
+ msgid ""
8
+ msgstr ""
9
+ "Project-Id-Version: PACKAGE VERSION\n"
10
+ "Report-Msgid-Bugs-To: \n"
11
+ "POT-Creation-Date: 2024-05-11 18:13+1000\n"
12
+ "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
13
+ "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
14
+ "Language-Team: LANGUAGE <LL@li.org>\n"
15
+ "Language: \n"
16
+ "MIME-Version: 1.0\n"
17
+ "Content-Type: text/plain; charset=UTF-8\n"
18
+ "Content-Transfer-Encoding: 8bit\n"
19
+ "Plural-Forms: nplurals=2; plural=(n != 1);\n"
20
+ #: alumni/models.py:14
21
+ msgid ""
22
+ "Characters with these Corps in their History will be given Alumni Status"
23
+ msgstr ""
24
+
25
+ #: alumni/models.py:18
26
+ msgid ""
27
+ "Characters with these Alliances in their History will be given Alumni Status"
28
+ msgstr ""
29
+
30
+ #: alumni/models.py:21 alumni/models.py:24 alumni/models.py:25
31
+ msgid "Alumni Config"
32
+ msgstr ""
33
+
34
+ #: alumni/models.py:37 alumni/models.py:52
35
+ msgid "True if the corporation has been deleted"
36
+ msgstr ""
37
+
38
+ #: alumni/models.py:39 alumni/models.py:54
39
+ msgid ""
40
+ "An incrementing ID that can be used to canonically establish order of "
41
+ "records in cases where dates may be ambiguous"
42
+ msgstr ""
@@ -0,0 +1,27 @@
1
+ # Generated by Django 4.2.10 on 2024-05-11 08:13
2
+
3
+ from django.db import migrations, models
4
+
5
+
6
+ class Migration(migrations.Migration):
7
+
8
+ dependencies = [
9
+ ('alumni', '0002_auto_20211230_0147'),
10
+ ]
11
+
12
+ operations = [
13
+ migrations.AlterModelOptions(
14
+ name='alumnisetup',
15
+ options={'verbose_name': 'Alumni Config', 'verbose_name_plural': 'Alumni Config'},
16
+ ),
17
+ migrations.AlterField(
18
+ model_name='charactercorporationhistory',
19
+ name='record_id',
20
+ field=models.PositiveIntegerField(help_text='An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous'),
21
+ ),
22
+ migrations.AlterField(
23
+ model_name='corporationalliancehistory',
24
+ name='record_id',
25
+ field=models.PositiveIntegerField(help_text='An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous'),
26
+ ),
27
+ ]
@@ -0,0 +1,56 @@
1
+ from solo.models import SingletonModel
2
+
3
+ from django.db import models
4
+ from django.utils.translation import gettext as _
5
+
6
+ from allianceauth.eveonline.models import (
7
+ EveAllianceInfo, EveCharacter, EveCorporationInfo,
8
+ )
9
+
10
+
11
+ class AlumniSetup(SingletonModel):
12
+ alumni_corporations = models.ManyToManyField(
13
+ EveCorporationInfo,
14
+ blank=True,
15
+ help_text=_("Characters with these Corps in their History will be given Alumni Status"))
16
+ alumni_alliances = models.ManyToManyField(
17
+ EveAllianceInfo,
18
+ blank=True,
19
+ help_text=_("Characters with these Alliances in their History will be given Alumni Status"))
20
+
21
+ def __str__(self):
22
+ return _("Alumni Config")
23
+
24
+ class Meta:
25
+ verbose_name = _("Alumni Config")
26
+ verbose_name_plural = _("Alumni Config")
27
+
28
+
29
+ class CorporationAllianceHistory(models.Model):
30
+ class Meta:
31
+ constraints = [
32
+ models.UniqueConstraint(fields=['corporation_id', 'record_id'], name="CorporationAllianceRecord"),
33
+ ]
34
+ corporation_id = models.PositiveIntegerField(db_index=True)
35
+ alliance_id = models.PositiveIntegerField(blank=True, null=True, db_index=True)
36
+ is_deleted = models.BooleanField(
37
+ default=False,
38
+ help_text=_("True if the corporation has been deleted"))
39
+ record_id = models.PositiveIntegerField(
40
+ help_text=_("An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous"))
41
+ start_date = models.DateTimeField()
42
+
43
+
44
+ class CharacterCorporationHistory(models.Model):
45
+ class Meta:
46
+ constraints = [
47
+ models.UniqueConstraint(fields=['character', 'record_id'], name="CharacterCorporationRecord"),
48
+ ]
49
+ character = models.ForeignKey(EveCharacter, on_delete=models.CASCADE)
50
+ corporation_id = models.PositiveIntegerField()
51
+ is_deleted = models.BooleanField(
52
+ default=False,
53
+ help_text=_("True if the corporation has been deleted"))
54
+ record_id = models.PositiveIntegerField(
55
+ help_text=_("An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous"))
56
+ start_date = models.DateTimeField()
@@ -20,6 +20,7 @@ classifiers = [
20
20
  "Framework :: Celery",
21
21
  "Framework :: Django",
22
22
  "Framework :: Django :: 4.0",
23
+ "Framework :: Django :: 4.2",
23
24
  "Intended Audience :: Developers",
24
25
  "License :: OSI Approved :: MIT License",
25
26
  "Operating System :: OS Independent",
@@ -29,15 +30,14 @@ classifiers = [
29
30
  "Programming Language :: Python :: 3.9",
30
31
  "Programming Language :: Python :: 3.10",
31
32
  "Programming Language :: Python :: 3.11",
33
+ "Programming Language :: Python :: 3.12",
32
34
  "Programming Language :: Python :: Implementation :: CPython",
33
35
  "Topic :: Internet :: WWW/HTTP",
34
36
  "Topic :: Internet :: WWW/HTTP :: Dynamic Content"
35
37
  ]
36
38
  dependencies = [
37
39
  "allianceauth>=3.0.0,<5.0.0",
38
- "django-eveuniverse",
39
- "django-solo>=2.0.0,<3.0.0",
40
- "py-cord>=2.0.0,<3.0.0"
40
+ "django-solo>=2.0.0,<3.0.0"
41
41
  ]
42
42
 
43
43
  [project.urls]
@@ -68,3 +68,8 @@ exclude = [".git", "*migrations*", ".tox", "dist", "htmlcov"]
68
68
  max-line-length = 119
69
69
  select = ["C", "E", "F", "W", "B", "B950"]
70
70
  ignore = ['E203', 'E231', 'E501', 'W503', 'W291', 'W293']
71
+
72
+ [tool.djlint]
73
+ max_attribute_length=119
74
+ max_line_length=119
75
+ max_blank_lines=1
@@ -1,60 +0,0 @@
1
- from django.core.exceptions import ValidationError
2
- from django.db import models
3
-
4
- from allianceauth.eveonline.models import (
5
- EveAllianceInfo, EveCharacter, EveCorporationInfo,
6
- )
7
-
8
-
9
- class AlumniSetup(models.Model):
10
- alumni_corporations = models.ManyToManyField(
11
- EveCorporationInfo,
12
- blank=True,
13
- help_text="Characters with these Corps in their History will be given Alumni Status")
14
- alumni_alliances = models.ManyToManyField(
15
- EveAllianceInfo,
16
- blank=True,
17
- help_text="Characters with these Alliances in their History will be given Alumni Status")
18
-
19
- def save(self, *args, **kwargs):
20
- if not self.pk and AlumniSetup.objects.exists():
21
- # Force a single object
22
- raise ValidationError('There is can be only one \
23
- AlumniCorp instance')
24
- self.pk = self.id = 1 # If this happens to be deleted and recreated, force it to be 1
25
- return super().save(*args, **kwargs)
26
-
27
- class Meta:
28
- verbose_name_plural = "Alumni Config"
29
-
30
-
31
- class CorporationAllianceHistory(models.Model):
32
- class Meta:
33
- constraints = [
34
- models.UniqueConstraint(fields=['corporation_id', 'record_id'], name="CorporationAllianceRecord"),
35
- ]
36
- corporation_id = models.PositiveIntegerField(db_index=True)
37
- alliance_id = models.PositiveIntegerField(blank=True, null=True, db_index=True)
38
- is_deleted = models.BooleanField(
39
- default=False,
40
- help_text='True if the corporation has been deleted')
41
- record_id = models.IntegerField(
42
- help_text='An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous')
43
- start_date = models.DateTimeField()
44
-
45
-
46
- class CharacterCorporationHistory(models.Model):
47
- class Meta:
48
- constraints = [
49
- models.UniqueConstraint(fields=['character', 'record_id'], name="CharacterCorporationRecord"),
50
- ]
51
- character = models.ForeignKey(
52
- EveCharacter,
53
- on_delete=models.CASCADE)
54
- corporation_id = models.PositiveIntegerField()
55
- is_deleted = models.BooleanField(
56
- default=False,
57
- help_text='True if the corporation has been deleted')
58
- record_id = models.IntegerField(
59
- help_text='An incrementing ID that can be used to canonically establish order of records in cases where dates may be ambiguous')
60
- start_date = models.DateTimeField()
File without changes
File without changes