Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added SPDX license identifiers to .vue, .ts, and .py files #1083

Merged
merged 11 commits into from
Jan 15, 2025
Merged
  •  
  •  
  •  
1 change: 1 addition & 0 deletions backend/authentication/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from typing import Any

from django import forms
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/apps.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.apps import AppConfig


Expand Down
1 change: 1 addition & 0 deletions backend/authentication/enums.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Enums for the authentication app.
More details about Enums can be found in schema section on Figma.
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from typing import Any

import factory
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the authentication app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for the authentication app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/tests.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Testing for the authentication app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/urls.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.urls import path

from authentication import views
Expand Down
1 change: 1 addition & 0 deletions backend/authentication/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import os
import uuid
from uuid import UUID
Expand Down
1 change: 1 addition & 0 deletions backend/communities/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.contrib import admin

from communities.groups.models import Group, GroupImage, GroupMember, GroupText
Expand Down
1 change: 1 addition & 0 deletions backend/communities/apps.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.apps import AppConfig


Expand Down
1 change: 1 addition & 0 deletions backend/communities/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import factory


Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import datetime

import factory
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for groups in the communities app.
"""
Expand Down
3 changes: 3 additions & 0 deletions backend/communities/groups/tests/test_group.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Testing for the Group model.
"""
Expand Down Expand Up @@ -64,6 +65,7 @@ def test_url_validations() -> None:
get_involved_url="not a url",
terms_checked=True,
)

group.full_clean()

# 2. Test valid URL.
Expand All @@ -77,6 +79,7 @@ def test_url_validations() -> None:
get_involved_url=fake.url(),
terms_checked=True,
)

group.full_clean()


Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/tests/test_group_events.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the GroupEvents entity.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/tests/test_group_member.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the GroupMember model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/tests/test_group_resource.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for GroupResource model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/tests/test_group_text.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the GroupText model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/tests/test_group_topic.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for GroupTopic model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/groups/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
# mypy: disable-error-code="override"
from rest_framework import status, viewsets
from rest_framework.request import Request
Expand Down
1 change: 1 addition & 0 deletions backend/communities/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import datetime

import factory
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for organizations in the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/tests/test_org_events.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the OrganizationEvents entity.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/tests/test_org_member.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the OrganizationMember model.
"""
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for OrganizationResource model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/tests/test_org_text.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for the OrganizationText model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/tests/test_org_topic.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Test cases for OrganizationTopic model.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/organizations/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
# mypy: disable-error-code="override"
from django.utils import timezone
from rest_framework import status, viewsets
Expand Down
1 change: 1 addition & 0 deletions backend/communities/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/tests.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Testing for the communities app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/communities/urls.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.urls import include, path
from rest_framework.routers import DefaultRouter

Expand Down
1 change: 1 addition & 0 deletions backend/communities/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
# mypy: disable-error-code="override"
from rest_framework import viewsets

Expand Down
1 change: 1 addition & 0 deletions backend/content/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.contrib import admin

from content.models import (
Expand Down
1 change: 1 addition & 0 deletions backend/content/apps.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.apps import AppConfig


Expand Down
1 change: 1 addition & 0 deletions backend/content/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import datetime
import random

Expand Down
1 change: 1 addition & 0 deletions backend/content/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the content app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/content/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for the content app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/content/tests.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Testing for the content app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/content/urls.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.urls import include, path
from rest_framework.routers import DefaultRouter

Expand Down
1 change: 1 addition & 0 deletions backend/content/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
# mypy: disable-error-code="override"
from django.db.models import Q
from rest_framework import status, viewsets
Expand Down
1 change: 1 addition & 0 deletions backend/core/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.contrib import admin

admin.site.site_header = "activist administration"
Expand Down
1 change: 1 addition & 0 deletions backend/core/asgi.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
ASGI config for the activist backend.

Expand Down
1 change: 1 addition & 0 deletions backend/core/custom_settings.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
This file contains granular settings specifically related to the activist project.
For more general settings strictly related to the functioning of Django and its components,
Expand Down
1 change: 1 addition & 0 deletions backend/core/exception_handler.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import logging
from typing import Any

Expand Down
1 change: 1 addition & 0 deletions backend/core/management/commands/populate_db.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import random
from argparse import ArgumentParser
from typing import TypedDict, Unpack
Expand Down
1 change: 1 addition & 0 deletions backend/core/management/commands/wait_for_db.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import sys
import time
from argparse import ArgumentParser
Expand Down
1 change: 1 addition & 0 deletions backend/core/paginator.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from rest_framework import pagination

from core import custom_settings
Expand Down
1 change: 1 addition & 0 deletions backend/core/settings.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Django settings for activist.org.

Expand Down
1 change: 1 addition & 0 deletions backend/core/tests/unit/conftest.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import pytest
from rest_framework.test import APIClient

Expand Down
1 change: 1 addition & 0 deletions backend/core/tests/unit/test_swagger.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from rest_framework.test import APIClient


Expand Down
1 change: 1 addition & 0 deletions backend/core/urls.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
URL configuration for the activist backend.

Expand Down
2 changes: 2 additions & 0 deletions backend/core/wsgi.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
WSGI config for the activist backend.

Expand All @@ -7,6 +8,7 @@
https://docs.djangoproject.com/en/4.2/howto/deployment/wsgi/
"""


import os

from django.core.wsgi import get_wsgi_application
Expand Down
1 change: 1 addition & 0 deletions backend/events/admin.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.contrib import admin

from events.models import (
Expand Down
1 change: 1 addition & 0 deletions backend/events/apps.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.apps import AppConfig


Expand Down
1 change: 1 addition & 0 deletions backend/events/factories.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import datetime
import random

Expand Down
1 change: 1 addition & 0 deletions backend/events/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Models for the events app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/events/serializers.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Serializers for the events app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/events/tests.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
"""
Testing for the events app.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/events/urls.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from django.urls import include, path
from rest_framework.routers import DefaultRouter

Expand Down
1 change: 1 addition & 0 deletions backend/events/views.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
from rest_framework import status, viewsets
from rest_framework.request import Request
from rest_framework.response import Response
Expand Down
2 changes: 2 additions & 0 deletions backend/manage.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
#!/usr/bin/env python

"""
Django's command-line utility for administrative tasks.
"""
Expand Down
1 change: 1 addition & 0 deletions backend/utils/models.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
ISO_CHOICES = [
("en", "en"),
("de", "de"),
Expand Down
1 change: 1 addition & 0 deletions backend/utils/utils.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# SPDX-License-Identifier: AGPL-3.0-or-later
import re
from typing import Any

Expand Down
1 change: 1 addition & 0 deletions frontend/app.config.ts
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
export default {};
1 change: 1 addition & 0 deletions frontend/app.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<Loading />
<div>
Expand Down
1 change: 1 addition & 0 deletions frontend/applyMiddleware.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
// SPDX-License-Identifier: AGPL-3.0-or-later
import type { NuxtPage } from "nuxt/schema";
import type { RouteLocationNormalizedGeneric } from "vue-router";

Expand Down
1 change: 1 addition & 0 deletions frontend/components/EmptyState.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<div class="flex w-full flex-col items-center bg-layer-0 text-primary-text">
<PageContent
Expand Down
1 change: 1 addition & 0 deletions frontend/components/FriendlyCaptcha.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<div class="rounded-md border border-primary-text">
<vue-friendly-captcha
Expand Down
1 change: 1 addition & 0 deletions frontend/components/Loading.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<!-- Note: Commented out until such a time when it's needed and triggered explicitly. -->
<div />
Expand Down
1 change: 1 addition & 0 deletions frontend/components/SearchBar.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<div
v-if="location == SearchBarLocation.SIDEBAR"
Expand Down
1 change: 1 addition & 0 deletions frontend/components/btn/BtnIconsLabel.vue
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
<!-- SPDX-License-Identifier: AGPL-3.0-or-later -->
<template>
<div class="h-fill flex items-center justify-center">
<Icon
Expand Down
Loading
Loading