arthexis 0.1.3__py3-none-any.whl → 0.1.4__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.
Potentially problematic release.
This version of arthexis might be problematic. Click here for more details.
- {arthexis-0.1.3.dist-info → arthexis-0.1.4.dist-info}/METADATA +1 -1
- {arthexis-0.1.3.dist-info → arthexis-0.1.4.dist-info}/RECORD +8 -8
- core/views.py +10 -0
- pages/tests.py +23 -0
- pages/views.py +2 -1
- {arthexis-0.1.3.dist-info → arthexis-0.1.4.dist-info}/WHEEL +0 -0
- {arthexis-0.1.3.dist-info → arthexis-0.1.4.dist-info}/licenses/LICENSE +0 -0
- {arthexis-0.1.3.dist-info → arthexis-0.1.4.dist-info}/top_level.txt +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
arthexis-0.1.
|
|
1
|
+
arthexis-0.1.4.dist-info/licenses/LICENSE,sha256=rBjcKtvD5yIpzAnkw3XRofK8KCAeL43DXmNaiRuYJrg,1092
|
|
2
2
|
config/__init__.py,sha256=5EyLFDrM6aTOHSnyBcLXRvMInZMPmAAy9Icu0cHHK5o,110
|
|
3
3
|
config/active_app.py,sha256=MET_G7oHL7GkoSo3VkkMzymM-PwsSZazMLZxpgjFLTo,388
|
|
4
4
|
config/asgi.py,sha256=n09URedOmQ_59II3UCl3iodGSDWOuN_A8DFyfLjuylA,803
|
|
@@ -29,7 +29,7 @@ core/tasks.py,sha256=Q4QweRlhahbXYEeL9ytlyQWwWQFP63q-ZY_fN0EXwtg,3145
|
|
|
29
29
|
core/tests.py,sha256=hQLrDtnieZaThs5mWQXezcYFzLAqqSg4gTsHIlyq4-A,17872
|
|
30
30
|
core/urls.py,sha256=pBkcWdiA0Aag7z4UOu7HT4Im4ghPPfBZKeogmoO0H5U,406
|
|
31
31
|
core/user_data.py,sha256=pfi4fgHl0CosG9jkfe__bSNN-Knhnzp7UirnCT_tae8,12029
|
|
32
|
-
core/views.py,sha256=
|
|
32
|
+
core/views.py,sha256=mrCvhMSUH42v1S6j9Lx5P1e64zFmv-WiadpesObIUrw,15786
|
|
33
33
|
nodes/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
34
34
|
nodes/actions.py,sha256=2QOtRdhm__4f0Pgy3n2tg9HCbS47ZK9qBdTXJ9YZJfA,2339
|
|
35
35
|
nodes/admin.py,sha256=YCjKqnb3GbYhke8CQI1VBzOliYjFEvJFkpobcxixfPY,12877
|
|
@@ -63,11 +63,11 @@ pages/apps.py,sha256=P1zJH4LV3ATTu7z4r_BA-fiOtui_UW6-GP--LNMUYhs,299
|
|
|
63
63
|
pages/checks.py,sha256=E2_ZYPD-2vw27ImA-Q29OvxbdQUvKx26ACZwiPflTaI,1569
|
|
64
64
|
pages/context_processors.py,sha256=mQj43pb4Y1u8cfBrl3m0bP-_iWHDKXxfuRE4Rbn6l-g,2432
|
|
65
65
|
pages/models.py,sha256=vG2knV91jRJ5PpIB-UKbsyuzB-e0KXYi9lwCFbIVUSA,7536
|
|
66
|
-
pages/tests.py,sha256=
|
|
66
|
+
pages/tests.py,sha256=3swTFfuMI9mYJ3XgFQlqgVpj5Ojp6j0_6VMAVTI0J4g,27103
|
|
67
67
|
pages/urls.py,sha256=glhQExK2vVLzzvaRypWfmMdnggBrpjlxCaN1BUbC_MY,457
|
|
68
68
|
pages/utils.py,sha256=bCcjku0mQhzgvTR46QwQgyc8YnSS7VumC6Qv968aCic,313
|
|
69
|
-
pages/views.py,sha256=
|
|
70
|
-
arthexis-0.1.
|
|
71
|
-
arthexis-0.1.
|
|
72
|
-
arthexis-0.1.
|
|
73
|
-
arthexis-0.1.
|
|
69
|
+
pages/views.py,sha256=8CZcf-LW2KwZnQjZkB3TFoTN2wFNI-gnMlvMi9o3FMs,7073
|
|
70
|
+
arthexis-0.1.4.dist-info/METADATA,sha256=lPZrVqhdlVkaHwTMmihYrzVwlTkEs3k7JnNdsI_ypiI,4507
|
|
71
|
+
arthexis-0.1.4.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
|
|
72
|
+
arthexis-0.1.4.dist-info/top_level.txt,sha256=J2a2q8_BWrCZ8H2WFUNMBfO2jz8j2gax6zZh-_1QDac,29
|
|
73
|
+
arthexis-0.1.4.dist-info/RECORD,,
|
core/views.py
CHANGED
|
@@ -43,6 +43,16 @@ def _changelog_notes(version: str) -> str:
|
|
|
43
43
|
|
|
44
44
|
def _step_check_pypi(release, ctx, log_path: Path) -> None:
|
|
45
45
|
from . import release as release_utils
|
|
46
|
+
from packaging.version import Version
|
|
47
|
+
|
|
48
|
+
version_path = Path("VERSION")
|
|
49
|
+
if version_path.exists():
|
|
50
|
+
current = version_path.read_text(encoding="utf-8").strip()
|
|
51
|
+
if current and Version(release.version) < Version(current):
|
|
52
|
+
raise Exception(
|
|
53
|
+
f"Version {release.version} is older than existing {current}"
|
|
54
|
+
)
|
|
55
|
+
version_path.write_text(release.version + "\n", encoding="utf-8")
|
|
46
56
|
|
|
47
57
|
_append_log(log_path, f"Checking if version {release.version} exists on PyPI")
|
|
48
58
|
if release_utils.network_available():
|
pages/tests.py
CHANGED
|
@@ -9,6 +9,7 @@ from pages.models import Application, Module, SiteBadge, Favorite
|
|
|
9
9
|
from core.user_data import UserDatum
|
|
10
10
|
from pages.admin import ApplicationAdmin
|
|
11
11
|
from django.apps import apps as django_apps
|
|
12
|
+
from core.models import AdminHistory
|
|
12
13
|
from django.core.files.uploadedfile import SimpleUploadedFile
|
|
13
14
|
import base64
|
|
14
15
|
import tempfile
|
|
@@ -86,6 +87,13 @@ class InvitationTests(TestCase):
|
|
|
86
87
|
resp = self.client.get(reverse("pages:request-invite"))
|
|
87
88
|
self.assertIn("csrftoken", resp.cookies)
|
|
88
89
|
|
|
90
|
+
def test_request_invite_allows_post_without_csrf(self):
|
|
91
|
+
client = Client(enforce_csrf_checks=True)
|
|
92
|
+
resp = client.post(
|
|
93
|
+
reverse("pages:request-invite"), {"email": "invite@example.com"}
|
|
94
|
+
)
|
|
95
|
+
self.assertEqual(resp.status_code, 200)
|
|
96
|
+
|
|
89
97
|
def test_invitation_flow(self):
|
|
90
98
|
resp = self.client.post(
|
|
91
99
|
reverse("pages:request-invite"), {"email": "invite@example.com"}
|
|
@@ -626,3 +634,18 @@ class FavoriteTests(TestCase):
|
|
|
626
634
|
resp = self.client.get(reverse("admin:index"))
|
|
627
635
|
self.assertContains(resp, reverse("admin:pages_application_changelist"))
|
|
628
636
|
self.assertContains(resp, reverse("admin:nodes_noderole_changelist"))
|
|
637
|
+
|
|
638
|
+
def test_dashboard_merges_duplicate_future_actions(self):
|
|
639
|
+
ct = ContentType.objects.get_for_model(NodeRole)
|
|
640
|
+
Favorite.objects.create(user=self.user, content_type=ct)
|
|
641
|
+
role = NodeRole.objects.create(name="DataRole2")
|
|
642
|
+
UserDatum.objects.create(user=self.user, content_type=ct, object_id=role.pk)
|
|
643
|
+
AdminHistory.objects.create(
|
|
644
|
+
user=self.user,
|
|
645
|
+
content_type=ct,
|
|
646
|
+
url=reverse("admin:nodes_noderole_changelist"),
|
|
647
|
+
)
|
|
648
|
+
resp = self.client.get(reverse("admin:index"))
|
|
649
|
+
url = reverse("admin:nodes_noderole_changelist")
|
|
650
|
+
self.assertEqual(resp.content.decode().count(url), 1)
|
|
651
|
+
self.assertContains(resp, NodeRole._meta.verbose_name_plural)
|
pages/views.py
CHANGED
|
@@ -16,7 +16,7 @@ from django.utils.encoding import force_bytes, force_str
|
|
|
16
16
|
from django.utils.http import urlsafe_base64_decode, urlsafe_base64_encode
|
|
17
17
|
from django.core.mail import send_mail
|
|
18
18
|
from django.utils.translation import gettext as _
|
|
19
|
-
from django.views.decorators.csrf import ensure_csrf_cookie
|
|
19
|
+
from django.views.decorators.csrf import csrf_exempt, ensure_csrf_cookie
|
|
20
20
|
|
|
21
21
|
import markdown
|
|
22
22
|
from pages.utils import landing
|
|
@@ -116,6 +116,7 @@ login_view = CustomLoginView.as_view()
|
|
|
116
116
|
class InvitationRequestForm(forms.Form):
|
|
117
117
|
email = forms.EmailField()
|
|
118
118
|
|
|
119
|
+
@csrf_exempt
|
|
119
120
|
@ensure_csrf_cookie
|
|
120
121
|
def request_invite(request):
|
|
121
122
|
form = InvitationRequestForm(request.POST if request.method == "POST" else None)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|