Skip to main content

H@H Gallery Parser (h2h-galleryinfo-parser)

H@H Gallery Parser is a Python package designed to parse downloaded gallery files from H@H, a gallery download tool. When H@H downloads a gallery, it creates a folder named after the gallery, containing image files and a galleryinfo.txt file. This package helps extract useful information from the galleryinfo.txt file for further use.

Features

The package provides three core functionalities:

  1. Parse Gallery ID: Extract the gallery ID from a given gallery folder.

  2. Gallery Information Parsing: The GalleryInfoParser class represents a parser for extracting detailed gallery information, including the gallery name, ID, modification time, title, upload and download times, comments, uploader account, tags, and the number of pages. File paths are not retained; the page count is computed lazily with a constant-memory directory pass.

  3. Parse Gallery Information: Extracts all relevant details from the given folder and returns an instance of GalleryInfoParser containing the parsed information.

Installation

You can install this package using pip:

pip install h2h-galleryinfo-parser

Usage

Here's a quick example of how to use H@H Gallery Parser:

from pathlib import Path

from h2h_galleryinfo_parser import parse_gid, parse_galleryinfo

# Parse gallery ID from folder path
gallery_id = parse_gid(Path("/path/to/gallery/folder"))
print(f"Gallery ID: {gallery_id}")

# Parse gallery information
gallery_info = parse_galleryinfo(Path("/path/to/gallery/folder"))
print(f"Gallery Title: {gallery_info.title}")
print(f"Tags: {gallery_info.tags}")

License

This project is distributed under the terms of the GNU General Public Licence (GPL). For detailed licence terms, see the LICENSE file included in this distribution.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

h2h_galleryinfo_parser-0.5.3.tar.gz (23.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

h2h_galleryinfo_parser-0.5.3-py3-none-any.whl (17.1 kB view details)

Uploaded Python 3

File details

Details for the file h2h_galleryinfo_parser-0.5.3.tar.gz.

File metadata

  • Download URL: h2h_galleryinfo_parser-0.5.3.tar.gz
  • Upload date:
  • Size: 23.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for h2h_galleryinfo_parser-0.5.3.tar.gz
Algorithm Hash digest
SHA256 e55cc4c60a830727f4ac3c6b8604ee8ba85e3500998182af1854c75af5bd5841
MD5 76f769b38d7d386b9bfd331b593f553c
BLAKE2b-256 817aaacbdcfe3fba125ff125beb4fdaed611d0c104eaa6bb310989c562b5166c

See more details on using hashes here.

Provenance

The following attestation bundles were made for h2h_galleryinfo_parser-0.5.3.tar.gz:

Publisher: publish.yml on Kuan-Lun/h2h-galleryinfo-parser

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file h2h_galleryinfo_parser-0.5.3-py3-none-any.whl.

File metadata

File hashes

Hashes for h2h_galleryinfo_parser-0.5.3-py3-none-any.whl
Algorithm Hash digest
SHA256 9b9b0177009e5c56d7ebd70570f670458fe11a10526dc5da4604e12cbf95935c
MD5 700ca028c21595a85101ae0b2298f5f5
BLAKE2b-256 6f9f2389bfd474b174210d9b6181844c6d191d42616bdb9bc0b8b71e600e9df5

See more details on using hashes here.

Provenance

The following attestation bundles were made for h2h_galleryinfo_parser-0.5.3-py3-none-any.whl:

Publisher: publish.yml on Kuan-Lun/h2h-galleryinfo-parser

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.5.3 This release

2 files

0.5.2

2 files

0.5.1

2 files

0.5.0

2 files

0.4.0

2 files

0.3.0

2 files

0.2.2

2 files

0.2.1

2 files

0.2.0

2 files

0.1.3

2 files

0.1.2

2 files

0.1.1

2 files

0.1.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page