Repository Analysis

mikf/gallery-dl

Command-line program to download image galleries and collections from several image hosting sites

5.9 Low AI signal View on GitHub
5.9
Adjusted Score
5.9
Raw Score
100%
Time Factor
2026-05-07
Last Push
18,319
Stars
Python
Language
138,849
Lines of Code
738
Files
700
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 0HIGH 10MEDIUM 71LOW 619

Pattern Findings

700 matches across 14 categories. Click a row to expand file-level details.

Excessive Try-Catch Wrapping329 hits · 380 pts
SeverityFileLineSnippet
LOWtest/test_results.py357 except Exception as exc:
LOWtest/test_results.py379 except Exception:
LOWtest/test_results.py401 except Exception as exc:
LOWtest/test_results.py594 except Exception as exc:
MEDIUMtest/test_results.py585def load_test_config():
LOWtest/test_ytdl.py276 except Exception:
MEDIUMtest/test_ytdl.py23def setUpClass(cls):
LOWscripts/run_tests.py37 except Exception as exc:
LOWscripts/util.py54 except Exception:
LOWscripts/supportedsites.py616 except Exception:
LOWscripts/docs_compare.py19 except Exception as exc:
LOWscripts/rm.py24 except Exception:
MEDIUMscripts/rm.py21def remove_file(args, path):
LOWscripts/init.py61 except Exception as exc:
LOWscripts/hook-gallery_dl.py29except Exception:
LOWscripts/pyprint.py64 except Exception:
MEDIUMgallery_dl/cookies.py311def _safari_cookies_database():
MEDIUMgallery_dl/cookies.py778def _get_gnome_keyring_password(browser_keyring_name):
MEDIUMgallery_dl/cookies.py934def __enter__(self):
LOWgallery_dl/cookies.py151 except Exception as exc:
LOWgallery_dl/cookies.py724 except Exception as exc:
LOWgallery_dl/cookies.py772 except Exception as exc:
LOWgallery_dl/cookies.py841 except Exception as exc:
LOWgallery_dl/cookies.py945 except Exception as exc:
LOWgallery_dl/formatter.py44 except Exception as exc:
LOWgallery_dl/formatter.py163 except Exception:
LOWgallery_dl/formatter.py173 except Exception:
LOWgallery_dl/formatter.py191 except Exception:
MEDIUMgallery_dl/formatter.py158def wrap(_):
MEDIUMgallery_dl/formatter.py168def wrap(kwdict):
LOWgallery_dl/config.py150 except Exception as exc:
LOWgallery_dl/config.py176 except Exception as exc:
LOWgallery_dl/config.py230 except Exception as exc:
LOWgallery_dl/config.py260 except Exception:
LOWgallery_dl/config.py273 except Exception:
LOWgallery_dl/config.py291 except Exception:
LOWgallery_dl/config.py303 except Exception:
LOWgallery_dl/config.py328 except Exception:
LOWgallery_dl/config.py359 except Exception:
LOWgallery_dl/option.py993 except Exception:
LOWgallery_dl/util.py233 except Exception:
LOWgallery_dl/util.py408 except Exception:
LOWgallery_dl/util.py823 except Exception:
LOWgallery_dl/util.py1040 except Exception as exc:
MEDIUMgallery_dl/util.py363def git_head():
MEDIUMgallery_dl/util.py548def __getitem__(self, key, modules=sys.modules):
MEDIUMgallery_dl/util.py1035def _pred(_, kwdict):
LOWgallery_dl/dt.py58 except Exception:
LOWgallery_dl/dt.py74 except Exception:
LOWgallery_dl/dt.py86 except Exception:
LOWgallery_dl/dt.py101 except Exception:
LOWgallery_dl/dt.py114 except Exception:
LOWgallery_dl/aes.py17except Exception as exc:
LOWgallery_dl/job.py187 except Exception as exc:
LOWgallery_dl/job.py366 except Exception as exc:
LOWgallery_dl/job.py731 except Exception as exc:
LOWgallery_dl/job.py837 except Exception as exc:
LOWgallery_dl/job.py1094 except Exception as exc:
LOWgallery_dl/job.py1113 except Exception:
LOWgallery_dl/cache.py32 except Exception as exc:
269 more matches not shown…
Deep Nesting199 hits · 190 pts
SeverityFileLineSnippet
LOWtest/test_results.py620
LOWtest/test_results.py113
LOWtest/test_results.py332
LOWscripts/generate_test_result.py53
LOWscripts/generate_test_result.py112
LOWscripts/generate_test_result.py196
LOWscripts/supportedsites.py676
LOWscripts/man.py111
LOWscripts/man.py229
LOWscripts/rm.py28
LOWscripts/rm.py47
LOWscripts/requirements.py20
LOWscripts/requirements.py106
LOWscripts/requirements.py133
LOWscripts/requirements.py157
LOWscripts/init.py32
LOWgallery_dl/update.py162
LOWgallery_dl/cookies.py127
LOWgallery_dl/cookies.py216
LOWgallery_dl/cookies.py356
LOWgallery_dl/cookies.py1002
LOWgallery_dl/cookies.py1113
LOWgallery_dl/formatter.py296
LOWgallery_dl/formatter.py156
LOWgallery_dl/config.py33
LOWgallery_dl/config.py216
LOWgallery_dl/config.py278
LOWgallery_dl/config.py310
LOWgallery_dl/option.py95
LOWgallery_dl/ytdl.py81
LOWgallery_dl/util.py337
LOWgallery_dl/util.py980
LOWgallery_dl/util.py1077
LOWgallery_dl/util.py1208
LOWgallery_dl/aes.py557
LOWgallery_dl/job.py210
LOWgallery_dl/job.py339
LOWgallery_dl/job.py418
LOWgallery_dl/job.py530
LOWgallery_dl/job.py620
LOWgallery_dl/job.py695
LOWgallery_dl/job.py948
LOWgallery_dl/actions.py36
LOWgallery_dl/__init__.py22
LOWgallery_dl/__init__.py485
LOWgallery_dl/text.py321
LOWgallery_dl/text.py342
LOWgallery_dl/path.py28
LOWgallery_dl/path.py258
LOWgallery_dl/path.py273
LOWgallery_dl/path.py318
LOWgallery_dl/path.py350
LOWgallery_dl/path.py385
LOWgallery_dl/output.py352
LOWgallery_dl/output.py193
LOWgallery_dl/postprocessor/metadata.py20
LOWgallery_dl/postprocessor/ugoira.py30
LOWgallery_dl/postprocessor/ugoira.py138
LOWgallery_dl/postprocessor/ugoira.py168
LOWgallery_dl/postprocessor/ugoira.py246
139 more matches not shown…
Hyper-Verbose Identifiers118 hits · 104 pts
SeverityFileLineSnippet
LOWtest/test_postprocessor.py615 def test_metadata_json_options(self):
LOWtest/test_postprocessor.py684 def test_metadata_tags_tagstring(self):
LOWtest/test_postprocessor.py693 def test_metadata_tags_list_of_dict(self):
LOWtest/test_postprocessor.py782 def test_metadata_directory_format(self):
LOWtest/test_postprocessor.py794 def test_metadata_directory_empty(self):
LOWtest/test_postprocessor.py805 def test_metadata_basedirectory(self):
LOWtest/test_postprocessor.py814 def test_metadata_basedirectory_custom(self):
LOWtest/test_postprocessor.py914 def test_metadata_option_skip(self):
LOWtest/test_postprocessor.py938 def test_metadata_option_skip_false(self):
LOWtest/test_postprocessor.py948 def test_metadata_option_newline(self):
LOWtest/test_postprocessor.py970 def test_metadata_option_include(self):
LOWtest/test_postprocessor.py985 def test_metadata_option_exclude(self):
LOWtest/test_job.py94 def test_parent_metadata_extractor(self):
LOWtest/test_cookies.py146 def test_check_cookies_domain(self):
LOWtest/test_cookies.py171 def test_check_cookies_domain_sub(self):
LOWtest/test_cookies.py198 def test_check_cookies_expires(self):
LOWtest/test_ytdl.py63 def test_authentication_options(self):
LOWtest/test_ytdl.py332 def test_process_entries_restart_propagation(self):
LOWtest/test_ytdl.py345 def test_process_entries_ignoreerrors_true(self):
LOWtest/test_ytdl.py361 def test_process_entries_ignoreerrors_false(self):
LOWtest/test_output.py118 def test_shorten_eaw_separator(self, f=output.shorten_string_eaw):
LOWtest/test_output.py130 def test_shorten_eaw_separator_wide(self, f=output.shorten_string_eaw):
LOWtest/test_output.py142 def test_shorten_eaw_separator_mix_(self, f=output.shorten_string_eaw):
LOWtest/test_util.py204 def test_predicate_tags_negate(self):
LOWtest/test_util.py269 def test_predicate_tags_multi(self):
LOWtest/test_util.py296 def test_predicate_tags_minus(self):
LOWtest/test_util.py410 def test_predicate_date_before(self):
LOWtest/test_util.py433 def test_predicate_date_after(self):
LOWtest/test_util.py622 def test_compile_expression_raw(self):
LOWtest/test_util.py633 def test_compile_expression_tryexcept(self):
LOWtest/test_util.py641 def test_compile_expression_defaultdict(self):
LOWtest/test_util.py868 def test_build_selection_func(self, f=util.build_selection_func):
LOWtest/test_util.py908 def test_build_duration_func_ex(self, f=util.build_duration_func_ex):
LOWtest/test_text.py235 def test_filename_from_contentdisposition(
LOWtest/test_text.py467 def test_parse_unicode_escapes(self, f=text.parse_unicode_escapes):
LOWtest/test_formatter.py151 def test_missing_custom_default(self):
LOWtest/test_formatter.py286 def test_specifier_maxlen_bytes(self):
LOWtest/test_formatter.py336 def test_specifier_offset_local(self):
LOWtest/test_formatter.py366 def test_specifier_arithmetic(self):
LOWtest/test_formatter.py371 def test_specifier_conversions(self):
LOWtest/test_formatter.py383 def test_specifier_limit_bytes(self):
LOWtest/test_extractor.py306 def test_date_min_max_default(self):
LOWtest/test_extractor.py317 def test_date_min_max_timestamp(self):
LOWtest/test_extractor.py335 def test_date_min_max_iso_invalid(self):
LOWtest/test_path.py135 def test_generate_path_windows(self):
LOWtest/test_path.py216 def test_option_basedirectory(self):
LOWtest/test_path.py229 def test_option_keywordsdefault(self):
LOWtest/test_path.py244 def test_option_extensionmap_default(self):
LOWtest/test_path.py267 def test_option_extensionmap_custom(self):
LOWtest/test_path.py320 def test_option_pathrestrict_custom(self):
LOWtest/test_downloader.py278 def test_http_adjust_extension(self):
LOWtest/test_downloader.py328class HttpRequestHandler(http.server.BaseHTTPRequestHandler):
LOWtest/test_cache.py163 def test_invalidate_mem_simple(self):
LOWscripts/rm.py28def remove_from_docs_configurationrst(args, path):
LOWscripts/rm.py47def remove_from_docs_gallerydlconf(args, path):
LOWscripts/rm.py62def remove_from_extractor_init(args, path):
LOWscripts/rm.py72def remove_from_scripts_supportedsites(args, path):
LOWscripts/rm.py84def update_docs_supportedsites(args, path):
LOWscripts/init.py92def generate_extractors_basic(args):
LOWscripts/init.py124def generate_extractors_manga(args):
58 more matches not shown…
Decorative Section Separators19 hits · 58 pts
SeverityFileLineSnippet
MEDIUMsnap/snapcraft.yaml4# ------------------------------
MEDIUMgallery_dl/cookies.py213# --------------------------------------------------------------------
MEDIUMgallery_dl/cookies.py307# --------------------------------------------------------------------
MEDIUMgallery_dl/cookies.py408# --------------------------------------------------------------------
MEDIUMgallery_dl/cookies.py680# --------------------------------------------------------------------
MEDIUMgallery_dl/cookies.py868# --------------------------------------------------------------------
MEDIUMgallery_dl/config.py19# --------------------------------------------------------------------
MEDIUMgallery_dl/config.py29# --------------------------------------------------------------------
MEDIUMgallery_dl/actions.py175# --------------------------------------------------------------------
MEDIUMgallery_dl/output.py17# --------------------------------------------------------------------
MEDIUMgallery_dl/output.py63# --------------------------------------------------------------------
MEDIUMgallery_dl/output.py325# --------------------------------------------------------------------
MEDIUMgallery_dl/output.py369# --------------------------------------------------------------------
MEDIUMgallery_dl/postprocessor/__init__.py46# --------------------------------------------------------------------
MEDIUMgallery_dl/downloader/__init__.py43# --------------------------------------------------------------------
MEDIUMgallery_dl/extractor/__init__.py304# --------------------------------------------------------------------
MEDIUMgallery_dl/extractor/oauth.py248# --------------------------------------------------------------------
MEDIUMgallery_dl/extractor/oauth.py308# --------------------------------------------------------------------
MEDIUMgallery_dl/extractor/oauth.py410# --------------------------------------------------------------------
Cross-Language Confusion7 hits · 35 pts
SeverityFileLineSnippet
HIGHtest/test_dt.py97 self.assertEqual(f(0) , null)
HIGHtest/test_dt.py98 self.assertEqual(f("0") , null)
HIGHscripts/completion_zsh.py23%(opts)s && rc=0
HIGHgallery_dl/option.py978 "Example: --exec \"convert {} {}.png && rm {}\""),
HIGHgallery_dl/util.py1007 return true
HIGHgallery_dl/util.py1144 return true
HIGHgallery_dl/extractor/facebook.py134 photo_page, '{"node":{"id"', '"cursor":null}'
Synthetic Comment Markers2 hits · 10 pts
SeverityFileLineSnippet
HIGHCONTRIBUTING.md11Do not submit code that was primarily generated by AI tools.
HIGH.github/PULL_REQUEST_TEMPLATE.md9Do not submit code that was primarily generated by AI tools.
Fake / Example Data6 hits · 8 pts
SeverityFileLineSnippet
LOWtest/test_text.py447 <a href="http://www.example.com">Lorem ipsum dolor sit amet</a>.
LOWtest/test_text.py447 <a href="http://www.example.com">Lorem ipsum dolor sit amet</a>.
LOWtest/test_formatter.py40 {"name": "John Doe" , "age": 42, "email": "jd@example.org"},
LOWtest/test_formatter.py49 <a href="http://www.example.com">Lorem ipsum dolor sit amet</a>.
LOWtest/test_formatter.py49 <a href="http://www.example.com">Lorem ipsum dolor sit amet</a>.
LOWtest/test_formatter.py396 "['John Doe', 'Jane Smith', 'Max Mustermann']")
Unused Imports7 hits · 7 pts
SeverityFileLineSnippet
LOWtest/test_ytdl.py15
LOWtest/test_text.py15
LOWtest/test_formatter.py18
LOWtest/test_extractor.py20
LOWtest/test_extractor.py22
LOWtest/test_downloader.py25
LOWgallery_dl/dt.py13
Dead Code3 hits · 6 pts
SeverityFileLineSnippet
MEDIUMtest/test_oauth.py149
MEDIUMtest/test_oauth.py153
MEDIUMgallery_dl/extractor/common.py112
Self-Referential Comments2 hits · 6 pts
SeverityFileLineSnippet
MEDIUMsnap/snapcraft.yaml5# This file is in the YAML data serialization format:
MEDIUMgallery_dl/extractor/generic.py214 # Create the image metadata dict and add imageurl to it
Over-Commented Block5 hits · 5 pts
SeverityFileLineSnippet
LOWtest/results/discord.py21},
LOWtest/results/discord.py41# "#parent_id" : "1306705919916249098",
LOWsnap/snapcraft.yaml1%YAML 1.1
LOWgallery_dl/version.py1# -*- coding: utf-8 -*-
LOWgallery_dl/extractor/utils/twitter_transaction_id.py1# -*- coding: utf-8 -*-
Docstring Block Structure1 hit · 5 pts
SeverityFileLineSnippet
HIGHgallery_dl/text.py167Extract the text between 'begin' and 'end' from 'txt' Args: txt: String to search in begin: First s
AI Slop Vocabulary1 hit · 2 pts
SeverityFileLineSnippet
MEDIUMtest/results/mangareader.py117 "description" : """To everyone else in his magic-dominated world, the young and powerless Mash Vandead is a threat
Redundant / Tautological Comments1 hit · 2 pts
SeverityFileLineSnippet
LOWgallery_dl/extractor/cfake.py112 # Check if next page link exists anywhere in the page