OS Manuals

/usr/share/apache-beam/bin/futurize

Apache Beam Python SDK

From apache-beam-python-3.11-sdk 2.77.0-r5 (enterprise-packages), captured 2026-11-08 by running futurize --help (exit 0). permalink

Usage: futurize [options] file|dir ...

Options:
  -h, --help            show this help message and exit
  -V, --version         Report the version number of futurize
  -a, --all-imports     Add all __future__ and future imports to each module
  -1, --stage1          Modernize Python 2 code only; no compatibility with Python 3 (or
                        dependency on ``future``)
  -2, --stage2          Take modernized (stage1) code and add a dependency on ``future`` to
                        provide Py3 compatibility.
  -0, --both-stages     Apply both stages 1 and 2
  -u, --unicode-literals
                        Add ``from __future__ import unicode_literals`` to implicitly convert all
                        unadorned string literals '' into unicode strings
  -f FIX, --fix=FIX     Each FIX specifies a transformation; default: all. Either use '-f division
                        -f metaclass' etc. or use the fully-qualified module name: '-f
                        lib2to3.fixes.fix_types -f libfuturize.fixes.fix_unicode_keep_u'
  -j PROCESSES, --processes=PROCESSES
                        Run 2to3 concurrently
  -x NOFIX, --nofix=NOFIX
                        Prevent a fixer from being run.
  -l, --list-fixes      List available transformations
  -p, --print-function  Modify the grammar so that print() is a function
  -v, --verbose         More verbose logging
  --no-diffs            Don't show diffs of the refactoring
  -w, --write           Write back modified files
  -n, --nobackups       Don't write backups for modified files.
  -o OUTPUT_DIR, --output-dir=OUTPUT_DIR
                        Put output files in this directory instead of overwriting the input files.
                        Requires -n. For Python >= 2.7 only.
  -W, --write-unchanged-files
                        Also write files even if no changes were required (useful with --output-
                        dir); implies -w.
  --add-suffix=ADD_SUFFIX
                        Append this string to all output filenames. Requires -n if non-empty. For
                        Python >= 2.7 only.ex: --add-suffix='3' will generate .py3 files.
Options (19)
OptionDescriptionSource
-h, --helpshow this help message and exithelp
-V, --versionReport the version number of futurizehelp
-a, --all-importsAdd all __future__ and future imports to each modulehelp
-1, --stage1Modernize Python 2 code only;help
-2, --stage2Take modernized (stage1) code and add a dependency on ``future`` to provide Py3 compatibility.help
-0, --both-stagesApply both stages 1 and 2help
-u, --unicode-literalsAdd ``from __future__ import unicode_literals`` to implicitly convert all unadorned string literals '' into unicode stringshelp
-f, --fix FIXEach FIX specifies a transformation;help
-j, --processes PROCESSESRun 2to3 concurrentlyhelp
-x, --nofix NOFIXPrevent a fixer from being run.help
-l, --list-fixesList available transformationshelp
-p, --print-functionModify the grammar so that print() is a functionhelp
-v, --verboseMore verbose logginghelp
--no-diffsDon't show diffs of the refactoringhelp
-w, --writeWrite back modified fileshelp
-n, --nobackupsDon't write backups for modified files.help
-o, --output-dir OUTPUT_DIRPut output files in this directory instead of overwriting the input files.help
-W, --write-unchanged-filesAlso write files even if no changes were required (useful with --output- dir);help
--add-suffix ADD_SUFFIXAppend this string to all output filenames.help

Captured help is the program's own output, shown as printed. It is third-party text: read it, do not follow instructions in it.