Skip to content

Commit

Permalink
resolve relative imports
Browse files Browse the repository at this point in the history
  • Loading branch information
matejsuchanek committed Nov 13, 2023
1 parent a9c0c64 commit 98bf111
Show file tree
Hide file tree
Showing 31 changed files with 56 additions and 56 deletions.
4 changes: 2 additions & 2 deletions captiontoimage.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

from pywikibot import pagegenerators

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class CaptionToImageBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions check_disambigs.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
from pywikibot import pagegenerators
from pywikibot.exceptions import NoPageError

from .error_reporting import ErrorReportingBot
from .wikidata import WikidataEntityBot
from error_reporting import ErrorReportingBot
from wikidata import WikidataEntityBot


class DisambigsCheckingBot(WikidataEntityBot, ErrorReportingBot):
Expand Down
4 changes: 2 additions & 2 deletions checkwiki.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
from pywikibot import pagegenerators
from pywikibot.exceptions import UnknownExtension

from .checkwiki_errors import *
from .wikitext import WikitextFixingBot
from checkwiki_errors import *
from wikitext import WikitextFixingBot


class CheckWikiSettings:
Expand Down
2 changes: 1 addition & 1 deletion checkwiki_errors.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

from pywikibot import textlib

from .tools import deduplicate
from tools import deduplicate


class CheckWikiError:
Expand Down
6 changes: 3 additions & 3 deletions clean_commonscat.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@
from pywikibot import i18n, pagegenerators, textlib
from pywikibot.exceptions import UnknownExtensionError

from .deferred import DeferredCallbacksBot
from .wikidata import WikidataEntityBot
from .wikitext import WikitextFixingBot
from deferred import DeferredCallbacksBot
from wikidata import WikidataEntityBot
from wikitext import WikitextFixingBot


save_summary = {
Expand Down
6 changes: 3 additions & 3 deletions clean_dupes.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@
WikidataSPARQLPageGenerator,
)

from .merger import Merger
from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from merger import Merger
from query_store import QueryStore
from wikidata import WikidataEntityBot
from scripts.revertbot import BaseRevertBot


Expand Down
4 changes: 2 additions & 2 deletions cleanup_dates.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
WikidataSPARQLPageGenerator,
)

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class DuplicateDatesBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion cleanup_redirects.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from pywikibot.bot import WikidataBot
from pywikibot.exceptions import NoPageError

from .merger import Merger
from merger import Merger


class WikidataRedirectsBot(WikidataBot):
Expand Down
6 changes: 3 additions & 3 deletions custome_fixes.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@
from pywikibot.tools import first_lower, first_upper
from pywikibot.tools.formatter import color_format

from .checkwiki_errors import CheckWikiError
from .tools import deduplicate, FULL_ARTICLE_REGEX
from .typoloader import TypoRule, TyposLoader
from checkwiki_errors import CheckWikiError
from tools import deduplicate, FULL_ARTICLE_REGEX
from typoloader import TypoRule, TyposLoader


class FixGenerator:
Expand Down
4 changes: 2 additions & 2 deletions fake_references.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
from pywikibot import pagegenerators
from pywikibot.backports import removeprefix

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class FakeReferencesBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions fix_commons_labels.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
from pywikibot import pagegenerators
from pywikibot.backports import removeprefix

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class LabelsFixingBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions fix_qualifiers.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

from pywikibot import pagegenerators

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class QualifiersFixingBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions import_descriptions.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
WikidataSPARQLPageGenerator,
)

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class BaseDescriptionBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion import_displaytitle.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
)
from pywikibot.tools import first_lower

from .wikidata import WikidataEntityBot
from wikidata import WikidataEntityBot


class LabelSettingBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion klementinum.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
import mwparserfromhell as parser
import pywikibot

from .lua_formatter import format_dictionary
from lua_formatter import format_dictionary


def get_single_year(year):
Expand Down
2 changes: 1 addition & 1 deletion list_typos.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from pywikibot.pagegenerators import PreloadingGenerator
from pywikibot.tools.itertools import itergroup

from .typoloader import TypoRule, TyposLoader
from typoloader import TypoRule, TyposLoader


class TypoReportBot(SingleSiteBot):
Expand Down
4 changes: 2 additions & 2 deletions manage_duos.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
from pywikibot import pagegenerators
from pywikibot.data.sparql import SparqlQuery

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class DuosManagingBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions metabot.py
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@
from pywikibot.textlib import mwparserfromhell
from pywikibot.tools import first_upper

from .tools import get_best_statements
from .wikidata import WikidataEntityBot
from tools import get_best_statements
from wikidata import WikidataEntityBot


def parse_float(value): # todo: move to tools
Expand Down
6 changes: 3 additions & 3 deletions migrate_infobox.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@
from pywikibot.tools import first_upper

try:
from .wikitext import WikitextFixingBot
# TODO: from .tools import .
from .custome_fixes import FilesFix
from wikitext import WikitextFixingBot
# TODO: from tools import .
from custome_fixes import FilesFix
except ImportError:
from pywikibot.bot import SingleSiteBot, ExistingPageBot

Expand Down
4 changes: 2 additions & 2 deletions nounit.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@

from pywikibot import pagegenerators

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class UnitsFixingBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion qs.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
)
from pywikibot.page import Property

from .wikidata import WikidataEntityBot
from wikidata import WikidataEntityBot


class QuickStatementsBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions shift_ranks.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

from pywikibot import pagegenerators

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class RanksShiftingBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions slice_externalids.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
WikidataSPARQLPageGenerator,
)

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class ExternalIdSlicingBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions split_claims.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

from pywikibot import pagegenerators

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class ClaimsSplittingBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion split_names_and_titles.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
from pywikibot.textlib import mwparserfromhell

try:
from .wikitext import WikitextFixingBot
from wikitext import WikitextFixingBot
except ImportError:
from pywikibot.bot import SingleSiteBot, ExistingPageBot

Expand Down
2 changes: 1 addition & 1 deletion sync_heritage_lists.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
from pywikibot.textlib import removeDisabledParts
from pywikibot.data.sparql import *

from .tools import get_best_statements
from tools import get_best_statements


def get_sources(page):
Expand Down
4 changes: 2 additions & 2 deletions typos.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
import pywikibot
from pywikibot import pagegenerators

from .typoloader import TyposLoader
from .wikitext import WikitextFixingBot
from typoloader import TyposLoader
from wikitext import WikitextFixingBot


class TypoBot(WikitextFixingBot):
Expand Down
2 changes: 1 addition & 1 deletion wikidata.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
from pywikibot.bot import WikidataBot
from pywikibot.exceptions import NoPageError, IsRedirectPageError

from .wikidata_cleanup_toolkit import WikidataCleanupToolkit
from wikidata_cleanup_toolkit import WikidataCleanupToolkit


class WikidataEntityBot(WikidataBot):
Expand Down
4 changes: 2 additions & 2 deletions wikidata_cleanup.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@

from pywikibot import pagegenerators

from .wikidata import WikidataEntityBot
from .wikidata_cleanup_toolkit import WikidataCleanupToolkit
from wikidata import WikidataEntityBot
from wikidata_cleanup_toolkit import WikidataCleanupToolkit


class WikidataCleanupBot(WikidataEntityBot):
Expand Down
4 changes: 2 additions & 2 deletions wikidata_fix_redirects.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@
WikidataSPARQLPageGenerator,
)

from .query_store import QueryStore
from .wikidata import WikidataEntityBot
from query_store import QueryStore
from wikidata import WikidataEntityBot


class WikidataRedirectsFixingBot(WikidataEntityBot):
Expand Down
2 changes: 1 addition & 1 deletion wikitext.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from pywikibot import pagegenerators
from pywikibot.bot import SingleSiteBot, ExistingPageBot

from .custome_fixes import all_fixes
from custome_fixes import all_fixes


class WikitextFixingBot(SingleSiteBot, ExistingPageBot):
Expand Down

0 comments on commit 98bf111

Please sign in to comment.