Skip to content

Passing both --fixed and --target-pages silently ignores --target-pages #8

Description

@adisakshya

Context

split_book.py, main().

Problem

If a user passes both --fixed N and --target-pages M, --fixed silently wins (if args.fixed is not None: ...) and --target-pages is dropped with no indication to the user that it was ignored.

Reproduction

  1. python split_book.py book.pdf --fixed 3 --target-pages 100 --list
  2. Output is a plain fixed-window plan; nothing mentions that --target-pages 100 was ignored. Confirmed.

Expected

Either reject the combination with a clear error ("--fixed and --target-pages are mutually exclusive"), or print an explicit note that --target-pages is being ignored because --fixed takes precedence.

Actual

Silent, undocumented precedence with no feedback.

Acceptance criteria

  • Passing both flags together produces either a clear rejection or an explicit stdout/stderr note about which one is being used.
  • Regression test added.
  • README/--help text documents the interaction.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions