Skip to content

Remove Linux-only PyGObject and qtpy from requirements.txt#65

Open
AlizerUncaged wants to merge 1 commit into
D-Ogi:mainfrom
AlizerUncaged:fix/remove-linux-only-deps
Open

Remove Linux-only PyGObject and qtpy from requirements.txt#65
AlizerUncaged wants to merge 1 commit into
D-Ogi:mainfrom
AlizerUncaged:fix/remove-linux-only-deps

Conversation

@AlizerUncaged

@AlizerUncaged AlizerUncaged commented Mar 16, 2026

Copy link
Copy Markdown

Summary

  • Removed PyGObject and qtpy from requirements.txt
  • These are Linux-only dependencies for pywebview's GTK/Qt backend
  • On Windows, pywebview uses WebView2, and these packages fail to build from source during setup.bat / setup.ps1, breaking installation

Error on Windows

Running setup.ps1 or setup.bat fails with:

ERROR: Exception:
Traceback (most recent call last):
  File "...\pip\_internal\cli\base_command.py", line 107, in _run_wrapper
    status = _inner_run()
  File "...\pip\_internal\cli\base_command.py", line 98, in _inner_run
    return self.run(options, args)
  File "...\pip\_internal\commands\install.py", line 392, in run
    requirement_set = resolver.resolve(
  File "...\pip\_internal\resolution\legacy\resolver.py", line 184, in resolve
    discovered_reqs.extend(self._resolve_one(requirement_set, req))
  File "...\pip\_internal\resolution\legacy\resolver.py", line 506, in _resolve_one
    dist = self._get_dist_for(req_to_install)
  File "...\pip\_internal\resolution\legacy\resolver.py", line 459, in _get_dist_for
    dist = self.preparer.prepare_linked_requirement(req)
  File "...\pip\_internal\operations\prepare.py", line 542, in prepare_linked_requirement
    return self._prepare_linked_requirement(req, parallel_builds)
  File "...\pip\_internal\operations\prepare.py", line 657, in _prepare_linked_requirement
    dist = _get_prepared_distribution(
  File "...\pip\_internal\operations\prepare.py", line 77, in _get_prepared_distribution
    abstract_dist.prepare_distribution_metadata(
  File "...\pip\_internal\distributions\sdist.py", line 55, in prepare_distribution_metadata
    self._install_build_reqs(build_env_installer)
  File "...\pip\_internal\distributions\sdist.py", line 132, in _install_build_reqs
    build_reqs = self._get_build_requires_wheel()
  File "...\pip\_internal\distributions\sdist.py", line 107, in _get_build_requires_wheel
    return backend.get_requires_for_build_wheel()

PyGObject requires GTK development libraries and cannot build from source on Windows. qtpy is also unnecessary since pywebview uses WebView2/EdgeChromium on Windows, not GTK or Qt.

Test plan

  • Run setup.bat or setup.ps1 on Windows — should complete without errors
  • Run setup.sh on Linux — pywebview should still work (it installs GTK deps via system packages, not pip)
  • Launch the GUI with run.bat / run.sh and verify it opens correctly

These are Linux-only GTK/Qt dependencies needed for pywebview's GTK backend.
On Windows, pywebview uses WebView2 and these packages fail to build from
source, breaking the setup script.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant