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

TagOrigin to MetadataOrigin #20

Merged
merged 1 commit into from
Jun 22, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 3 additions & 4 deletions gcd_talker/gcd.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,21 +23,20 @@
import pathlib
import re
import sqlite3
from typing import Any, Callable
from typing import Any, Callable, TypedDict
from urllib.parse import urljoin

import requests
import settngs
from bs4 import BeautifulSoup
from comicapi import utils
from comicapi.genericmetadata import ComicSeries, GenericMetadata, TagOrigin
from comicapi.genericmetadata import ComicSeries, GenericMetadata, MetadataOrigin
from comicapi.issuestring import IssueString
from comictalker.comiccacher import ComicCacher
from comictalker.comiccacher import Issue as CCIssue
from comictalker.comiccacher import Series as CCSeries
from comictalker.comictalker import ComicTalker, TalkerDataError, TalkerNetworkError
from pyrate_limiter import Limiter, RequestRate
from typing_extensions import TypedDict
from urllib3.exceptions import LocationParseError
from urllib3.util import parse_url

Expand Down Expand Up @@ -914,7 +913,7 @@ def _fetch_issue_by_issue_id(self, issue_id: int) -> GCDIssue:

def _map_comic_issue_to_metadata(self, issue: GCDIssue, series: GCDSeries) -> GenericMetadata:
md = GenericMetadata(
tag_origin=TagOrigin(self.id, self.name),
data_origin=MetadataOrigin(self.id, self.name),
issue_id=utils.xlate(issue["id"]),
series_id=utils.xlate(series["id"]),
publisher=utils.xlate(series.get("publisher_name")),
Expand Down
Loading