wbnews 2.2.4__tar.gz → 2.2.5__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.
- {wbnews-2.2.4 → wbnews-2.2.5}/PKG-INFO +1 -1
- {wbnews-2.2.4 → wbnews-2.2.5}/pyproject.toml +2 -6
- wbnews-2.2.4/wbnews/.coveragerc +0 -23
- wbnews-2.2.4/wbnews/__init__.py +0 -1
- wbnews-2.2.4/wbnews/admin.py +0 -27
- wbnews-2.2.4/wbnews/apps.py +0 -9
- wbnews-2.2.4/wbnews/factories.py +0 -33
- wbnews-2.2.4/wbnews/fixtures/wbnews.yaml +0 -1
- wbnews-2.2.4/wbnews/import_export/__init__.py +0 -0
- wbnews-2.2.4/wbnews/import_export/backends/__init__.py +0 -1
- wbnews-2.2.4/wbnews/import_export/backends/news.py +0 -35
- wbnews-2.2.4/wbnews/import_export/handlers/__init__.py +0 -1
- wbnews-2.2.4/wbnews/import_export/handlers/news.py +0 -25
- wbnews-2.2.4/wbnews/import_export/parsers/__init__.py +0 -0
- wbnews-2.2.4/wbnews/import_export/parsers/emails/__init__.py +0 -0
- wbnews-2.2.4/wbnews/import_export/parsers/emails/news.py +0 -48
- wbnews-2.2.4/wbnews/import_export/parsers/emails/utils.py +0 -61
- wbnews-2.2.4/wbnews/import_export/parsers/rss/__init__.py +0 -0
- wbnews-2.2.4/wbnews/import_export/parsers/rss/news.py +0 -63
- wbnews-2.2.4/wbnews/locale/de/LC_MESSAGES/django.po +0 -112
- wbnews-2.2.4/wbnews/migrations/0001_initial_squashed_0005_alter_news_import_source.py +0 -349
- wbnews-2.2.4/wbnews/migrations/0006_alter_news_language.py +0 -122
- wbnews-2.2.4/wbnews/migrations/0007_auto_20240103_0955.py +0 -43
- wbnews-2.2.4/wbnews/migrations/0008_alter_news_language.py +0 -123
- wbnews-2.2.4/wbnews/migrations/0009_newsrelationship_analysis_newsrelationship_sentiment.py +0 -94
- wbnews-2.2.4/wbnews/migrations/__init__.py +0 -0
- wbnews-2.2.4/wbnews/models/__init__.py +0 -3
- wbnews-2.2.4/wbnews/models/llm/cleaned_news.py +0 -63
- wbnews-2.2.4/wbnews/models/news.py +0 -116
- wbnews-2.2.4/wbnews/models/relationships.py +0 -20
- wbnews-2.2.4/wbnews/models/sources.py +0 -43
- wbnews-2.2.4/wbnews/serializers.py +0 -83
- wbnews-2.2.4/wbnews/signals.py +0 -4
- wbnews-2.2.4/wbnews/tests/__init__.py +0 -0
- wbnews-2.2.4/wbnews/tests/conftest.py +0 -6
- wbnews-2.2.4/wbnews/tests/test_models.py +0 -15
- wbnews-2.2.4/wbnews/tests/tests.py +0 -12
- wbnews-2.2.4/wbnews/urls.py +0 -29
- wbnews-2.2.4/wbnews/viewsets/__init__.py +0 -12
- wbnews-2.2.4/wbnews/viewsets/buttons.py +0 -23
- wbnews-2.2.4/wbnews/viewsets/display.py +0 -133
- wbnews-2.2.4/wbnews/viewsets/endpoints.py +0 -18
- wbnews-2.2.4/wbnews/viewsets/menu.py +0 -23
- wbnews-2.2.4/wbnews/viewsets/titles.py +0 -39
- wbnews-2.2.4/wbnews/viewsets/views.py +0 -140
- {wbnews-2.2.4 → wbnews-2.2.5}/.gitignore +0 -0
|
@@ -19,12 +19,8 @@ package = true
|
|
|
19
19
|
[tool.hatch.version]
|
|
20
20
|
path = "../../pyproject.toml"
|
|
21
21
|
|
|
22
|
-
[tool.hatch.build
|
|
23
|
-
include = ["
|
|
24
|
-
|
|
25
|
-
[tool.hatch.build.targets.wheel]
|
|
26
|
-
packages = ["wbnews"]
|
|
27
|
-
only-packages = true
|
|
22
|
+
[tool.hatch.build]
|
|
23
|
+
include = ["wbwiki/**/*.py"]
|
|
28
24
|
|
|
29
25
|
[build-system]
|
|
30
26
|
requires = ["hatchling"]
|
wbnews-2.2.4/wbnews/.coveragerc
DELETED
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
[report]
|
|
2
|
-
exclude_lines =
|
|
3
|
-
print()
|
|
4
|
-
def api_endpoints_root
|
|
5
|
-
def get_or_create_model_sql
|
|
6
|
-
def profile_check
|
|
7
|
-
if hasattr
|
|
8
|
-
raise Exception
|
|
9
|
-
raise Http404
|
|
10
|
-
except:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
[run]
|
|
14
|
-
omit = */migrations/*
|
|
15
|
-
manage.py
|
|
16
|
-
*/tests/*
|
|
17
|
-
*/wbnews_config/*
|
|
18
|
-
*/apps.py
|
|
19
|
-
*/docs/*
|
|
20
|
-
*/dynamic_preferences_registry.py
|
|
21
|
-
*/permissions.py
|
|
22
|
-
*/preferences/*
|
|
23
|
-
*/.venv/*
|
wbnews-2.2.4/wbnews/__init__.py
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
__version__ = "1.0.0"
|
wbnews-2.2.4/wbnews/admin.py
DELETED
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
from django.contrib import admin
|
|
2
|
-
|
|
3
|
-
from .models import News, NewsRelationship, NewsSource
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
@admin.register(NewsRelationship)
|
|
7
|
-
class NewsRelationshipAdmin(admin.ModelAdmin):
|
|
8
|
-
list_display = ["news", "content_object"]
|
|
9
|
-
autocomplete_fields = ["news"]
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
@admin.register(News)
|
|
13
|
-
class NewsAdmin(admin.ModelAdmin):
|
|
14
|
-
search_fields = ("title", "description")
|
|
15
|
-
raw_id_fields = ["import_source"]
|
|
16
|
-
autocomplete_fields = [
|
|
17
|
-
"source",
|
|
18
|
-
]
|
|
19
|
-
list_display = ["title", "language", "tags", "source", "datetime"]
|
|
20
|
-
|
|
21
|
-
list_filter = ("source",)
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
@admin.register(NewsSource)
|
|
25
|
-
class NewsSourceAdmin(admin.ModelAdmin):
|
|
26
|
-
search_fields = ("type", "title", "identifier", "description", "author", "url")
|
|
27
|
-
list_filter = ("type",)
|
wbnews-2.2.4/wbnews/apps.py
DELETED
wbnews-2.2.4/wbnews/factories.py
DELETED
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
import factory
|
|
2
|
-
from django.conf.global_settings import LANGUAGES
|
|
3
|
-
from django.utils import timezone
|
|
4
|
-
from faker import Factory
|
|
5
|
-
from wbnews.models import News, NewsSource
|
|
6
|
-
|
|
7
|
-
langs = [n for (n, v) in LANGUAGES]
|
|
8
|
-
faker = Factory.create()
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
class NewsSourceFactory(factory.django.DjangoModelFactory):
|
|
12
|
-
title = factory.Sequence(lambda n: f"source_{n}")
|
|
13
|
-
identifier = factory.Sequence(lambda n: f"http://myurl_{n}.com")
|
|
14
|
-
image = faker.url()
|
|
15
|
-
description = factory.Faker("sentence", nb_words=32)
|
|
16
|
-
author = faker.name()
|
|
17
|
-
url = factory.Faker("url")
|
|
18
|
-
|
|
19
|
-
class Meta:
|
|
20
|
-
model = NewsSource
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
class NewsFactory(factory.django.DjangoModelFactory):
|
|
24
|
-
datetime = factory.LazyFunction(timezone.now)
|
|
25
|
-
title = factory.Sequence(lambda n: f"news_{n}")
|
|
26
|
-
description = factory.Faker("sentence", nb_words=32)
|
|
27
|
-
summary = factory.Faker("sentence", nb_words=32)
|
|
28
|
-
language = factory.Iterator(langs)
|
|
29
|
-
link = faker.url()
|
|
30
|
-
source = factory.SubFactory(NewsSourceFactory)
|
|
31
|
-
|
|
32
|
-
class Meta:
|
|
33
|
-
model = News
|