Skip to content

Terminal reports the invalid "icon" message after export and import a WSL distro #19124

@chansey97

Description

@chansey97

Windows Terminal version

1.22.11141.0

Windows build number

10.0.26100.4652

Other Software

WSL1
WSL2

Steps to reproduce

I was setting up multiple WSL distribution instances as the following method:

wsl --export Ubuntu ubuntu_base.tar
wsl --import Ubuntu_export1 e:/wsl/Ubuntu_export1 ./ubuntu_base.tar

The process of the export and import is successful and works fine.

Close the terminal and open it again.

The terminal popup a dialogue message:

Found a profile with an invalid "icon". 
Defaulting that profile to have no icon. Make sure that when setting an "icon", the value is a valid file path to an image.

Reason

Open the terminal settings, the Ubuntu_export1 profile (which was generated automatically) shows that:

Icon \\?\E:\wsl\Ubuntu_export1\shortcut.ico

Workaround

Modify

Icon \\?\E:\wsl\Ubuntu_export1\shortcut.ico

to

Icon E:\wsl\Ubuntu_export1\shortcut.ico

Then everything is OK

P.S. Both WSL1 and WSL2 distribution has the same problem.

Expected Behavior

No the dialogue message.

Actual Behavior

The terminal popup a dialogue message:

Found a profile with an invalid "icon". 
Defaulting that profile to have no icon. Make sure that when setting an "icon", the value is a valid file path to an image.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Issue-BugIt either shouldn't be doing this or needs an investigation.Resolution-DuplicateThere's another issue on the tracker that's pretty much the same thing.

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions