          """
          import winpty  # pylint:disable=import-outside-toplevel,import-error
          # For some reason with WinPTY we need to pass in the full command. Probably a bug
          proc = winpty.PTY(
              80 if self._env.is_installer else 100,
              24,
              backend=winpty.enums.Backend.WinPTY,  # ConPTY hangs and has lots of Ansi Escapes
              agent_config=winpty.enums.AgentConfig.WINPTY_FLAG_PLAIN_OUTPUT)  # Strip all Ansi
  
          if not proc.spawn(self._cmd, cmdline=self._cmdline):
 
</s> remove         proc = pexpect.spawn(" ".join(self._command),
                             encoding=self._env.encoding, codec_errors="replace", timeout=None)
 </s> add         proc = pexpect.spawn(" ".join(self._command), timeout=None) </s> remove             if self._env.is_conda:
                if pkg.startswith("tensorflow-gpu"):
                    # From TF 2.4 onwards, Anaconda Tensorflow becomes a mess. The version of 2.5
                    # installed by Anaconda is compiled against an incorrect numpy version which
                    # breaks Tensorflow. Coupled with this the versions of cudatoolkit and cudnn
                    # available in the default Anaconda channel are not compatible with the
                    # official PyPi versions of Tensorflow. With this in mind we will pull in the
                    # required Cuda/cuDNN from conda-forge, and install Tensorflow with pip
                    # TODO Revert to Conda if they get their act together

                    # Rewrite tensorflow requirement to versions from highest available cuda/cudnn
                    highest_cuda = sorted(_TENSORFLOW_REQUIREMENTS.values())[-1]
                    compat_tf = next(k for k, v in _TENSORFLOW_REQUIREMENTS.items()
                                     if v == highest_cuda)
                    pkg = f"tensorflow-gpu{compat_tf}"
                    conda_only = True

 </s> add             if self._env.is_conda and not pip_only: </s> remove     model._download_model = cast(MagicMock, mocker.MagicMock())  # type:ignore
    model._unzip_model = cast(MagicMock, mocker.MagicMock())  # type:ignore
 </s> add     model._download_model = T.cast(MagicMock, mocker.MagicMock())  # type:ignore
    model._unzip_model = T.cast(MagicMock, mocker.MagicMock())  # type:ignore </s> remove     def _parse_lines(self) -> None:
        """ Process the latest batch of lines that have been received from winPTY. """
        for line in self._lines:  # Dump the output to log
            line = line.rstrip()
            is_cr = bool(self._pbar.search(line))
            if line and not is_cr:
                if self._last_line_cr:
                    self._last_line_cr = False
                    if not self._env.is_installer:
                        # Go to next line
                        self._non_gui_print("")
                self._seen_line_log(line)
            elif line:
                self._last_line_cr = True
                logger.debug(line)
                # NSIS only updates on line endings, so force new line for installer
                self._non_gui_print(line, end=None if self._env.is_installer else "\r")
        self._lines = []

 </s> add  </s> remove             retval = dict(alignments_file=[self._args.alignments_file],
                          faces_dir=[self._args.faces_dir],
                          frames_dir=[self._args.frames_dir])
 </s> add             retval = {"alignments_file": [self._args.alignments_file],
                      "faces_dir": [self._args.faces_dir],
                      "frames_dir": [self._args.frames_dir]}
            100,
          """
          import winpty  # pylint:disable=import-outside-toplevel,import-error
          # For some reason with WinPTY we need to pass in the full command. Probably a bug
          proc = winpty.PTY(
            100,
              24,
              backend=winpty.enums.Backend.WinPTY,  # ConPTY hangs and has lots of Ansi Escapes
              agent_config=winpty.enums.AgentConfig.WINPTY_FLAG_PLAIN_OUTPUT)  # Strip all Ansi
  
          if not proc.spawn(self._cmd, cmdline=self._cmdline):
keep keep keep keep replace keep keep keep keep keep
 Rebase code (#1326)

* Remove tensorflow_probability requirement

* setup.py - fix progress bars

* requirements.txt: Remove pre python 3.9 packages

* update apple requirements.txt

* update INSTALL.md

* Remove python<3.9 code

* setup.py - fix Windows Installer

* typing: python3.9 compliant

* Update pytest and readthedocs python versions

* typing fixes

* Python Version updates
  - Reduce max version to 3.10
  - Default to 3.10 in installers
  - Remove incompatible 3.11 tests

* Update dependencies

* Downgrade imageio dep for Windows

* typing: merge optional unions and fixes

* Updates
  - min python version 3.10
  - typing to python 3.10 spec
  - remove pre-tf2.10 code
  - Add conda tests

* train: re-enable optimizer saving

* Update dockerfiles

* Update setup.py
  - Apple Conda deps to setup.py
  - Better Cuda + dependency handling

* bugfix: Patch logging to prevent Autograph errors

* Update dockerfiles

* Setup.py - Setup.py - stdout to utf-8

* Add more OSes to github Actions

* suppress mac-os end to end test 
setup.py