Skip to content

Trouble Shooting

sung-su.kim edited this page Mar 29, 2024 · 17 revisions

Trouble Shooting

If you encounter problems when installing Tizen workload, you need to check the following:

Run PowerShell as Administrator

  • This scripts needs to be installed with admin rights.

Check PowerShellsecurity policy

  • RemoteSigned or higher ExecutionPolicy is required for this script execution. Or, UnauthorizedAccess, not digitally signed error will be occured.
about_Execution_Policies(https://go.microsoft.com/fwlink/?LinkID=135170)를 참조하십시오.
위치 줄:1 문자:1
+ .\workload-install.ps1
+ ~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : 보안 오류: (:) [], PSSecurityException
    + FullyQualifiedErrorId : UnauthorizedAccess

PS > Set-ExecutionPolicy RemoteSigned
PS > Get-ExecutionPolicy
  RemoteSigned

DOTNET_ROOT environment variable

  • If dotnet sdk is not installed in the default path, it is necessary to set the $DOTNET_ROOT environment variable as the installation path.

Visual Studio Tizen extension

  • After you install the Visual Studio 2022 tools for Tizen extension, you need admin rights to install the Tizen workload at the first run.

Uninstall Tizen workload

  • using dotnet command with workload ID
PS > dotnet --version
  7.0.302
PS > dotnet workload list
  설치된 워크로드 ID           매니페스트 버전               설치 원본
  --------------------------------------------------------------
  tizen                 7.0.114/7.0.300        SDK 7.0.300
PS > dotnet workload uninstall tizen
  tizen에 대한 워크로드 설치 레코드를 제거하는 중...
  워크로드를 제거함: tizen
  • Remove workload manifest directory C:\Program Files\dotnet\sdk-manifests\7.0.300\samsung.net.sdk.tizen
  • Depending on the installed dotnet sdk version, the installed manifest directory path may be dirrerent.
    • C:\Program Files\dotnet\sdk-manifests\6.0.400\samsung.net.sdk.tizen
    • C:\Program Files\dotnet\sdk-manifests\7.0.300\samsung.net.sdk.tizen

BadImageFormatException

In case you face a BadImageFormatException like below. You need to set a proper RuntimeIdentifier on your csproj.

E/DOTNET_LAUNCHER(11568): log.cc: stdErrRedirect(120) > Unhandled exception.
E/DOTNET_LAUNCHER(11568): log.cc: stdErrRedirect(120) > System.BadImageFormatException: Could not load file or assembly '/opt/usr/apps/com.companyname.HelloMaui/bin/HelloMaui.dll'. An attempt was made to load a program with an incorrect format.

The default RuntimeIdentifier for Tizen is tizen-x86, and you can modify it on your csproj to build tpk for device targets.

<PropertyGroup Condition="$(TargetFramework.Contains('-tizen'))">    
    <RuntimeIdentifier>tizen-armel</RuntimeIdentifier>
</PropertyGroup>

Workload installation fail

When you try to install a new workload, if the installation fails due to the tizen workload, you can use --skip-manifest-update option.

PS > dotnet workload install [workload ID] --skip-manifest-update

Invoke-WebRequest fail

When you try to excute Invoke-WebRequest on PowerShell,

Invoke-WebRequest : 요청이 중단되었습니다. SSL/TLS 보안 채널을 만들 수 없습니다.
or
The request was aborted: Could not create SSL/TLS secure channel.

PS> [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
PS> Invoke-WebRequest 'https://raw.githubusercontent.com/Samsung/Tizen.NET/main/workload/scripts/workload-install.ps1' -OutFile 'workload-install.ps1';

Multiple dotnet sdks

If multiple dotnet SDKs are installed, a conflict may occur in installing the workload.

PS> dotnet --list-sdks
6.0.xxx [C:\Program Files\dotnet\sdk]
7.0.xxx [C:\Program Files\dotnet\sdk]
8.0.xxx [C:\Program Files\dotnet\sdk]

The following options are available for installing the workload.

PS> ./workload-install.ps1 -u // Install the workload on all SDKs.
or
PS> ./workload-install.ps1 -t [dotnet-sdk-version] // Receive an dotnet sdk version and install the appropriate workload.

Linux proxy

Failure to unzip during installation

[10:20:34] Downloading workload install script...
[10:20:34] workload install script download completed
[11:21:00] Installing Dotnet workload started...
[11:25:22] Installing done!
[11:25:22] [sudo] password for test: Check Tizen Workload for sdk 8.0.202.
Return cached latest version: 8.0.145
Installing samsung.net.sdk.tizen.manifest-8.0.200/8.0.145 to /home/test/.dotnet/sdk-manifests/8.0.200...
unzip:  cannot find or open /tmp/tmp.mueladk6T0/manifest.zip, /tmp/tmp.mueladk6T0/manifest.zip.zip or /tmp/tmp.mueladk6T0/manifest.zip.ZIP.
No such files to install.
DONE

The following options need to be added to the curl command. e,g,) --proxy http://10.112.1.184:8080