From 7985eec4933b0267180863ce434bd3d1c7634eb3 Mon Sep 17 00:00:00 2001 From: daijro Date: Wed, 2 Oct 2024 00:09:42 -0500 Subject: [PATCH] pythonlib: Allow fetch without geoip 0.2.3 Fix fetch not checking if geoip2 is installed before trying to download the mmdb. --- pythonlib/camoufox/__main__.py | 5 +++-- pythonlib/pyproject.toml | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/pythonlib/camoufox/__main__.py b/pythonlib/camoufox/__main__.py index 6249548..e063fe7 100644 --- a/pythonlib/camoufox/__main__.py +++ b/pythonlib/camoufox/__main__.py @@ -11,7 +11,7 @@ from typing import Optional import click -from .locale import download_mmdb, remove_mmdb +from .locale import ALLOW_GEOIP, download_mmdb, remove_mmdb from .pkgman import INSTALL_DIR, CamoufoxFetcher, installed_verstr, rprint @@ -74,7 +74,8 @@ def fetch() -> None: """ CamoufoxUpdate().update() # Fetch the GeoIP database - download_mmdb() + if ALLOW_GEOIP: + download_mmdb() @cli.command(name='remove') diff --git a/pythonlib/pyproject.toml b/pythonlib/pyproject.toml index b64b5d5..46fdc1e 100644 --- a/pythonlib/pyproject.toml +++ b/pythonlib/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "poetry.core.masonry.api" [tool.poetry] name = "camoufox" -version = "0.2.2" +version = "0.2.3" description = "Wrapper around Playwright to help launch Camoufox" authors = ["daijro "] license = "MIT"