Skip to content

Releases: d4NY0H/neoconv

1.4.1

Choose a tag to compare

@github-actions github-actions released this 01 Jun 08:23

New

  • Structured error API — Expected failures use a small hierarchy instead of bare ValueError:
    • NeoConvError (base, with code and optional hint)
    • InvalidNeoError — bad or truncated .neo files
    • InvalidRomLayoutError — MAME layout, naming, ZIP/dir issues, C/V sequence gaps
    • InvalidConfigurationError — extract sizes, P-ROM swap rules
    • UserCancelledError — GUI operation cancelled
  • resolve_genre() in neoconv.core — One shared function for genre name/id validation (CLI and GUI use the same rules).
  • SwapMode enumAUTO, YES, and NO for P-ROM bank swap in core, CLI, and GUI (replaces mixed bool/string handling).
  • py.typed in published wheels — PEP 561 marker so type checkers can use neoconv as a typed dependency.

Improvements

  • GUI — Pack with auto swap — Parses the ROM source once and runs swap detection once (faster on large sets; less redundant work than before).
  • GUI — Genre handling — Pack and Edit validate genre like the CLI; Pack preflight shows invalid genre in the status line (no silent “genre id 0”).
  • GUI — Clearer feedback — Info tab shows proper .neo errors with hints; Edit tab warns when header metadata cannot be loaded; cancel is reported as info, not a generic error.
  • GUI — Startup — If tkinter is missing, neoconv-gui exits with OS-specific install hints instead of a raw import error.
  • CLI & GUI — Actionable errors — Hints are printed/logged where available (e.g. C chip size, P-ROM swap on non–2 MB ROMs).
  • Pack--swap-p yes on a non–2 MB P-ROM fails with an explicit message and hint (detect-swap / use auto or no).
  • Library ergonomicsSwapMode, exception types, and resolve_genre are exported from neoconv.core.
  • Tests — End-to-end roundtrip integration tests (pack ↔ extract) strengthen regression coverage.

Bug fixes

  • Interleave: odd C chip count raises a clear layout error instead of IndexError.
  • Pack: _word_swap loop step corrected (off-by-one).
  • CLI: internal assert in extract replaced with RuntimeError for impossible states.
  • Removed stray duplicate neoconv/core/cli.py.

Documentation

  • README overhaul: Getting started table (pack / extract / edit / info), CLI + GUI called out up front, clearer structure and technical overview.
  • Pack metadata limits (latin-1 field lengths, uint types) and extract size reference (byte values for --c-chip-size / --v-bank-size).
  • Explained 2 MB fallback when sizes are unset vs per-game sizes from MAME / neogeo.xml.
  • FBNeo compatibility and split-C-chip notes; why C/V sizes must be chosen on extract.
  • New section: Errors (library API) for embedders.

For Python embedders

from neoconv.core import (
    NeoConvError,
    InvalidNeoError,
    InvalidRomLayoutError,
    InvalidConfigurationError,
    UserCancelledError,
    resolve_genre,
    SwapMode,
)

Catch NeoConvError subclasses for expected failures; read .code and .hint for stable handling and user-facing text.

Upgrade notes

  • Library code that caught ValueError from neoconv.core should catch NeoConvError (or the specific subclasses) instead.
  • CLI behaviour for successful conversions is unchanged; error text may include an extra hint line after —.
  • No new CLI subcommands since 1.3.0; extract sizing (--c-chip-size, --v-bank-size) and other 1.3.x behaviour is unchanged.

1.3.0

Choose a tag to compare

@github-actions github-actions released this 17 May 15:21

Added

  • --v-bank-size for extract (CLI and GUI): choose the size of each v1, v2, … file when splitting V ROM (default 2 MB; presets 512 KB–16 MB in the GUI, any byte value on the CLI).
  • C ROM chips C9–C16 when packing MAME sets (extended / hack ROM layouts beyond the standard eight C chips).
  • Pack from unzipped folders: reads ROM files in the selected directory and one level of subfolders (typical unzip layout).
  • GUI pack preflight: warns when V or C ROM numbering has gaps (e.g. v1 + v3 without v2) before you pack.
  • Extract overwrite warnings: existing output files are replaced with a visible warning (CLI → stderr, GUI → log).

Changed

  • C chip size on extract: default is now a fixed 2 MB per chip (CLI 0, GUI “2 MB (default)”). The old auto (C_total ÷ 2) mode was removed — it could silently produce wrong c*.bin files for multi-bank sets. Use MAME neogeo.xml size attributes or the GUI/CLI presets (e.g. 4 MB for Neo Turf Masters).
  • V/C ROM gaps when packing now abort with an error instead of continuing with a broken layout.
  • P-ROM auto-swap: when detection is inconclusive, pack logs [WARN] and suggests neoconv detect-swap or --swap-p yes / no.
  • CLI errors: pack, extract, and other commands report Error: … and exit code 1 instead of a Python traceback for typical failures.
  • Core package layout: neoconv.core is split into focused modules; several semi-public helpers were renamed (no leading underscore).

Fixed

  • Atomic writes for pack output (.neo) and extract-to-ZIP (same pattern as edit); reduces risk of truncated files if a run is interrupted.
  • GUI worker thread safety (Tk updates via a main-thread queue).
  • Synthetic S-ROM filename heuristics aligned with more MAME set patterns.
  • .neo metadata edits (edit) rewrite the header without re-parsing ROM payloads.
  • V1/V2 header read/write behaviour documented; non-standard split V sizes trigger a warning on load.
  • Various pack/extract edge cases (duplicate ROM roles, sorted directory iteration, P-ROM swap immutability).

Documentation

  • README: C9–C16, C/V chip and bank size tables, neogeo.xml lookup hints, pack gap behaviour, detect-swap vs GUI Pack auto-detect, --out-dir vs --out, atomic output, extract overwrite behaviour.
  • Drag & drop (tkinterdnd2) and release workflow notes updated.

Tests

  • Test count 123 (up from 114 at 1.2.0).

1.2.0

Choose a tag to compare

@github-actions github-actions released this 14 May 08:03

What's new

  • info output: When showing ROM details (CLI info, extract header block, GUI Info tab), neoconv now prints MD5 checksums per region (P, S, M, V, C). Handy to confirm two .neo files differ only in the TerraOnion header while payload regions match.
  • Layout: Region sizes and Total are grouped first; MD5 lines follow underneath so the summary reads clearly.

Documentation

  • README: Intro updated so the project is described as both converting (.neo ↔ MAME/Darksoft) and editing .neo header metadata without repacking; “Why neoconv” tweaked accordingly.
  • ROM role detection: Extra section on synthetic S-ROM (boards without a physical s1), filename heuristics, and clarification that MAME set-ID digits in filenames are not the same as the .neo NGH header field.
  • mame_zip_to_neo / mame_dir_to_neo: Docstrings note that the CLI/GUI pack flow defaults to swap_p="auto", while the Python API default remains False unless you pass "auto".

1.1.0

Choose a tag to compare

@github-actions github-actions released this 14 May 06:36

What's new

  • Edit .neo metadata without repacking: New CLI command neoconv edit updates TerraOnion header fields (--name, --manufacturer, --year, --genre, --ngh, --screenshot). At least one flag is required. Use --out / -o to write a copy; omit it to overwrite the input file atomically.
  • GUI: New Edit (.neo) tab (after Extract): pick input .neo, optional output path, same metadata fields as Pack. Fields load from the file header (first 4 KiB only, debounced). Write metadata saves all fields to the header; P/S/M/V/C data is unchanged.
  • Core: parse_neo_header_metadata(), replace_neo_metadata(), and write_bytes_atomic() support the above.

Changes

  • GUI tab order: Pack → Extract → Edit → Info (Pack is first).
  • Info / format_info: Screenshot # is shown; NGH is shown as decimal only (hex suffix removed).
  • Pack tab: Parser warnings go to the tab log (not stderr); duplicate warnings between auto-swap probe and pack are deduplicated; progress bars replaced with a compact busy spinner.
  • GUI: Tab form values are no longer persisted to disk via config helpers; related reset/legacy config behavior was removed or simplified.

Removed

  • Verify (roundtrip): Removed from the GUI and the neoconv verify CLI subcommand. verify_roundtrip remains in the core library for unit tests.

1.0.5

Choose a tag to compare

@github-actions github-actions released this 12 May 14:27

GUI

  • Extract: “Files” section uses a consistent two-column grid; path rows align with the ZIP/directory radio options; minor padding and sticky tweaks.
  • Pack: Status line wraps using wraplength tied to the allocated column width, so longer messages no longer widen the window (and we avoid a fixed character width that bloated the default size).
  • General layout polish (label frames, log height, shared section label widths) plus README updates for install/GUI notes.

Pack / ROM handling

  • MAME sets with no physical s1 ROM (e.g. parent svc): a synthetic zero-filled S region is inserted to mirror MAME’s fixed-area fill, so Pack no longer fails with a bogus “Missing S”.
  • Synthetic S size aligned with the software list: 512 KiB for the known PCB ROM ID prefixes 253, 256, 257, 263, 266, 269, 271 (including names like 271-c1c.c1), 256 KiB for kf10- (KOF 10th bootleg style), otherwise the usual 128 KiB; broader detection of C1-style sprite filenames (e.g. mart-c1.bin, kf10-c1a.bin).

Development / repository

  • Tests: more CLI/core coverage; renamed/trimmed tests.
  • .gitignore: coverage artifacts (.coverage, htmlcov/, etc.).

Note
If you only use the CLI and never pack “no s1” MAME parents, most user-visible changes are GUI and docs; the ROM changes matter mainly for those encrypted / no-s1 parent sets.

1.0.4

Choose a tag to compare

@github-actions github-actions released this 11 May 10:36

P-ROM Bank Swap Auto-Detection

The --swap-p option now defaults to auto. neoconv inspects the M68000
exception-vector table in both 1 MB halves of a 2 MB P-ROM and automatically
determines whether a half-swap is needed — no manual guesswork required for
unknown dumps or hacks. The result is printed as a diagnostic line during
packing. Manual override remains available via --swap-p yes or --swap-p no.

A new detect-swap subcommand allows inspecting a P-ROM or MAME ZIP without
packing it:

neoconv detect-swap mygame.zip

GUI — Major Overhaul

Drag and drop
All file input fields accept drag and drop. Drop a .neo file or MAME ZIP
directly onto any tab — no need to use the file browser.

Progress bar and Cancel
Extract, Pack, and Verify tabs each show a progress bar and a Cancel button.
All operations run in a background thread — the UI stays responsive during
long operations. Cancel requests are handled at the next safe checkpoint.

Real-time input validation (Pack tab)
The Pack tab continuously validates all inputs and shows a colour-coded status
line below the controls:

  • Missing or invalid input path
  • Non-integer values for Year, NGH, Screenshot
  • Missing required ROM roles (P, S, M) detected by scanning the ZIP or
    directory in the background — with debouncing so it does not re-scan on
    every keystroke

Metadata field byte-limit enforcement
Name is hard-limited to 32 bytes and Manufacturer to 16 bytes (latin-1
encoded), matching the .neo header format. Characters beyond the limit are
rejected immediately while typing rather than silently truncated at pack time.

P-ROM swap radio (Pack tab)
The P-ROM bank swap option is now a three-way radio button:
Auto-detect (default) / Yes / No.

Settings persistence
All tab inputs, format selections, C chip size, swap mode, and window geometry
are saved on close and restored on next launch. Settings are stored in the
platform-appropriate config directory:

Windows : %APPDATA%\neoconv\config.json
macOS : ~/Library/Application Support/neoconv/config.json
Linux : ~/.config/neoconv/config.json

Reset all tabs
A "Reset all tabs" button in the toolbar restores all inputs to their defaults.
Blocked while an operation is running.

Extract output mode
Extract tab now offers a choice between ZIP output and directory output.

Darksoft format support
MAME and Darksoft output formats are selectable via radio button in Extract
and Verify tabs.

Resizable window
The main window is now resizable so the log area can grow as needed.

Prebuilt Binaries

Native GUI binaries are now provided for Windows, macOS, and Linux on the
Releases page. No Python installation required.

Windows : neoconv-gui-x.y.z-windows.exe — run directly
macOS : neoconv-gui-x.y.z-macos.zip — unzip, double-click .app
(first launch: right-click -> Open to bypass Gatekeeper)
Linux : neoconv-gui-x.y.z-linux — chmod +x, then run

CLI

  • detect-swap subcommand added
  • --swap-p accepts auto (default), yes, no
  • verify output uses consistent [OK] / [ERROR] / [WARN] markers throughout