Skip to content
Permalink

Comparing changes

Choose two branches to see what’s changed or to start a new pull request. If you need to, you can also or learn more about diff comparisons.

Open a pull request

Create a new pull request by comparing changes across two branches. If you need to, you can also . Learn more about diff comparisons here.
base repository: nvidia-riva/python-clients
Failed to load repositories. Confirm that selected base ref is valid, then try again.
Loading
base: main
Choose a base ref
...
head repository: atomer-nvidia/python-clients
Failed to load repositories. Confirm that selected head ref is valid, then try again.
Loading
compare: main
Choose a head ref
Checking mergeability… Don’t worry, you can still create the pull request.
  • 2 commits
  • 11 files changed
  • 2 contributors

Commits on Jun 30, 2026

  1. Wire cli_main into asr/nmt/tts client scripts and tighten input valid…

    …ation
    
    Address the VDR 26.02 finding that python-clients CLIs exit 0 on most
    error paths across all three modalities. Each script now:
    
      - Wraps main() with @cli_main so gRPC and OS errors propagate to a
        real exit code instead of being printed and swallowed.
      - Calls sys.exit(main()) so the chosen exit code reaches the shell.
    
    Script-specific fixes:
    
      scripts/nmt/nmt.py
        - Drop the inner request() try/except that swallowed every gRPC
          status; let cli_main translate it. Empty/whitespace --text and
          missing --text-file now return EXIT_BAD_INPUT (was: silent
          exit 0). Document --max-len-variation as decoder-token units
          with valid range [0, 256], default 20, and Arabic chunking note.
    
      scripts/tts/talk.py
        - Reject whitespace-only --text up front (defense-in-depth pair to
          the server-side fix in riva-speech that closed the hang on
          `--text "   "`). Drop the broad `except Exception` that
          stringified gRPC errors and exited 0.
    
      scripts/asr/transcribe_file*.py
        - Replace `print(...); return` on missing input files with
          EXIT_BAD_INPUT. Remove the silent grpc.RpcError swallow in
          transcribe_file_offline.py.
    
      scripts/asr/transcribe_mic.py + realtime_asr_client.py + tts/talk.py
        - Pyaudio install hint now mentions `apt-get install -y
          portaudio19-dev` (Debian/Ubuntu) and `brew install portaudio`
          (macOS), pairing with the prereqs doc landed in documentation_2.
    
      scripts/tts/realtime_tts_client.py
        - Drop the module-level `from riva.client.audio_io import
          SoundCallBack` import (it was unused and pulled pyaudio in
          eagerly, defeating the lazy import). Drop the broad
          `except Exception` that mapped every failure to exit 1.
    
      scripts/nmt/nmt_speech_to_{text,speech}.py
        - Drop unused `import grpc`; remove the catch-all that printed
          "Error during translation" and exited 0.
    
    Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
    atomer-nvidia and claude committed Jun 30, 2026
    Configuration menu
    Copy the full SHA
    0d91b3e View commit details
    Browse the repository at this point in the history
  2. fix: clear voice_name when --voice omitted in realtime TTS client

    When no --voice is passed, the server was receiving voice_name='' from
    the fresh session payload but missing the explicit empty string, causing
    it to retain its initialization default ('English-US.Male-1') which isn't
    a valid voice on magpie-tts-multilingual.
    
    Fixes NVBug 6261715.
    
    Co-Authored-By: Claude Sonnet 4.6 (1M context) <[email protected]>
    atomer-nvidia and claude committed Jun 30, 2026
    Configuration menu
    Copy the full SHA
    43c2461 View commit details
    Browse the repository at this point in the history
Loading