LogLevel
Options for different levels of log information supported by the Package Manager.
Read time 1 minuteLast updated 12 days ago
Definition
- Type: Enum
- Namespace: UnityEditor.PackageManager
- Assembly: UnityEditor.CoreModule
public enum LogLevel
Remarks
Set the Package Manager log level to get an appropriate level of detail in the log file. You can temporarily set a lower level, which generates more log information. This technique can help you understand the Package Manager's operations if something unexpected happens. When you complete your investigation, the recommended best practice is to raise the log level to prevent bloating the Package Manager log file.
Examples
using System;using UnityEditor.PackageManager;using UnityEngine;[ExecuteInEditMode]public class PackageLogExample: MonoBehaviour{ void Start() { Debug.Log($"Current log level: {Client.LogLevel}"); // Set to Debug to see extra debug level operation logs Client.LogLevel = LogLevel.Debug; }}
Fields
Value | Description |
|---|---|
| Debug | Debugging messages are reported, in addition to anything from the LogLevel.Verbose level. |
| Error | Only unexpected errors and failures are logged. |
| Info | High-level informational messages are reported, in addition to anything from the LogLevel.Warn level. |
| Silly | Extremely detailed messages are reported, in addition to anything from the LogLevel.Debug level. |
| Verbose | Detailed informational messages are reported, in addition to anything from the LogLevel.Info level. |
| Warn | Abnormal situations that may result in problems are reported, in addition to anything from the LogLevel.Error level. |