question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

whenever I run in debug mode windows are displayed outside my screen

See original GitHub issue

Context:

  • Playwright Version: 1.18
  • Operating System: Windows 11
  • Node.js version: 14.19
  • Browser: Chromium
  • Extra: Running in Ubuntu 20.04 in WSL2 from VSCode
## System:
 - OS: Linux 5.10 Ubuntu 20.04.2 LTS (Focal Fossa)
 - Memory: 2.36 GB / 7.73 GB
 - Container: Yes## System:
 - OS: Linux 5.10 Ubuntu 20.04.2 LTS (Focal Fossa)
 - Memory: 2.36 GB / 7.73 GB
 - Container: Yes
## Binaries:
 - Node: 14.19.0 - /usr/bin/node
 - npm: 8.4.1 - /usr/local/bin/npm
## Languages:
 - Bash: 5.0.17 - /usr/bin/bash
## Binaries:
 - Node: 14.19.0 - /usr/bin/node
 - npm: 8.4.1 - /usr/local/bin/npm
## Languages:
 - Bash: 5.0.17 - /usr/bin/bash

** config **

import { PlaywrightTestConfig } from '@playwright/test';
const config: PlaywrightTestConfig = {
//    testDir: './tests',
    /* Maximum time one test can run for. */
    timeout: 30 * 1000,
    /* Retry on CI only */
    retries: process.env.CI ? 2 : 0,
    /* Opt out of parallel tests on CI. */
    workers: process.env.CI ? 1 : undefined,
    globalTimeout: 60 * 60 * 1000,
    snapshotDir: './snapshots',
    reporter: process.env.CI ? 'html' : 'dot',
    use: {
        headless: true,
        baseURL: process.env.AZHOP_FQDN,
        viewport: { width: 1600, height: 900 },
        screenshot: 'only-on-failure',
        httpCredentials: {
            username: process.env.AZHOP_USER,
            password: process.env.AZHOP_PASSWORD
        },
        trace: 'on-first-retry',
    },
};
export default config;

Describe the bug

if I run my test in debug mode I can see the browser and the inspector windows in the task bar, but they can’t be moved or displayed on my screen. I’m using a dual screen, and even on a single screen it’s the same.

How to force the viewport to always start at the same position on the screen ?

Issue Analytics

  • State:open
  • Created 2 years ago
  • Comments:5 (2 by maintainers)

github_iconTop GitHub Comments

2reactions
kbarendrechtcommented, Jul 27, 2022

I understand this doesn’t help anyone with this issue, but for the sake of providing feedback: It works out the box for me with WSLg on Windows 11 👍🏻

0reactions
pkerschbaumcommented, Mar 13, 2022

WSL 2 has “native” GUI support for some time, it is called “WSLg”, see microsoft/wslg.
I use Playwright quite successfully with it, but the issue that the Window is not visible (even though the icon appears in the Windows taskbar) has also occured to me sometimes.

But this also happened with Cypress. I am pretty sure it is a WSLg issue, also considering that the workaround of @xpillons above switches from WSLg to a X-Server.
There are many issues regarding Window positioning/appearance in the microsoft/wslg repository, I think WSLg still just has some rough edges…

Read more comments on GitHub >

github_iconTop Results From Across the Web

Some Programs Are Displayed Off the Screen
Method 2 · Start the program. · Right-click the program on the taskbar, and then click Move. · Move the mouse pointer to...
Read more >
Debug Window Stuck off Screen
hi. I am having a problem with my debug window. When it is in floating mode, the top of the window is off-screen....
Read more >
Visual Studio Dual Monitor Layout : Watch/Debug Window ...
Start 'debug' your project · Move the desired windows(watch/debug) to the 2nd monitor on right · Goto Tools>Import and Export Settings>Export selected environment ......
Read more >
call stack window off screen cant move it
Make sure the window is in focus (you may use Ctrl+Tab to select it). · Press Alt+Space to open the window context menu....
Read more >
Application running in debug mode in the test environment not ...
The only workaround is to use an external browser. You can set an external browser by going to Windows > Preferences > Internet...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found