schema_version: 1

context:
  version: "0.20.1"
  python_min: "3.10"

package:
  name: remove-ai-watermarks
  version: ${{ version }}

source:
  url: https://pypi.org/packages/source/r/remove-ai-watermarks/remove_ai_watermarks-${{ version }}.tar.gz
  sha256: da2370d8b3a8386a2b0483e7bea6bb3c218b2e65cab5fab289eed9ea26c75014

build:
  noarch: python
  number: 0
  script: python -m pip install . -vv --no-deps --no-build-isolation

requirements:
  host:
    - python ${{ python_min }}.*
    - pip
    - hatchling
  run:
    - python >=${{ python_min }}
    - pillow >=10.0.0
    - pillow-heif >=0.13.0
    - piexif >=1.1.3
    - numpy >=1.24.0
    - py-opencv >=4.8.0
    - click >=8.0.0
    - python-dotenv >=1.0.0
    # c2pa-python is a core PyPI dependency but is not packaged on conda-forge.
    # The guarded import falls back to the built-in C2PA byte scanner when it is
    # absent. Add it here once a c2pa-python feedstock exists.

tests:
  - python:
      imports:
        - remove_ai_watermarks
        - remove_ai_watermarks.identify
        - remove_ai_watermarks.metadata
      python_version: ${{ python_min }}.*
      # pip_check defaults to true; disable it explicitly. `pip check` fails on
      # the conda-forge piexif `py_2` build, whose stale 2019 metadata pip reads
      # as "piexif 1.1.3 is not supported on this platform" -- even though the
      # package installs, imports, and works. The imports test verifies loading.
      pip_check: false

about:
  homepage: https://github.com/wiltodelta/remove-ai-watermarks
  summary: Remove visible and invisible AI watermarks from images
  description: |
    Detect and remove registered visible AI-provenance marks and strip
    AI-provenance metadata (C2PA, EXIF, IPTC, and PNG text chunks) from images.
    The core package covers the identify, metadata, visible, and erase command
    surface. Optional pip extras add SynthID diffusion removal and additional
    invisible-watermark detectors.
  license: Apache-2.0
  license_file: LICENSE
  repository: https://github.com/wiltodelta/remove-ai-watermarks

extra:
  recipe-maintainers:
    - wiltodelta
