Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug]: ModuleNotFoundError: No module named 'playwright._repo_version' #2707

Open
xiaoscofield opened this issue Jan 4, 2025 · 0 comments
Open

Comments

@xiaoscofield
Copy link

Version

1.49

Steps to reproduce

Example steps (replace with your own):

  1. Clone my repo at https://github.com//example
  2. conda create -n Playwright2 python=3.10 -y
  3. conda activate Playwright2
  4. conda config --add channels conda-forg
  5. conda config --add channels microsoft
  6. conda install pytest-playwright
  7. playwright install
  8. You should see the error come up , ModuleNotFoundError: No module named 'playwright._repo_version'

Expected behavior

I expected that the program works well. but now the program is terminated by the bug.

Actual behavior

Traceback (most recent call last):
File "E:\Github_model\Playwright\playwright-python-main\Test_liepin.py", line 2, in
from playwright.sync_api import Playwright, sync_playwright, expect
File "E:\Github_model\Playwright\playwright-python-main\playwright\sync_api_init_.py", line 25, in
import playwright.sync_api._generated
File "E:\Github_model\Playwright\playwright-python-main\playwright\sync_api_generated.py", line 21, in
from playwright._impl._accessibility import Accessibility as AccessibilityImpl
File "E:\Github_model\Playwright\playwright-python-main\playwright_impl_accessibility.py", line 17, in
from playwright._impl._connection import Channel
File "E:\Github_model\Playwright\playwright-python-main\playwright_impl_connection.py", line 44, in
from playwright._impl._transport import Transport
File "E:\Github_model\Playwright\playwright-python-main\playwright_impl_transport.py", line 24, in
from playwright._impl._driver import compute_driver_executable, get_driver_env
File "E:\Github_model\Playwright\playwright-python-main\playwright_impl_driver.py", line 22, in
from playwright._repo_version import version
ModuleNotFoundError: No module named 'playwright._repo_version'

Additional context

I tried to use virtualenv, but it also failed.

Environment

- Operating System: [windows 11]
- CPU: [intel(R) Xeon(R) Gold 5117]
- Browser: [All, Chromium, Firefox, WebKit]
- Python Version: [3.10]
- Other info:
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

No branches or pull requests

1 participant