From af0641301b9371af1956506a3a9d043fa5b535e4 Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Sat, 30 Jan 2021 16:37:03 +0100
Subject: [PATCH 1/6] moved the insert_date from podpost into archive
---
python/podcast/archive.py | 39 +-
python/podcast/data_migration.py | 28 +-
qml/components/ArchiveHandler.py | 5 +-
test/test_archive.py | 23 +-
test/test_migration_to_v1.py | 3 +-
test/test_podpost.py | 10 +-
test/test_queue.py | 10 +-
test/testdata/freakshow.rss | 5392 +-----------------------------
8 files changed, 86 insertions(+), 5424 deletions(-)
diff --git a/python/podcast/archive.py b/python/podcast/archive.py
index 0e2d649..ba5fa93 100644
--- a/python/podcast/archive.py
+++ b/python/podcast/archive.py
@@ -1,9 +1,10 @@
"""
Archive of listened poposts
"""
-
+import datetime
import sys
import time
+from typing import List, Any
sys.path.append("../")
@@ -13,17 +14,30 @@ from podcast.factory import Factory
archivename = "the_archive"
+class ArchiveEntry:
+ insert_date: float
+ podpost: str
+
+ @classmethod
+ def of_podpost(cls, postid: str):
+ archive_entry = ArchiveEntry()
+ archive_entry.podpost = postid
+ archive_entry.insert_date = time.time()
+ return archive_entry
+
+
class Archive:
"""
The podcast Archive. It has a list of podposts
"""
+ _archive_entries: list[ArchiveEntry]
def __init__(self):
"""
Initialization
"""
- self.podposts = [] # Id list of posposts
+ self._archive_entries = [] # Id list of posposts
def save(self):
"""
@@ -38,28 +52,27 @@ class Archive:
Insert an podost
"""
- if podpost not in self.podposts:
- self.podposts.insert(0, podpost)
- post = Factory().get_podpost(podpost)
- if post.insert_date == None:
- post.insert_date = time.time()
- post.save()
+ if podpost not in [e.podpost for e in self._archive_entries]:
+ self._archive_entries.insert(0, ArchiveEntry.of_podpost(podpost))
self.save()
- def get_podposts(self):
+ def get_podposts(self, sorted_by_date=False):
"""
get the list of podposts
"""
-
- for podpost in self.podposts:
- yield podpost
+ if not sorted_by_date:
+ for archive_entry in self._archive_entries:
+ yield archive_entry.podpost
+ else:
+ for archive_entry in sorted(self._archive_entries, key=lambda e: e.insert_date, reverse=True):
+ yield archive_entry.podpost
def remove_podpost(self, podpost):
"""
Remove a podpost from archive
"""
- self.podposts.remove(podpost)
+ self._archive_entries = [entry for entry in self._archive_entries if entry.podpost != podpost]
class ArchiveFactory(metaclass=Singleton):
diff --git a/python/podcast/data_migration.py b/python/podcast/data_migration.py
index a7bcdbc..7fd6ccc 100644
--- a/python/podcast/data_migration.py
+++ b/python/podcast/data_migration.py
@@ -1,5 +1,7 @@
import logging
import os
+from typing import List
+
import pyotherside
from podcast.factory import Factory
@@ -41,10 +43,10 @@ def run_migrations():
migrate_podpost_v0_v1(Factory().get_podpost(entry_id))
i += 1
pyotherside.send("migrationProgress", i)
+ migrate_archive_v0_v1()
set_versionnumber(1)
pyotherside.send("migrationDone")
-
def get_versionnumber() -> int:
versionfilepath = get_versionfile_path()
if os.path.isfile(versionfilepath):
@@ -64,6 +66,30 @@ def get_versionfile_path():
return os.path.join(Factory().data_home, "dataversion")
+def migrate_archive_v0_v1():
+ """
+ migrates the id list to ArchiveEntry
+ """
+ from podcast.archive import ArchiveFactory, ArchiveEntry, Archive
+ import datetime
+ archive: Archive = ArchiveFactory().get_archive()
+ if hasattr(archive, "podposts") and len(archive.podposts) > 0 and type(archive.podposts) is not ArchiveEntry:
+ old_archive: List[str] = archive.podposts
+ archive.__archive_entries = []
+ for postid in old_archive:
+ archive_entry = ArchiveEntry()
+ post = Factory().get_podpost(postid)
+ if not post:
+ continue
+ if hasattr(post, "insert_date") and post.insert_date:
+ archive_entry.insert_date = post.insert_date
+ else:
+ archive_entry.insert_date = datetime.datetime.now()
+ archive_entry.podpost = postid
+ archive.__archive_entries.append(post)
+ del archive.podposts
+
+
def migrate_podpost_v0_v1(self: Podpost):
if hasattr(self, "entry"):
if not hasattr(self, "isaudio"):
diff --git a/qml/components/ArchiveHandler.py b/qml/components/ArchiveHandler.py
index f488394..4a48d88 100644
--- a/qml/components/ArchiveHandler.py
+++ b/qml/components/ArchiveHandler.py
@@ -19,8 +19,8 @@ def get_archive_posts(podurl=None):
entries = []
archive = ArchiveFactory().get_archive()
- for post in archive.get_podposts():
- entry = Factory().get_podpost(post)
+ for archive_entry in archive.get_podposts(sorted_by_date=True):
+ entry = Factory().get_podpost(archive_entry.podpost)
if podurl:
if entry.podurl == podurl:
entries.append(entry.get_data())
@@ -30,7 +30,6 @@ def get_archive_posts(podurl=None):
else:
pyotherside.send("ArchiveHandler: We have a none object")
- entries.sort(key=lambda r: r["adate"], reverse=True)
pyotherside.send("createArchiveList", entries)
diff --git a/test/test_archive.py b/test/test_archive.py
index e3d187d..a951a22 100644
--- a/test/test_archive.py
+++ b/test/test_archive.py
@@ -4,7 +4,6 @@ test the archive
import sys
-import httpretty
from httpretty import HTTPretty, httprettified
from test.test_podcast import read_testdata, xml_headers
@@ -15,7 +14,6 @@ from podcast.archive import ArchiveFactory, Archive
from podcast.factory import Factory
from podcast.podcast import Podcast
from podcast.podpost import Podpost
-import podcast
def test_create_archive():
"""
@@ -43,18 +41,19 @@ def test_insert():
HTTPretty.register_uri(HTTPretty.GET, 'https://freakshow.fm/feed/opus/',
body=read_testdata('testdata/freakshow.rss'), adding_headers=xml_headers)
- a = ArchiveFactory().get_archive()
- p = Podcast('https://freakshow.fm/feed/opus/')
- e = p.get_entry(p.entry_ids_old_to_new[0])
- e.save()
- a.insert(e.id)
+ archive = ArchiveFactory().get_archive()
+ podcast = Podcast('https://freakshow.fm/feed/opus/')
+ entry1 = podcast.get_entry(podcast.entry_ids_old_to_new[0])
+ entry1.save()
+ archive.insert(entry1.id)
- e2 = p.get_entry(p.entry_ids_old_to_new[1])
- e2.save()
- a.insert(e2.id)
+ entry2 = podcast.get_entry(podcast.entry_ids_old_to_new[1])
+ entry2.save()
+ archive.insert(entry2.id)
- assert e.id in a.podposts
- assert e2.id in a.podposts
+ result_posts = list(archive.get_podposts(sorted_by_date=True))
+ assert entry1.id == result_posts[1] # older
+ assert entry2.id == result_posts[0] # newer
def test_get_archives():
"""
diff --git a/test/test_migration_to_v1.py b/test/test_migration_to_v1.py
index 4f9e587..c694f0c 100644
--- a/test/test_migration_to_v1.py
+++ b/test/test_migration_to_v1.py
@@ -14,6 +14,7 @@ from podcast.queue import QueueFactory
sys.path.append("../python")
+
def test_migration():
with tempfile.TemporaryDirectory() as tmpdir:
copy_tree(os.path.join(os.path.dirname(__file__), "testdata/migrationtests_v1/"), tmpdir)
@@ -23,7 +24,7 @@ def test_migration():
assert os.path.exists(os.path.join(tmpdir, "dataversion"))
podcasts = list(PodcastListFactory().get_podcast_list().get_podcasts())
assert len(podcasts) == 1
- podcast:Podcast = PodcastFactory().get_podcast(podcasts[0])
+ podcast: Podcast = PodcastFactory().get_podcast(podcasts[0])
assert podcast != None
assert len(podcast.entry_ids_old_to_new) == 22
assert len(list(podcast.get_entries())) == 22
diff --git a/test/test_podpost.py b/test/test_podpost.py
index 2d40f3c..b138568 100644
--- a/test/test_podpost.py
+++ b/test/test_podpost.py
@@ -3,17 +3,25 @@ Podpost tests
"""
import sys
+
+import httpretty
+from httpretty import HTTPretty
+
+from test.test_podcast import read_testdata, xml_headers
+
sys.path.append("../python")
from podcast.factory import Factory
from podcast.podcast import Podcast
from podcast.podpost import Podpost
+@httpretty.activate
def test_podpost_save():
"""
Test podpost saving
"""
-
+ HTTPretty.register_uri(HTTPretty.GET, 'https://freakshow.fm/feed/opus/',
+ body=read_testdata('testdata/freakshow.rss'), adding_headers=xml_headers)
f1 = Factory()
p = Podcast('https://freakshow.fm/feed/opus/')
diff --git a/test/test_queue.py b/test/test_queue.py
index 7634336..0927ba5 100644
--- a/test/test_queue.py
+++ b/test/test_queue.py
@@ -4,6 +4,11 @@ test the queue
import sys
+import httpretty
+from httpretty import HTTPretty
+
+from test.test_podcast import read_testdata, xml_headers
+
sys.path.append("../python")
from podcast.queue import QueueFactory
@@ -34,11 +39,12 @@ def test_queue_save():
q = QueueFactory().get_queue()
q.save()
-
+@httpretty.activate
def test_insert_top():
"""
"""
-
+ HTTPretty.register_uri(HTTPretty.GET, 'https://freakshow.fm/feed/opus/',
+ body=read_testdata('testdata/freakshow.rss'), adding_headers=xml_headers)
q = QueueFactory().get_queue()
l1 = len(q.podposts)
p = Podcast('https://freakshow.fm/feed/opus/')
diff --git a/test/testdata/freakshow.rss b/test/testdata/freakshow.rss
index c81a8fc..e2b9ac7 100644
--- a/test/testdata/freakshow.rss
+++ b/test/testdata/freakshow.rss
@@ -56,5397 +56,7 @@
no
no
- -
-
FS255 Bitcoin Recycling
- https://freakshow.fm/fs255-bitcoin-recycling
- Thu, 24 Dec 2020 18:02:10 +0000
- podlove-2020-12-24t16:44:11+00:00-2df73540be4775e
-
-
-
- 03:56:56
- Metaebene Personal Media - Tim Pritlove
- Podcast Clients — 2020 Technik-Rückblick — LiDAR — iPhone 12 — M1 — OpenZFS — NAS — Mac Apps — Bildschirme
- 255
- full
- Das Jahr geht (endlich) zu Ende und wir füllen die Bits eines Bytes bis auf letzte Stelle. Ausgabe Nummer Zweihundertfünfundfünzig versucht Euch zu Weihnachten noch mal das Herz zu fluten.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Podcast Clients — 2020 Technik-Rückblick — LiDAR — iPhone 12 — M1 — OpenZFS — NAS — Mac Apps — Bildschirme
-
-Das Jahr geht (endlich) zu Ende und wir füllen die Bits eines Bytes bis auf letzte Stelle. Ausgabe Nummer Zweihundertfünfundfünzig versucht Euch zu Weihnachten noch mal das Herz zu fluten.
-
-Dauer: 3:56:56
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Denis Ahrens
-
-
- roddi
-
-
- -
-
FS254 Chat Roulette Business Edition
- https://freakshow.fm/fs254-chat-roulette-business-edition
- Thu, 10 Dec 2020 02:43:45 +0000
- podlove-2020-12-10t01:23:08+00:00-036a06860a74b9b
-
-
-
- 03:30:42
- Metaebene Personal Media - Tim Pritlove
- Talking Heads — Konten und Banken — M1 und Wintel — Internet Tips — pretix — venueless — pretalx — Virtuelle Events — Videotechnik — Mikrofone und Headsets — Licht — Ethernet
- 254
- full
- Heute dreht sich alles um Events. Wir begrüßen rami als Gast in der Sendung, der das Projekt pretix losgetreten hat, dass ein Ticketing-System für Veranstaltungen aller Art ist. Wir sprechen über Online-Events und in was von der Pandemie-Zeit übrig bleiben wird, wenn wir uns wieder in der Realität treffen können. Dazu gibt es noch eine Reihe von Tips für Technik zur Durchführung von Audio- und Videosessions.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Talking Heads — Konten und Banken — M1 und Wintel — Internet Tips — pretix — venueless — pretalx — Virtuelle Events — Videotechnik — Mikrofone und Headsets — Licht — Ethernet
-
-Heute dreht sich alles um Events. Wir begrüßen rami als Gast in der Sendung, der das Projekt pretix losgetreten hat, dass ein Ticketing-System für Veranstaltungen aller Art ist. Wir sprechen über Online-Events und in was von der Pandemie-Zeit übrig bleiben wird, wenn wir uns wieder in der Realität treffen können. Dazu gibt es noch eine Reihe von Tips für Technik zur Durchführung von Audio- und Videosessions.
-
-Dauer: 3:30:42
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-Liebe Dauerspender, ich habe eine Bitte | Metaebene Personal Media
- — Metaebene Personal Media
-
-
-Konto bei Kontist anlegen, 50 EUR spenden, 50 EUR bekommen
- — app.kontist.com
-
-
-Apple preps next Mac chips with aim to outclass highest-end PCs - BNN Bloomberg
- — BNN
-
-
-Just Have a Think
- — YouTube
-
-
-Ishkur's Guide to Electronic Music
- — music.ishkur.com
-
-
-Radiooooo
- — Radiooooo - The Musical Time Machine
-
-
-pretix
- — GitHub
-
-
-Host your events online with venueless
- — venueless
-
-
-pretix – Ticket-Shop für Konferenzen, Festivals, Messen, ...
- — pretix.eu
-
-
-pretalx.com – CfP and scheduling for conferences
- — pretalx.com
-
-
-Blog – pretix – Ticket-Shop für Konferenzen, Festivals, Messen, ...
- — pretix.eu
-
-
-BigBlueButton - Open Source Web Conferencing
- — bigbluebutton.org
-
-
-Second Life
- — de.wikipedia.org
-
-
-Video Meetings, Video Conferencing and Screen Sharing
- — whereby.com
-
-
-Blackmagic Design UltraStudio Recorder 3G
- — Musikhaus Thomann
- (*)
-
-
-Wonder – Online events that are fun
- — wonder.me
-
-
-Maps - rC3 howto
- — howto.rc3.world
-
-
-Blackmagic Design ATEM Television Studio Pro 4K
- — Musikhaus Thomann
- (*)
-
-
-doozzoo - live coaching platform for music education
- — doozzoo.com
-
-
-NDI + WiFi | Camera for OBS Studio
- — obs.camera
-
-
-v19 / Page / Product / Epoc | elgato.com
- — elgato.com
-
-
-Blackmagic Design ATEM Mini
- — Musikhaus Thomann
- (*)
-
-
-Tom Buck
- — YouTube
-
-
-Cam Link | elgato.com
- — elgato.com
-
-
-Shure MV 7 Black
- — Musikhaus Thomann
- (*)
-
-
-Starship | SN8 | High-Altitude Flight Test
- — youtube.com
-
-
-🎤 Shure SM 7 B
- — Musikhaus Thomann
- (*)
-
-
-Starship | SN8 | High-Altitude Flight Test
- — YouTube
-
-
-Manfrotto 244N Magic Arm
- — Musikhaus Thomann
- (*)
-
-
-Manfrotto 143N Magic Arm
- — Musikhaus Thomann
- (*)
-
-
-Manfrotto 035 Super Clamp
- — Musikhaus Thomann
- (*)
-
-
-Rode PSA-1
- — Musikhaus Thomann
- (*)
-
-
-Neewer Fortgeschrittene 660 LED Videoleuchte Dimmbares: Amazon.de: Kamera
- — amazon.de
-
-
-Yamaha AG03
- — Musikhaus Thomann
- (*)
-
-
-SSL 2
- — Musikhaus Thomann
- (*)
-
-
-Netgear GS105GE, Switch blau, Retail
- — alternate.de
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Letty
-
-
- hukl
-
-
- rami
-
-
- -
-
FS253 Zero Latency Computing
- https://freakshow.fm/fs253-zero-latency-computing
- Thu, 26 Nov 2020 23:00:32 +0000
- podlove-2020-11-26t22:43:23+00:00-130a4cec453a37f
-
-
-
- 03:41:53
- Metaebene Personal Media - Tim Pritlove
- Ultraschall — M1 Macs — Big Sur
- 253
- full
- Nach zwei Wochen und vor allem nachdem manche von uns bereits ein paar der neuen M1 Macs erhalten habe dreht sich hier ein weiteres Mal alles um die neuen Computer. Wir teilen erste Erfahrungen und Einschätzungen und sind überhaupt sehr aufgeregt. Außerdem ist Ralf zu Gast und berichtet von den Fortschritten beim Ultraschall-Projekt.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Ultraschall — M1 Macs — Big Sur
-
-Nach zwei Wochen und vor allem nachdem manche von uns bereits ein paar der neuen M1 Macs erhalten habe dreht sich hier ein weiteres Mal alles um die neuen Computer. Wir teilen erste Erfahrungen und Einschätzungen und sind überhaupt sehr aufgeregt. Außerdem ist Ralf zu Gast und berichtet von den Fortschritten beim Ultraschall-Projekt.
-
-Dauer: 3:41:53
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-Tonaderspeisung
- — de.wikipedia.org
-
-
-Logitech G432 Gaming-Headset mit 7.1 Surround Sound
- — logitechg.com
-
-
-PC38X - The Gaming Advantage?
- — YouTube
-
-
-Übersicht: alles rund um das Superlux HMC660 X Headset
- — Sendegate
-
-
-MV7 - Podcast-Mikrofon
- — shure.com
-
-
-PC38X - The Gaming Advantage?
- — youtu.be
-
-
-HedgeDoc - Collaborative markdown editor
- — HedgeDoc
-
-
-HedgeDoc - Collaborative markdown notes
- — HedgeDoc - Collaborative markdown notes
-
-
-Flowchart Maker & Online Diagram Software
- — Draw.io
-
-
-Roam Research – A note taking tool for networked thought.
- — Roam Research
-
-
-Affinity 1.8.6 for macOS is here!
- — Affinity
-
-
-Drafts, Where Text Starts
- — getdrafts.com
-
-
-HedgeDoc - Collaborative markdown notes
- — HedgeDoc - Collaborative markdown notes
-
-
-Podlovers
- — podlovers.org
-
-
-Notion – The all-in-one workspace for your notes, tasks, wikis, and databases.
- — Notion
-
-
-Podlove Community
- — community.podlove.org
-
-
-8GB vs 16GB M1 MacBook Pro - How much RAM do you NEED?!
- — YouTube
-
-
-Apple Mac Pro - Audio & Music Pro Buyer's Guide #1
- — YouTube
-
-
-Intel’s Disruption is Now Complete
- — Medium
-
-
-Apple Silicon M1: Black. Magic. Fuckery.
- — singhkays.com
-
-
-Apple Announces The Apple Silicon M1: Ditching x86 - What to Expect, Based on A14
- — AnandTech
-
-
-Craig Federighi says touchscreen Macs not the goal of Big Sur’s design
- — Six Colors
-
-
-Acorn Archimedes
- — de.m.wikipedia.org
-
-
-Upgrade #326: The M1 Macs: Interview and Review - Relay FM
- — Relay FM
-
-
-Epic: Support Apple Silicon · Issue #43313 · dotnet/runtime
- — GitHub
-
-
-Run Six Displays on M1 Macs Apple Silicon (Mac Mini, Macbook Air, Macbook Pro) #WorkFromHome #ARM
- — YouTube
-
-
-macOS 11 Big Sur compatibility on Apple Silicon · Issue #7857 · Homebrew/brew
- — GitHub
-
-
-Is Apple Silicon ready ?
- — Is Apple silicon ready ?
-
-
-High-Performance Workflow Solutions
- — OWC Digital
-
-
-Airfoil for Mac: Installing ACE on M chip-based Macs
- — rogueamoeba.com
-
-
-Safely open apps on your Mac
- — Apple Support
-
-
-macOS Big Sur launch appears to cause temporary slowdown in even non-Big Sur Macs
- — Ars Technica
-
-
-ktemkin/homebrew-tirepatch
- — GitHub
-
-
-Apple Silicon M1 Chips and Docker - Docker Blog
- — Docker Blog
-
-
-What happened during the troubled Big Sur launch, and why Apple can't let it happen again | AppleInsider
- — AppleInsider
-
-
-Apple M1 Tidbits: Running iOS Apps With .IPAs, Running x86 Homebrew Apps, Accessing macOS Recovery and More
- — MacRumors
-
-
-Developer ID certificate revocation
- — lapcatsoftware.com
-
-
-Apple Developer ID OCSP
- — lapcatsoftware.com
-
-
-Does Apple really log every app you run? A technical look – Jacopo Jannone - blog
- — blog.jacopo.io
-
-
-MacOS Big Sur Launch Overwhelmed Apple’s CDN, Which in Turn Triggered a Bug in ‘trustd’ That Ground App Launching to a Halt
- — Daring Fireball
-
-
-Big no on Big Sur: Mullvad disallows Apple apps to bypass firewall - Blog | Mullvad VPN
- — Mullvad VPN
-
-
-Help Center - Little Snitch
- — Objective Development
-
-
-US-Uni entwickelt Super-Cluster aus G5-Power-Macs
- — heise.de
-
-
-A hole in the wall
- — Objective Development's Blog
-
-
-PC guy is BACK! Watch him troll Apple's MacBook event ('I'm a Mac' - 'I'm a PC')
- — YouTube
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Dominik Wagner
-
-
- Denis Ahrens
-
-
- Ralf Stockmann
-
-
- -
-
FS252 Keine grobe Feinheit
- https://freakshow.fm/fs252-keine-grobe-feinheit
- Thu, 12 Nov 2020 20:36:35 +0000
- podlove-2020-11-12t13:43:01+00:00-6312fbdf2ec0387
-
-
-
- 03:50:53
- Metaebene Personal Media - Tim Pritlove
- Kontowechsel — Pausenende — Elektrourlaub — Tesla Battery Day — iPhone 12 — Apple Watch — iOS 14 und AirPods Pro — Augmented Reality — Big Sur — ARM-Macs — 5G — Audio auf dem Mac — Audiointerfaces — Küchenkram
- 252
- full
- We are back. Nach einer längeren, im Kern ungeplanten aber trotzdem notwenidgen Verschnaufpause ist die Freak Show wieder am Start, denn wir mussten dringend mal wieder mehr über Macs reden. Wir gehen die neue Produkten von Apple der letzten Woche durch und natürlich legen wir einen Schwerpunkt auf die neuen ARM-Macs, die nun endlich vorgestellt worden. Dazu ein wenig Corona-Küchenkram rund um Waffeleisen und scharfe Messer.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Kontowechsel — Pausenende — Elektrourlaub — Tesla Battery Day — iPhone 12 — Apple Watch — iOS 14 und AirPods Pro — Augmented Reality — Big Sur — ARM-Macs — 5G — Audio auf dem Mac — Audiointerfaces — Küchenkram
-
-We are back. Nach einer längeren, im Kern ungeplanten aber trotzdem notwenidgen Verschnaufpause ist die Freak Show wieder am Start, denn wir mussten dringend mal wieder mehr über Macs reden. Wir gehen die neue Produkten von Apple der letzten Woche durch und natürlich legen wir einen Schwerpunkt auf die neuen ARM-Macs, die nun endlich vorgestellt worden. Dazu ein wenig Corona-Küchenkram rund um Waffeleisen und scharfe Messer.
-
-Dauer: 3:50:53
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-Liebe Dauerspender, ich habe eine Bitte | Metaebene Personal Media
- — Metaebene Personal Media
-
-
-Spenden für die Metaebene | Metaebene Personal Media
- — Metaebene Personal Media
-
-
-etzmax - Commercial On-Demand-Espresso-Grinder: Grinders (EN)
- — etzinger-ag.com
-
-
-Beyerdynamic DT-297-PV/80 MKII
- — Musikhaus Thomann
- (*)
-
-
-Apple Silicon: MacBook Air schneller als 16" MacBook Pro? | Mac Life
- — Mac Life
-
-
-20 Macs for 2020 - Relay FM
- — Relay FM
-
-
-Behringer | Product | FLOW 8
- — behringer.com
-
-
-Thomann feat. Tim Pritlove
- — thomann.de
- (*)
-
-
-20 Macs for 2020 – Six Colors
- — Six Colors
-
-
-SubEthaEdit
- — Mac App Store
-
-
-Raspberry Pi 400, DE Tastatur Layout
- — Pi-Shop.ch
-
-
-Amazon.de: Baratza | Sette 270 | Elektrische Kaffee Kegelmühlen Professional | Grau / Schwarz
- — amazon.de
-
-
-SSL 2
- — Musikhaus Thomann
- (*)
-
-
-Beyerdynamic DT-797 PV
- — Musikhaus Thomann
- (*)
-
-
-Knives Out – Mord ist Familiensache – Wikipedia
- — de.wikipedia.org
-
-
-Wüsthof Kochmesser, Classic (4582-7/18), 18 cm Klingenlänge, geschmiedet, rostfreier Edelstahl, breites und sehr scharfes Küchenmesser: Amazon.de: Küche & Haushalt
- — amazon.de
-
-
-Universal Audio Apollo Twin USB Duo
- — Musikhaus Thomann
- (*)
-
-
-Roland Rubix24
- — Musikhaus Thomann
- (*)
-
-
-Yamaha AG03
- — Musikhaus Thomann
- (*)
-
-
-Penninger Blutwurz
- — penninger.de
-
-
-SIMPLE-Sharp, 53,61 €
- — schmiedeglut.de
-
-
-Lendromat
- — lendrom.at
-
-
-Mediashop Bavarian Edge Messerschärfer
- — amazon.de
-
-
-Amazon.de: Graef Diamant-Messerschärfer CC 120 DE, weiß-schwarz
- — amazon.de
-
-
-HORL | Rollschleifer | Die zweite Generation Schärfe
- — horl.com
-
-
-M. Power Tools DC Schärfblock, extrafein/grob | Schärfsteine / Schleifsteine | Dictum
- — Dictum
-
-
-Ken Onion Edition Knife & Tool Sharpener - Work Sharp Sharpeners
- — Work Sharp Sharpeners
-
-
-ZWILLING Schubladeneinsatz, bis zu 8 Messer, Buche | Offizieller ZWILLING Shop
- — zwilling.com
-
-
-SHAN ZU Schleifstein Abziehstein Wetzstein für Professionell 2-in-1 Doppelseitiger Messerschärfer
- — amazon.de
-
-
-8" Dia-Sharp DMT Diamant Schleifstein Set
- — schmiedeglut.de
-
-
-Für die Werkstatt - SCHMIEDEGLUT Messer nach Wunsch: Damastmesser,
- — schmiedeglut.de
-
-
-Mactracker App Info and Alternatives @ Mactracker.com
- — mactracker.app
-
-
-Messer Schärfen lernen in 10 Minuten im Schärfkurs Online
- — YouTube
-
-
-SCHMIEDEGLUT: Messer, Damastmesser, Jagdmesser, Damast Kochmesser
- — schmiedeglut.de
-
-
-cloer 1898 Waffeleisen Herzwaffel 16, 5 cm Ø, doppelte Antihaftbeschichtung, für gewerblichen Betrieb geeignet
- — amazon.de
-
-
-Amazon.de: Waffeleisen Wanda 1600 W, Doppelwaffeleisen für Belgische Waffeln, Praktische Überlaufrille, Display zur Anzeige der Backfarbe
- — amazon.de
-
-
-kiwami japan
- — YouTube
-
-
-Schmiedeglut - Handmade Knives Germany
- — YouTube
-
-
-Amazon.de: Krups FDD95D Professionelles Waffeleisen
- — amazon.de
-
-
-ExistentialAudio/BlackHole
- — GitHub
-
-
-Ultimate Hacking Keyboard – The keyboard. For professionals.
- — Ultimate Hacking Keyboard
-
-
-Everest Max im Test: Mehr kann man von einer Tastatur nicht wollen - Golem.de
- — Golem.de
-
-
-1Password | Yubico
- — Yubico
-
-
-SoundSource - A Superior Sound Control
- — rogueamoeba.com
-
-
-Loopback - Cable-free audio routing for Mac
- — rogueamoeba.com
-
-
-Apple schnappt sich Intels Modemgeschäft
- — Mac & i
-
-
-MacBook Air - Technical Specifications
- — Apple
-
-
-Apple stellt den M1 vor
- — Apple Newsroom
-
-
-Apple M1 Power Chart
- — applemust.com
-
-
-Apple Announces The Apple Silicon M1: Ditching x86 - What to Expect, Based on A14
- — AnandTech
-
-
-ICARER MacBook Pro 13 Hülle Lederhülle, Ultra Slim: Amazon.de: Computer & Zubehör
- — amazon.de
-
-
-Spinal Tap - "These go to eleven...."
- — YouTube
-
-
-Augmented Reality - The Future of Education ( Ara Pacis ) - HD version
- — YouTube
-
-
-Sheets - Windows and Views - macOS - Human Interface Guidelines - Apple Developer
- — developer.apple.com
-
-
-200 Puls - Mediamarkt - Sachse - Videorekorder
- — YouTube
-
-
-Exclusive: Intel's new smart glasses hands-on
- — YouTube
-
-
-Microsoft HoloLens | Mixed Reality-Technologie für Unternehmen
- — microsoft.com
-
-
-MacBook Pro 13" (2016-2019) Hard Case Hülle Dual Schutzabdeckung - Schwarz (Transparent/Matt)
- — apfelkiste.ch
-
-
-iHealth AIR PO3M Vernetztes Pulsoximeter: Amazon.de: Drogerie & Körperpflege
- — amazon.de
-
-
-Fission - Fast & lossless audio editing for Mac
- — rogueamoeba.com
-
-
-ZWILLING Messeraufbewahrung, Buche | Offizieller ZWILLING Shop
- — zwilling.com
-
-
-Surprise! Fujitsu Releases 64-Bit ScanSnap Manager for Older Scanners - TidBITS
- — TidBITS
-
-
-Models for ScanSnap Manager V7 Download
- — scansnap.fujitsu.com
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- hukl
-
-
- Denis Ahrens
-
-
- roddi
-
-
- Dominik Wagner
-
-
- -
-
FS251 Bürgermeisterladesäulen
- https://freakshow.fm/fs251-buergermeisterladesaeulen
- Sat, 18 Jul 2020 09:49:43 +0000
- podlove-2020-07-18t09:29:01+00:00-e6a090d7c680aed
-
-
-
- 03:19:11
- Metaebene Personal Media - Tim Pritlove
- Eine Spezialausgabe der Freak Show mit dem Schwerpunkt Elektromobilität
- 251
- full
- Wir haben schon oft darüber gesprochen, aber so richtig Ahnung haben wir ja eh nicht. Deswegen haben wir (Roddi, Denis, Tim) uns den Philipp vom cleaneletric Podcast eingeladen um mal ganz ausführlich über den Stand der Dinge in Sachen Elektromobilität in Deutschland und dem Rest der Welt zu sprechen. Dabei versuchen wir zu ergründen, woran es noch hapert und wo vielleicht der Umstieg für viele schon näher liegt, als diese selbst noch glauben.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Eine Spezialausgabe der Freak Show mit dem Schwerpunkt Elektromobilität
-
-Wir haben schon oft darüber gesprochen, aber so richtig Ahnung haben wir ja eh nicht. Deswegen haben wir (Roddi, Denis, Tim) uns den Philipp vom cleaneletric Podcast eingeladen um mal ganz ausführlich über den Stand der Dinge in Sachen Elektromobilität in Deutschland und dem Rest der Welt zu sprechen. Dabei versuchen wir zu ergründen, woran es noch hapert und wo vielleicht der Umstieg für viele schon näher liegt, als diese selbst noch glauben.
-
-Dauer: 3:19:11
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Denis Ahrens
-
-
- roddi
-
-
- Philipp Hellwig
-
-
- -
-
FS250 Die Ente bleibt draußen
- https://freakshow.fm/fs250-die-ente-bleibt-draussen
- Thu, 02 Jul 2020 22:46:38 +0000
- podlove-2020-07-02t21:40:53+00:00-6b9d9aaa486e6bf
-
-
-
- 03:37:40
- Metaebene Personal Media - Tim Pritlove
- Die 250. Sendung der Freak Show über die WWDC 2020 und andere Dinge
- 250
- full
- Nun sind schon über 12 Jahre vergangen seitdem die Freak Show (damals noch unter anderem Namen) ans Netz gegangen ist. Wir bedanken uns für die jahrelange Treue unserer Hörerinnen und Hörer, die mit ihrem Feedback immer dazu beigetragen haben, dass uns die Lust am Projekt nie vergangen ist.
-
-Heute sind wir dann auch standesgemäß vollzählig angetreten und dazu haben wir uns auch noch den Dominik dazugehört, um die Akustik für Euch komplett unübersichtlich zu gestalten.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Die 250. Sendung der Freak Show über die WWDC 2020 und andere Dinge
-
-Nun sind schon über 12 Jahre vergangen seitdem die Freak Show (damals noch unter anderem Namen) ans Netz gegangen ist. Wir bedanken uns für die jahrelange Treue unserer Hörerinnen und Hörer, die mit ihrem Feedback immer dazu beigetragen haben, dass uns die Lust am Projekt nie vergangen ist.
-
-Heute sind wir dann auch standesgemäß vollzählig angetreten und dazu haben wir uns auch noch den Dominik dazugehört, um die Akustik für Euch komplett unübersichtlich zu gestalten.
-
-Dauer: 3:37:40
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Dominik Wagner
-
-
- hukl
-
-
- Clemens Schrimpe
-
-
- Letty
-
-
- Tala
-
-
- roddi
-
-
- Denis Ahrens
-
-
- -
-
FS249 Hemmungsloser Hinterhoftoilettensex
- https://freakshow.fm/fs249-hemmungsloser-hinterhoftoilettensex
- Mon, 27 Apr 2020 10:05:37 +0000
- podlove-2020-04-27t09:29:08+00:00-0afb684ad7267f3
-
-
-
- 04:05:36
- Metaebene Personal Media - Tim Pritlove
- Die Corona-Situation — Masken und Zauberwürfel — Gesundheitstechnologie — Differential Privacy — macOS auf ARM — Programmiersprachen
- 249
- full
- Heute begrüßen wir in unserer Runde den Menschen, der jetzt schon seit Jahren auf die eine oder andere Art und Weise zu hören war, nur noch nicht selbst: Rainer, der seinerzeit die Produktion der Previouslys von David übernommen hatte nimmt Platz in unserer Runde. Inhaltlich dreht sich natürlich viel um Das Unvermeidliche Thema ™, aber wir versuchen noch das eine oder andere sinnvolle zur Debatte hinzuzufügen. Und wir mussten mal wieder über Macs reden. Viel Spaß dabei.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Die Corona-Situation — Masken und Zauberwürfel — Gesundheitstechnologie — Differential Privacy — macOS auf ARM — Programmiersprachen
-
-Heute begrüßen wir in unserer Runde den Menschen, der jetzt schon seit Jahren auf die eine oder andere Art und Weise zu hören war, nur noch nicht selbst: Rainer, der seinerzeit die Produktion der Previouslys von David übernommen hatte nimmt Platz in unserer Runde. Inhaltlich dreht sich natürlich viel um Das Unvermeidliche Thema ™, aber wir versuchen noch das eine oder andere sinnvolle zur Debatte hinzuzufügen. Und wir mussten mal wieder über Macs reden. Viel Spaß dabei.
-
-Dauer: 4:05:36
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Letty
-
-
- Denis Ahrens
-
-
- Clemens Schrimpe
-
-
- Rainer
-
-
- -
-
FS248 Public Static Final
- https://freakshow.fm/fs248-public-static-final
- Tue, 31 Mar 2020 07:57:09 +0000
- podlove-2020-03-30t23:22:33+00:00-0d806fba61c9b50
-
-
-
- 03:23:01
- Metaebene Personal Media - Tim Pritlove
- Die erste Freak Show, die komplett remote stattfindet
- 248
- full
- Nun ist es es also soweit: der Coronavirus zwingt auch die Freak Show in den Zwangsabstand und so wird das erste mal nicht live und lebendig in der Metaebene aufgenommen, sondern wir finden uns alle digital zusammen. Klappt trotzdem irgendwie und wir bieten seit langem mal wieder ein volles Team. Die Themen liegen natürlich auf der Hand, aber wir reden auch mal wieder über Macs. Viel Spaß.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Die erste Freak Show, die komplett remote stattfindet
-
-Nun ist es es also soweit: der Coronavirus zwingt auch die Freak Show in den Zwangsabstand und so wird das erste mal nicht live und lebendig in der Metaebene aufgenommen, sondern wir finden uns alle digital zusammen. Klappt trotzdem irgendwie und wir bieten seit langem mal wieder ein volles Team. Die Themen liegen natürlich auf der Hand, aber wir reden auch mal wieder über Macs. Viel Spaß.
-
-Dauer: 3:23:01
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Letty
-
-
- hukl
-
-
- Tala
-
-
- roddi
-
-
- Clemens Schrimpe
-
-
- -
-
FS247 Pulp-Fiction-Koffermoment
- https://freakshow.fm/fs247-pulp-fiction-koffermoment
- Thu, 27 Feb 2020 21:32:03 +0000
- podlove-2020-02-27t19:11:42+00:00-44e5ad9cc461a0e
-
-
-
- 04:02:47
- Metaebene Personal Media - Tim Pritlove
- Umziehen — Podlove Web Player — Podlove Publisher — WordPress — Podlove Radiator — Küchengeräte
- 247
- full
- Heute finden wir uns mit einer ganzen Reihe an Wiedergängern aus den letzten Jahren zusammen. Wir begrüßen Dennis Morhardt, Alexander Heimbuch und Eric Teubert in unserer Runde und reden viel über Podlove und Podcasting, aber auch darüber, wie man sich richtig die Hände wäscht und ohne welchen Küchengeräte ein Leben im 21. Jahrhundert unvorstellbar ist.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Umziehen — Podlove Web Player — Podlove Publisher — WordPress — Podlove Radiator — Küchengeräte
-
-Heute finden wir uns mit einer ganzen Reihe an Wiedergängern aus den letzten Jahren zusammen. Wir begrüßen Dennis Morhardt, Alexander Heimbuch und Eric Teubert in unserer Runde und reden viel über Podlove und Podcasting, aber auch darüber, wie man sich richtig die Hände wäscht und ohne welchen Küchengeräte ein Leben im 21. Jahrhundert unvorstellbar ist.
-
-Dauer: 4:02:47
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-FSP247 - Aktionärstreffen
- — SoundCloud
-
-
-momox - Einfach gebrauchte Sachen online verkaufen
- — momox.de
-
-
-rebuy
-
-
-Ali Noorani on Twitter: Händewaschen
- — Twitter
-
-
-Home - Shelly Cloud
- — Shelly Cloud
-
-
-MQTT
- — de.wikipedia.org
-
-
-Node-RED
- — nodered.org
-
-
-Online-Zahlungsabwicklung für Internet-Unternehmen – Stripe
- — stripe.com
-
-
-Web Payments Working Group
- — w3.org
-
-
-Berliner Toilette
- — App Store
-
-
-Direkte Spenden im Web für die Metaebene via bunq.me und Apple Pay
- — bunq.me
-
-
-Spenden für die Metaebene | Metaebene Personal Media
- — Metaebene Personal Media
-
-
-GoCardless
- — gocardless.com
-
-
-Best way for artists and creators to get sustainable income and connect with fans | Patreon
- — Patreon
-
-
-Steady – People-Powered Media
- — Steady
-
-
-Patreon will now give creators cash advances on their subscription money
- — The Verge
-
-
-The world’s fastest framework for building websites
- — gohugo.io
-
-
-Enjoy Slurm!
- — betaebene.be
-
-
-Amazon Smile
- — smile.amazon.de
-
-
-fehlkauf.biz - Wir machen Business
- — fehlkauf.biz
-
-
-Unfurl · Url Metadata Extractor
- — unfurl.eric.co.de
-
-
-Microbrowsers are Everywhere
- — 24ways.org
-
-
-podcasting
- — wikidata.org
-
-
-Stream Deck | elgato.com
- — elgato.com
-
-
-Optimus (Tastatur)
- — de.wikipedia.org
-
-
-ANYCAST - Fachpodcast für Heimat, Recht, Bahn und Moral
- — ANYCAST
-
-
-GraphQL
- — de.wikipedia.org
-
-
-Startseite | BR Podcast
- — BR Podcast
-
-
-MinIO | High Performance, Kubernetes-Friendly Object Storage
- — MinIO
-
-
-BOB - BOB 2020
- — bobkonf.de
-
-
-Elixir (Programmiersprache)
- — de.wikipedia.org
-
-
-Amazon.de: SAGE STM800 the Tea Maker Teeautomat mit Absenkautomatik, 1.5 Liter, Edelstahl
- — amazon.de
-
-
-Amazon.de: Karcher 112921 Kaffeemaschine Morning Star mit Radio
- — amazon.de
-
-
-Amazon.de: Caso 1811 TeeGourmet Pro-Design Auto-Lift-Funktion Teekocher, 18/8 Edelstahl, 1.7 liters
- — amazon.de
-
-
-Old-fashioned rice cookers are extremely clever
- — YouTube
-
-
-Amazon.de: Reishunger Reiskocher (1, 2l / 500W / 220V)
- — amazon.de
-
-
-The Antique Toaster that's Better than Yours
- — YouTube
-
-
-Amazon.de: Bosch muc88b68fr Multi Apfelkocher 1200 W Metallic
- — amazon.de
-
-
-Arendo - Edelstahl Dampfgarer Reiskocher - inkl. Dampfgarfunktion
- — amazon.de
-
-
-Vakuumgaren
- — de.wikipedia.org
-
-
-Krups FDD95D Waffelautomat Professional: Amazon.de: Küche & Haushalt
- — amazon.de
-
-
-Amazon.de: Cloer 189 Waffelautomat für kuchenartige Waffeln
- — amazon.de
-
-
-Zwilling 307481810 Twin Pollux Santokumesser
- — amazon.de
-
-
-BearMoo Wetzstein, 2-IN-1 Abziehstein Schleifstein für Messer, Körnung 3000/8000 mit rutschfestem Silikonhalter
- — amazon.de
-
-
-Holzapfel Buckelsmesser Olivenholz
- — Holzapfel Berlin
-
-
-Amazon.de: Espressomaschine Rancilio Silvia
- — amazon.de
-
-
-Profitec Pro300 Espressomaschine
- — Coffee Circle
-
-
-Regler – Wikipedia
- — de.wikipedia.org
-
-
-Arc
- — felicitacoffee.com
-
-
-Puqpress M1 weiß
- — STOLL Espresso
-
-
-DE1+
- — decentespresso.com
-
-
-Bezzera BZ10 S PM Espressomaschine
- — Coffee Circle
-
-
-Eureka Mignon MCI Espressomühle
- — Coffee Circle
-
-
-jbkaffe Onlineshop f. Kaffee + Espresso
- — https://www.jbkaffee.de/
-
-
-19grams Kaffeerösterei
- — 19grams Kaffeerösterei
-
-
-MAN VERSUS MACHINE - INDEPENDENT SPECIALTY COFFEE ROASTERS
- — MAN VERSUS MACHINE COFFEE ROASTERS
-
-
-Ascaso Factory | Espresso coffee machines manufactured in Barcelona |
- — ascaso.com
-
-
-Espresso Bohnen & Kaffee bestellen » Espresso International
- — Deutsch (.de)
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- roddi
-
-
- Eric Teubert
-
-
- Dennis Morhardt
-
-
- Alexander Heimbuch
-
-
- -
-
FS246 Raumzeitfenster
- https://freakshow.fm/fs246-raumzeitfenster
- Thu, 30 Jan 2020 13:10:47 +0000
- podlove-2020-01-30t10:52:26+00:00-666de9cd437c1b9
-
-
-
- 04:02:58
- Metaebene Personal Media - Tim Pritlove
- Monty Python und Humor — Coronavirus — Living the Future — Raumzeit — Space — Tesla und die Automobilindustrie — Sozialraum Auto — Promotion — Billie Eilish
- 246
- full
- Eine kleine Runde mit Gast. Tala ist und Gregor ist mal wieder dazugestossen. Wenig überraschend gehen wir diverse Dinge stark auf der Metaebene an (im doppelten Wortsinne). Wir diskutieren Humor, Viren, Texteditoren, das Leben in der Zukunft und warum das mit der Abkehr vom Auto noch eine Weile dauern wird.
- Feedback zur Sendung?
-Schreibe uns einen Kommentar
-
-Diese Sendung soll nie aufhören?
-Unterstütze die Metaebene mit einer Spende
-
-
-
-Monty Python und Humor — Coronavirus — Living the Future — Raumzeit — Space — Tesla und die Automobilindustrie — Sozialraum Auto — Promotion — Billie Eilish
-
-Eine kleine Runde mit Gast. Tala ist und Gregor ist mal wieder dazugestossen. Wenig überraschend gehen wir diverse Dinge stark auf der Metaebene an (im doppelten Wortsinne). Wir diskutieren Humor, Viren, Texteditoren, das Leben in der Zukunft und warum das mit der Abkehr vom Auto noch eine Weile dauern wird.
-
-Dauer: 4:02:58
-
-
-
-
-
-
-
-
-
-Shownotes:
-
-
-
-
-
-
-
-
-]]>
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- 2
-
- Tim Pritlove
- http://tim.pritlove.org/
-
-
- Tala
-
-
- Gregor Sedlag
-
-
- -
+
-
FS245 Lazy Letty
https://freakshow.fm/fs245-lazy-letty
Fri, 10 Jan 2020 19:33:54 +0000
--
GitLab
From 885688a8b21d6828e2c0bc93ddd5a64a3818cc02 Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Sat, 30 Jan 2021 16:39:20 +0100
Subject: [PATCH 2/6] fixed linter errors
---
python/podcast/archive.py | 2 --
1 file changed, 2 deletions(-)
diff --git a/python/podcast/archive.py b/python/podcast/archive.py
index ba5fa93..a7346e7 100644
--- a/python/podcast/archive.py
+++ b/python/podcast/archive.py
@@ -1,10 +1,8 @@
"""
Archive of listened poposts
"""
-import datetime
import sys
import time
-from typing import List, Any
sys.path.append("../")
--
GitLab
From 2d0567c372f81becee5f68967fc9a9d51bf03fd9 Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Sat, 30 Jan 2021 16:42:14 +0100
Subject: [PATCH 3/6] fixed 3.8 interoperatibility
---
python/podcast/archive.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/python/podcast/archive.py b/python/podcast/archive.py
index a7346e7..f160ecd 100644
--- a/python/podcast/archive.py
+++ b/python/podcast/archive.py
@@ -3,6 +3,7 @@ Archive of listened poposts
"""
import sys
import time
+from typing import List
sys.path.append("../")
@@ -28,7 +29,7 @@ class Archive:
"""
The podcast Archive. It has a list of podposts
"""
- _archive_entries: list[ArchiveEntry]
+ _archive_entries: List[ArchiveEntry]
def __init__(self):
"""
--
GitLab
From cae5472dec77c69e736943d141e66e274e328708 Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Mon, 1 Feb 2021 21:10:23 +0100
Subject: [PATCH 4/6] fixed tests, small refactorings, sorting by
Podpost::insert_date again
---
pytest.ini | 5 +++++
python/podcast/archive.py | 12 ++++++++++--
python/podcast/data_migration.py | 22 ++++++++++++----------
python/podcast/podpost.py | 22 ++++++++--------------
qml/components/ArchiveHandler.py | 20 +++++---------------
test/__init__.py | 5 +++++
test/test_archive.py | 11 +++++++----
test/test_migration_to_v1.py | 3 +++
test/test_queue.py | 11 +++++++----
9 files changed, 62 insertions(+), 49 deletions(-)
create mode 100644 pytest.ini
diff --git a/pytest.ini b/pytest.ini
new file mode 100644
index 0000000..a861829
--- /dev/null
+++ b/pytest.ini
@@ -0,0 +1,5 @@
+[pytest]
+log_cli = 1
+log_cli_level = Info
+testpaths =
+ test
\ No newline at end of file
diff --git a/python/podcast/archive.py b/python/podcast/archive.py
index f160ecd..1f7f7dc 100644
--- a/python/podcast/archive.py
+++ b/python/podcast/archive.py
@@ -3,18 +3,19 @@ Archive of listened poposts
"""
import sys
import time
-from typing import List
+from typing import List, Iterator
sys.path.append("../")
from podcast.singleton import Singleton
from podcast.factory import Factory
+from podcast.podpost import Podpost
archivename = "the_archive"
class ArchiveEntry:
- insert_date: float
+ insert_date: float # unused yet
podpost: str
@classmethod
@@ -66,6 +67,13 @@ class Archive:
for archive_entry in sorted(self._archive_entries, key=lambda e: e.insert_date, reverse=True):
yield archive_entry.podpost
+ def get_podpost_objects(self, url_filter=None) -> Iterator[Podpost]:
+ for id in self.get_podposts():
+ entry: Podpost = Factory().get_podpost(id)
+ if entry:
+ if not url_filter or (url_filter and entry.podurl == url_filter):
+ yield entry
+
def remove_podpost(self, podpost):
"""
Remove a podpost from archive
diff --git a/python/podcast/data_migration.py b/python/podcast/data_migration.py
index 7fd6ccc..5cbe69d 100644
--- a/python/podcast/data_migration.py
+++ b/python/podcast/data_migration.py
@@ -1,3 +1,4 @@
+import datetime
import logging
import os
from typing import List
@@ -75,7 +76,7 @@ def migrate_archive_v0_v1():
archive: Archive = ArchiveFactory().get_archive()
if hasattr(archive, "podposts") and len(archive.podposts) > 0 and type(archive.podposts) is not ArchiveEntry:
old_archive: List[str] = archive.podposts
- archive.__archive_entries = []
+ archive._archive_entries = []
for postid in old_archive:
archive_entry = ArchiveEntry()
post = Factory().get_podpost(postid)
@@ -86,19 +87,20 @@ def migrate_archive_v0_v1():
else:
archive_entry.insert_date = datetime.datetime.now()
archive_entry.podpost = postid
- archive.__archive_entries.append(post)
+ archive._archive_entries.append(post)
del archive.podposts
def migrate_podpost_v0_v1(self: Podpost):
- if hasattr(self, "entry"):
- if not hasattr(self, "isaudio"):
- self.isaudio = False
- if not hasattr(self, "length"):
- self.length = 0
- if not self.isaudio:
- self.init(self.entry, self.logo_url, self.podurl)
- self.save()
+ if not hasattr(self, "insert_date") or self.insert_date is None:
+ self.insert_date = datetime.datetime.now().timestamp()
+ if not hasattr(self, "isaudio"):
+ self.isaudio = False
+ if not hasattr(self, "length"):
+ self.length = 0
+ if hasattr(self, "entry") and not self.isaudio:
+ self.init(self.entry, self.logo_url, self.podurl)
+ self.save()
def migrate_podcast_v0_v1(self: Podcast):
diff --git a/python/podcast/podpost.py b/python/podcast/podpost.py
index d59b89d..e263fad 100644
--- a/python/podcast/podpost.py
+++ b/python/podcast/podpost.py
@@ -1,7 +1,7 @@
"""
Podpost: a single podcast post
"""
-
+import datetime
import sys
sys.path.append("../")
@@ -41,7 +41,7 @@ class Podpost:
title: str
percentage: float
position: int
- isaudio: bool
+ isaudio: bool # if the post comes from the external folder
id: str
state: int
favorite: bool
@@ -51,13 +51,12 @@ class Podpost:
href: str
duration: Optional[int]
length: int
- published: Optional[float]
- insert_date: object
+ published: Optional[float] # when the post was published according to feed
+ insert_date: float # when we entered this post into our db
link: Optional[str]
type: str
- podurl: str
+ podurl: str # the feed url
chapters: List
- version: int
def __init__(self, entry, podurl, logo_url, data=None, isaudio=False):
"""
@@ -75,6 +74,7 @@ class Podpost:
self.length = 0
self.type = ""
self.href = ""
+ self.insert_date = datetime.datetime.now().timestamp()
if isaudio:
self.init_file_entry(data, logo_url, podurl)
@@ -93,7 +93,6 @@ class Podpost:
self.id = data["id"]
self.length = int(data["length"])
self.published = 0
- self.insert_date = None
self.link = None
self.type = data["mime"]
self.podurl = podurl
@@ -107,7 +106,6 @@ class Podpost:
if len(logo_url) > 0:
if logo_url[0] == "/":
self.logo_path = logo_url
- self.insert_date = None
try:
self.published = timegm(entry.published_parsed)
except:
@@ -262,12 +260,8 @@ class Podpost:
section = format_full_date(self.published)
date = self.published
fdate = s_to_year(date)
- if self.insert_date:
- asection = format_full_date(self.insert_date)
- adate = self.insert_date
- else:
- asection = ""
- adate = 0
+ asection = format_full_date(self.insert_date)
+ adate = self.insert_date
logger.debug("adate, asection %s, %s", adate, asection)
logger.debug("date, section %s, %s", date, section)
if self.duration:
diff --git a/qml/components/ArchiveHandler.py b/qml/components/ArchiveHandler.py
index 4a48d88..bc3edf3 100644
--- a/qml/components/ArchiveHandler.py
+++ b/qml/components/ArchiveHandler.py
@@ -9,28 +9,18 @@ sys.path.append("/usr/share/harbour-podqast/python")
from podcast.archive import ArchiveFactory
from podcast.factory import Factory
+import logging
+logger = logging.getLogger(__name__)
def get_archive_posts(podurl=None):
"""
Return a list of all archive posts
"""
- entries = []
- archive = ArchiveFactory().get_archive()
-
- for archive_entry in archive.get_podposts(sorted_by_date=True):
- entry = Factory().get_podpost(archive_entry.podpost)
- if podurl:
- if entry.podurl == podurl:
- entries.append(entry.get_data())
- else:
- if entry:
- entries.append(entry.get_data())
- else:
- pyotherside.send("ArchiveHandler: We have a none object")
-
- pyotherside.send("createArchiveList", entries)
+ posts = ArchiveFactory().get_archive().get_podpost_objects(url_filter=podurl)
+ sorted_posts = sorted(posts, key=lambda p: p.insert_date, reverse=True)
+ pyotherside.send("createArchiveList", [post.get_data() for post in sorted_posts])
def get_archive_pod_data():
diff --git a/test/__init__.py b/test/__init__.py
index 30af4ca..c174ad0 100644
--- a/test/__init__.py
+++ b/test/__init__.py
@@ -1,3 +1,5 @@
+import os
+import tempfile
import types
import sys
from unittest.mock import Mock
@@ -9,3 +11,6 @@ def mock_pyotherside():
module.send = Mock(name=module_name+'.send')
mock_pyotherside()
+
+os.environ["PODQAST_HOME"] = tempfile.gettempdir()
+print("tempdir: %s"%os.environ["PODQAST_HOME"] )
diff --git a/test/test_archive.py b/test/test_archive.py
index a951a22..a1b958e 100644
--- a/test/test_archive.py
+++ b/test/test_archive.py
@@ -5,7 +5,6 @@ test the archive
import sys
from httpretty import HTTPretty, httprettified
-
from test.test_podcast import read_testdata, xml_headers
sys.path.append("../python")
@@ -51,9 +50,13 @@ def test_insert():
entry2.save()
archive.insert(entry2.id)
- result_posts = list(archive.get_podposts(sorted_by_date=True))
- assert entry1.id == result_posts[1] # older
- assert entry2.id == result_posts[0] # newer
+ result_posts = list(archive.get_podposts())
+ assert entry1.id in result_posts
+ assert entry2.id in result_posts
+ object_ids = [a.id for a in archive.get_podpost_objects('https://freakshow.fm/feed/opus/')]
+ assert entry1.id in object_ids
+ assert entry2.id in object_ids
+ assert 0 == len(list(archive.get_podpost_objects(url_filter='https://i.am.not.corrects/speex')))
def test_get_archives():
"""
diff --git a/test/test_migration_to_v1.py b/test/test_migration_to_v1.py
index c694f0c..c8fc258 100644
--- a/test/test_migration_to_v1.py
+++ b/test/test_migration_to_v1.py
@@ -27,6 +27,9 @@ def test_migration():
podcast: Podcast = PodcastFactory().get_podcast(podcasts[0])
assert podcast != None
assert len(podcast.entry_ids_old_to_new) == 22
+ for post in (Factory().get_podpost(post) for post in podcast.entry_ids_old_to_new for podcast in
+ map(PodcastFactory().get_podcast, podcasts)):
+ assert post.insert_date is not None
assert len(list(podcast.get_entries())) == 22
del os.environ["PODQAST_HOME"]
resetSingletons()
diff --git a/test/test_queue.py b/test/test_queue.py
index 0927ba5..f2e166d 100644
--- a/test/test_queue.py
+++ b/test/test_queue.py
@@ -14,9 +14,8 @@ sys.path.append("../python")
from podcast.queue import QueueFactory
from podcast.factory import Factory
from podcast.queue import Queue
-from podcast.podcast import Podcast
+from podcast.podcast import Podcast, PodcastFactory
from podcast.podpost import Podpost
-import podcast
def test_create_queue():
@@ -70,10 +69,14 @@ def test_get_podposts():
"""
queue = QueueFactory().get_queue()
- queue.podposts = ['85140fc8e16ba62517877ef4857a85f5bbf83e6a236c659a73489f093e51f154',
- 'ce656a3888a282fe9df727e0729fa7d375704e4bd6c0d50e9c0fe7ddafa232ec']
+ podcast = PodcastFactory().get_podcast('https://freakshow.fm/feed/opus/')
+ entry = podcast.entry_ids_old_to_new[1]
+ entry2 = podcast.entry_ids_old_to_new[0]
+ queue.insert_top(entry)
+ queue.insert_top(entry2)
postids = list(queue.get_podposts())
assert len(postids) == 2
for post in postids:
assert type(post) == str
assert type(Factory().get_podpost(post)) == Podpost
+ assert post in [entry,entry2]
--
GitLab
From 6d79cdef668bd638cc913fd9608a52e660ff7c7a Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Mon, 1 Feb 2021 21:20:06 +0100
Subject: [PATCH 5/6] removed adate completly, sorting everything by
insert_date now
---
python/podcast/podpost.py | 4 ----
qml/components/FavoriteHandler.py | 4 +---
2 files changed, 1 insertion(+), 7 deletions(-)
diff --git a/python/podcast/podpost.py b/python/podcast/podpost.py
index e263fad..39beaa2 100644
--- a/python/podcast/podpost.py
+++ b/python/podcast/podpost.py
@@ -261,9 +261,6 @@ class Podpost:
date = self.published
fdate = s_to_year(date)
asection = format_full_date(self.insert_date)
- adate = self.insert_date
- logger.debug("adate, asection %s, %s", adate, asection)
- logger.debug("date, section %s, %s", date, section)
if self.duration:
duration = s_to_hr(self.duration)
else:
@@ -294,7 +291,6 @@ class Podpost:
"date": date,
"fdate": fdate,
"section": section,
- "adate": adate,
"asection": asection,
"length": self.length,
"duration": duration,
diff --git a/qml/components/FavoriteHandler.py b/qml/components/FavoriteHandler.py
index e19a9a9..9ea0aab 100644
--- a/qml/components/FavoriteHandler.py
+++ b/qml/components/FavoriteHandler.py
@@ -79,10 +79,8 @@ def get_favorites(podurl=None):
posts = get_queue_favorites(podurl)
posts = append_archive_favorites(posts, podurl=podurl)
postsdata = []
- for post in posts:
+ for post in sorted(posts, key=lambda p: p.insert_date, reverse=True):
postsdata.append(post.get_data())
-
- postsdata.sort(key=lambda r: r["adate"], reverse=True)
pyotherside.send("favoriteList", postsdata)
--
GitLab
From e9e9e3f4bac77004376ade6556a455b343b0368e Mon Sep 17 00:00:00 2001
From: Thilo Kogge
Date: Mon, 1 Feb 2021 22:06:44 +0100
Subject: [PATCH 6/6] moved favorite logic to main package, added tests, fixed
tests, stabilized tests
---
python/podcast/archive.py | 7 ++-
python/podcast/favorite.py | 80 ++++++++++++++++++++++++++++
qml/components/FavoriteHandler.py | 87 +++----------------------------
test/__init__.py | 14 ++++-
test/test_archive.py | 36 ++++++++-----
test/test_favorites.py | 35 +++++++++++++
test/test_queue.py | 28 +++++++++-
7 files changed, 188 insertions(+), 99 deletions(-)
create mode 100644 python/podcast/favorite.py
create mode 100644 test/test_favorites.py
diff --git a/python/podcast/archive.py b/python/podcast/archive.py
index 1f7f7dc..9318ec5 100644
--- a/python/podcast/archive.py
+++ b/python/podcast/archive.py
@@ -20,6 +20,8 @@ class ArchiveEntry:
@classmethod
def of_podpost(cls, postid: str):
+ if not type(postid) == str:
+ raise ValueError("did not get the id of a post")
archive_entry = ArchiveEntry()
archive_entry.podpost = postid
archive_entry.insert_date = time.time()
@@ -47,11 +49,12 @@ class Archive:
store = Factory().get_store()
store.store(archivename, self)
- def insert(self, podpost):
+ def insert(self, podpost: str):
"""
Insert an podost
"""
-
+ if type(podpost) != str:
+ raise ValueError("please supply the id of the post")
if podpost not in [e.podpost for e in self._archive_entries]:
self._archive_entries.insert(0, ArchiveEntry.of_podpost(podpost))
self.save()
diff --git a/python/podcast/favorite.py b/python/podcast/favorite.py
new file mode 100644
index 0000000..6117218
--- /dev/null
+++ b/python/podcast/favorite.py
@@ -0,0 +1,80 @@
+from podcast.factory import Factory
+
+
+def get_queue_favorites(podurl=None):
+ """
+ Return a list of all favorites posts from queue
+ """
+
+ from podcast.queue import QueueFactory
+
+ posts = []
+
+ queue = QueueFactory().get_queue()
+ for post in queue.get_podposts():
+ p = Factory().get_podpost(post)
+ try:
+ if p.favorite:
+ if podurl:
+ if p.podurl == podurl:
+ posts.append(p)
+ else:
+ posts.append(p)
+ except:
+ pass
+ return posts
+
+
+def append_archive_favorites(posts, podurl=None):
+ """
+ append archive favorites to posts list
+ """
+
+ from podcast.archive import ArchiveFactory
+
+ archive = ArchiveFactory().get_archive()
+
+ for post in archive.get_podposts():
+ p = Factory().get_podpost(post)
+ try:
+ if p.favorite:
+ if p not in posts:
+ if podurl:
+ if p.podurl == podurl:
+ posts.append(p)
+ else:
+ posts.append(p)
+ except:
+ pass
+
+ return posts
+
+
+def get_favorites(podurl=None):
+ """
+ Test
+ """
+
+ posts = get_queue_favorites(podurl)
+ posts = append_archive_favorites(posts, podurl=podurl)
+ yield from sorted(posts, key=lambda p: p.insert_date, reverse=True)
+
+
+def get_favorite_podcast_stats():
+ """
+ """
+
+ entries = {}
+
+ posts = get_queue_favorites()
+ posts = append_archive_favorites(posts)
+ for p in posts:
+ if p.podurl in entries:
+ entries[p.podurl]["count"] += 1
+ else:
+ if p.logo_url:
+ logo_url = p.logo_url
+ else:
+ logo_url = "../../images/podcast.png"
+ entries[p.podurl] = {"count": 1, "logo_url": logo_url}
+ return entries
diff --git a/qml/components/FavoriteHandler.py b/qml/components/FavoriteHandler.py
index 9ea0aab..98dfd6b 100644
--- a/qml/components/FavoriteHandler.py
+++ b/qml/components/FavoriteHandler.py
@@ -6,6 +6,7 @@ import threading
import sys
sys.path.append("/usr/share/harbour-podqast/python")
+import podcast.favorite as favorite
from podcast.factory import Factory
@@ -22,87 +23,11 @@ def toggle_favorite(podpost, do_download=False):
pyotherside.send("favoriteToggled", podpost, post.toggle_fav(do_download))
-def get_queue_favorites(podurl=None):
- """
- Return a list of all favorites posts from queue
- """
-
- from podcast.queue import QueueFactory
-
- posts = []
-
- queue = QueueFactory().get_queue()
- for post in queue.get_podposts():
- p = Factory().get_podpost(post)
- try:
- if p.favorite:
- if podurl:
- if p.podurl == podurl:
- posts.append(p)
- else:
- posts.append(p)
- except:
- pass
- return posts
-
-
-def append_archive_favorites(posts, podurl=None):
- """
- append archive favorites to posts list
- """
-
- from podcast.archive import ArchiveFactory
-
- archive = ArchiveFactory().get_archive()
-
- for post in archive.get_podposts():
- p = Factory().get_podpost(post)
- try:
- if p.favorite:
- if p not in posts:
- if podurl:
- if p.podurl == podurl:
- posts.append(p)
- else:
- posts.append(p)
- except:
- pass
-
- return posts
-
-
-def get_favorites(podurl=None):
- """
- Test
- """
-
- posts = get_queue_favorites(podurl)
- posts = append_archive_favorites(posts, podurl=podurl)
- postsdata = []
- for post in sorted(posts, key=lambda p: p.insert_date, reverse=True):
- postsdata.append(post.get_data())
- pyotherside.send("favoriteList", postsdata)
-
+def send_favorites(podurl=None):
+ pyotherside.send("favoriteList", [p.get_data() for p in favorite.get_favorites(podurl)])
def get_fav_pod_data():
- """
- """
-
- entries = {}
-
- posts = get_queue_favorites()
- posts = append_archive_favorites(posts)
- for p in posts:
- if p.podurl in entries:
- entries[p.podurl]["count"] += 1
- else:
- if p.logo_url:
- logo_url = p.logo_url
- else:
- logo_url = "../../images/podcast.png"
- entries[p.podurl] = {"count": 1, "logo_url": logo_url}
-
- pyotherside.send("archivePodList", entries)
+ pyotherside.send("archivePodList", favorite.get_favorite_podcast_stats())
class FavoriteHandler:
@@ -125,10 +50,10 @@ class FavoriteHandler:
return
if podurl:
self.bgthread2 = threading.Thread(
- target=get_favorites, args=[podurl]
+ target=send_favorites, args=[podurl]
)
else:
- self.bgthread2 = threading.Thread(target=get_favorites)
+ self.bgthread2 = threading.Thread(target=send_favorites)
self.bgthread2.start()
def getfavpoddata(self):
diff --git a/test/__init__.py b/test/__init__.py
index c174ad0..2de8407 100644
--- a/test/__init__.py
+++ b/test/__init__.py
@@ -4,13 +4,23 @@ import types
import sys
from unittest.mock import Mock
+
def mock_pyotherside():
module_name = "pyotherside"
module = types.ModuleType(module_name)
sys.modules[module_name] = module
- module.send = Mock(name=module_name+'.send')
+ module.send = Mock(name=module_name + '.send')
+
mock_pyotherside()
os.environ["PODQAST_HOME"] = tempfile.gettempdir()
-print("tempdir: %s"%os.environ["PODQAST_HOME"] )
+print("tempdir: %s" % os.environ["PODQAST_HOME"])
+
+
+def cleanup_archive():
+ from podcast.archive import ArchiveFactory
+ archive = ArchiveFactory().get_archive()
+ for post in archive.get_podposts():
+ archive.remove_podpost(post)
+ archive.save()
diff --git a/test/test_archive.py b/test/test_archive.py
index a1b958e..2c8e7a8 100644
--- a/test/test_archive.py
+++ b/test/test_archive.py
@@ -5,6 +5,8 @@ test the archive
import sys
from httpretty import HTTPretty, httprettified
+
+from . import cleanup_archive
from test.test_podcast import read_testdata, xml_headers
sys.path.append("../python")
@@ -14,6 +16,7 @@ from podcast.factory import Factory
from podcast.podcast import Podcast
from podcast.podpost import Podpost
+
def test_create_archive():
"""
test if archive is created
@@ -25,6 +28,7 @@ def test_create_archive():
a2 = ArchiveFactory().get_archive()
assert a1 == a2
+
def test_archive_save():
"""
does the archive save itself?
@@ -33,41 +37,47 @@ def test_archive_save():
a = ArchiveFactory().get_archive()
a.save()
-@httprettified
+
def test_insert():
"""
"""
+
+ archive = ArchiveFactory().get_archive()
+ entry1, entry2 = setup_archive_with_2_posts(archive)
+
+ result_posts = list(archive.get_podposts())
+ assert entry1.id in result_posts
+ assert entry2.id in result_posts
+ object_ids = [a.id for a in archive.get_podpost_objects('https://freakshow.fm/feed/opus/')]
+ assert entry1.id in object_ids
+ assert entry2.id in object_ids
+ assert 0 == len(list(archive.get_podpost_objects(url_filter='https://i.am.not.corrects/speex')))
+
+
+@httprettified
+def setup_archive_with_2_posts(archive):
HTTPretty.register_uri(HTTPretty.GET, 'https://freakshow.fm/feed/opus/',
body=read_testdata('testdata/freakshow.rss'), adding_headers=xml_headers)
-
- archive = ArchiveFactory().get_archive()
podcast = Podcast('https://freakshow.fm/feed/opus/')
entry1 = podcast.get_entry(podcast.entry_ids_old_to_new[0])
entry1.save()
archive.insert(entry1.id)
-
entry2 = podcast.get_entry(podcast.entry_ids_old_to_new[1])
entry2.save()
archive.insert(entry2.id)
+ return entry1, entry2
- result_posts = list(archive.get_podposts())
- assert entry1.id in result_posts
- assert entry2.id in result_posts
- object_ids = [a.id for a in archive.get_podpost_objects('https://freakshow.fm/feed/opus/')]
- assert entry1.id in object_ids
- assert entry2.id in object_ids
- assert 0 == len(list(archive.get_podpost_objects(url_filter='https://i.am.not.corrects/speex')))
def test_get_archives():
"""
Test listing of podposts
"""
-
+ cleanup_archive()
a = ArchiveFactory().get_archive()
+ setup_archive_with_2_posts(a)
count = 0
for post in a.get_podposts():
assert type(post) == str
assert type(Factory().get_podpost(post)) == Podpost
count += 1
- # make sure to clean ~/.local/share/harbour-podqast if this fails
assert count == 2
diff --git a/test/test_favorites.py b/test/test_favorites.py
new file mode 100644
index 0000000..c41e8fc
--- /dev/null
+++ b/test/test_favorites.py
@@ -0,0 +1,35 @@
+from httpretty import HTTPretty, httprettified
+
+from podcast.archive import ArchiveFactory
+from podcast.factory import Factory
+from . import cleanup_archive
+from test.test_podcast import read_testdata, xml_headers
+
+
+@httprettified
+def test_queue_favorites():
+ """
+ Test listing of podposts
+ """
+ HTTPretty.register_uri(HTTPretty.GET, 'https://freakshow.fm/feed/opus/',
+ body=read_testdata('testdata/freakshow.rss'), adding_headers=xml_headers)
+
+ from podcast import favorite
+ from podcast.podcast import PodcastFactory
+ cleanup_archive()
+
+ url = 'https://freakshow.fm/feed/opus/'
+ podcast = PodcastFactory().get_podcast(url)
+ fav_posts = [Factory().get_podpost(podcast.entry_ids_old_to_new[i]) for i in range(0, 10, 2)]
+ assert len(fav_posts) == 5
+ archive = ArchiveFactory().get_archive()
+ assert len(list(archive.get_podposts())) == 0
+ for post in fav_posts:
+ post.favorite = True
+ post.save()
+ archive.insert(post.id)
+ archive.save()
+ assert len(favorite.get_queue_favorites()) == 0
+ assert len(list(favorite.get_favorites())) == 5
+ assert len(favorite.get_favorite_podcast_stats()) == 1
+ assert favorite.get_favorite_podcast_stats()[url]['count'] == 5
diff --git a/test/test_queue.py b/test/test_queue.py
index f2e166d..7043775 100644
--- a/test/test_queue.py
+++ b/test/test_queue.py
@@ -38,6 +38,7 @@ def test_queue_save():
q = QueueFactory().get_queue()
q.save()
+
@httpretty.activate
def test_insert_top():
"""
@@ -79,4 +80,29 @@ def test_get_podposts():
for post in postids:
assert type(post) == str
assert type(Factory().get_podpost(post)) == Podpost
- assert post in [entry,entry2]
+ assert post in [entry, entry2]
+
+
+def test_queue_favorites():
+ """
+ Test listing of podposts
+ """
+ from podcast import favorite
+
+ queue = QueueFactory().get_queue()
+ url = 'https://freakshow.fm/feed/opus/'
+ podcast = PodcastFactory().get_podcast(url)
+ for post in (Factory().get_podpost(podcast.entry_ids_old_to_new[i]) for i in range(0, 10, 2)):
+ post.favorite = True
+ post.save()
+ for id in podcast.entry_ids_old_to_new:
+ queue.insert_bottom(id)
+ assert len(queue.podposts) == 20
+ assert len(favorite.get_queue_favorites('https://wrong.url')) == 0
+ assert [fav.id for fav in favorite.get_queue_favorites()] == [podcast.entry_ids_old_to_new[i] for i in
+ range(0, 10, 2)]
+ assert len(favorite.get_queue_favorites(url)) == 5
+ for id in podcast.entry_ids_old_to_new:
+ queue.remove(id)
+ assert len(queue.podposts) == 0
+ assert len(favorite.get_queue_favorites()) == 0
--
GitLab