QL-Win / QL-Win/QuickLook

Crash when previewing audio files (FLAC, MP3)

Open
#1,700 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
24.7k
Forks
1.3k
Avg merge
4d 7h
Merged PRs (30d)
1

Description

For all's convenience, please use English to fill this issue.

Please search within existing issues before the submission. Has this issue already been reported?
I have found the previous issues which is related. The related one is #1693. #1693 is caused by the config file, but this is not cause by this.

Describe the bug
When previewing an audio file, it will crash or show the error information.

To Reproduce

  1. Get a music in format of flac or mp3
  2. Press the Space key, and you will see the problem

Expected behavior
It should play music instead of get crash.

Desktop (please complete the following information):

  • OS Version: Windows 11 Pro 24H2 26100.1742 (Windows Feature Experience Pack 1000.26100.18.0)
  • QuickLook Version 1: 4.0.2.0 (UWP) from MS Store
  • QuickLook Version 2: 4.1.0-78-g55a0690 from latest release

Screenshots and Exception Log

  • I don't install any plugin in the QuickLook.

Store Ver:

QuickLook - 李荣浩 - 李白.flac v4.0.2.0
2025/7/18 8:19:04 Windows 10.0.26100.2
System.Xaml.XamlObjectWriterException: 设置属性“System.Windows.ResourceDictionary.Source”时引发了异常。 ---> System.IO.FileNotFoundException: 未能加载文件或程序集“WPFMediaKit, Culture=neutral”或它的某一个依赖项。系统找不到指定的文件。
   在 System.Reflection.RuntimeAssembly._nLoad(AssemblyName fileName, String codeBase, Evidence assemblySecurity, RuntimeAssembly locationHint, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   在 System.Reflection.RuntimeAssembly.InternalLoadAssemblyName(AssemblyName assemblyRef, Evidence assemblySecurity, RuntimeAssembly reqAssembly, StackCrawlMark& stackMark, IntPtr pPrivHostBinder, Boolean throwOnFileNotFound, Boolean forIntrospection, Boolean suppressSecurityChecks)
   在 System.Reflection.Assembly.Load(AssemblyName assemblyRef)
   在 System.Windows.Navigation.BaseUriHelper.GetLoadedAssembly(String assemblyName, String assemblyVersion, String assemblyKey)
   在 MS.Internal.AppModel.ResourceContainer.GetResourceManagerWrapper(Uri uri, String& partName, Boolean& isContentFile)
   在 MS.Internal.AppModel.ResourceContainer.GetPartCore(Uri uri)
   在 System.IO.Packaging.Package.GetPartHelper(Uri partUri)
   在 System.IO.Packaging.Package.GetPart(Uri partUri)
   在 System.IO.Packaging.PackWebResponse.CachedResponse.GetResponseStream()
   在 System.IO.Packaging.PackWebResponse.get_ContentType()
   在 MS.Internal.WpfWebRequestHelper.GetContentType(WebResponse response)
   在 System.Windows.ResourceDictionary.set_Source(Uri value)
   在 MS.Internal.Xaml.Runtime.ClrObjectRuntime.SetValue(Object inst, XamlMember property, Object value)
   --- 内部异常堆栈跟踪的结尾 ---
   在 MS.Internal.Xaml.Runtime.ClrObjectRuntime.SetValue(Object inst, XamlMember property, Object value)
   在 MS.Internal.Xaml.Runtime.PartialTrustTolerantRuntime.SetValue(Object obj, XamlMember property, Object value)
   在 System.Xaml.XamlObjectWriter.Logic_ApplyPropertyValue(ObjectWriterContext ctx, XamlMember prop, Object value, Boolean onParent)
   在 System.Xaml.XamlObjectWriter.Logic_DoAssignmentToParentProperty(ObjectWriterContext ctx)
   在 System.Xaml.XamlObjectWriter.Logic_AssignProvidedValue(ObjectWriterContext ctx)
   在 System.Xaml.XamlObjectWriter.WriteEndMember()
   在 System.Xaml.XamlServices.Transform(XamlReader xamlReader, XamlWriter xamlWriter, Boolean closeWriter)
   在 System.Windows.SystemResources.ResourceDictionaries.LoadDictionary(Assembly assembly, String assemblyName, String resourceName, Boolean isTraceEnabled, Uri& dictionarySourceUri)
   在 System.Windows.SystemResources.ResourceDictionaries.LoadGenericDictionary(Boolean isTraceEnabled)
   在 System.Windows.SystemResources.FindDictionaryResource(Object key, Type typeKey, ResourceKey resourceKey, Boolean isTraceEnabled, Boolean allowDeferredResourceReference, Boolean mustReturnDeferredResourceReference, Boolean& canCache)
   在 System.Windows.SystemResources.FindResourceInternal(Object key, Boolean allowDeferredResourceReference, Boolean mustReturnDeferredResourceReference)
   在 MS.Internal.Helper.FindTemplateResourceFromAppOrSystem(DependencyObject target, ArrayList keys, Int32 exactMatch, Int32& bestMatch)
   在 System.Windows.FrameworkElement.FindTemplateResourceInternal(DependencyObject target, Object item, Type templateType)
   在 System.Windows.Controls.ContentPresenter.DefaultSelector.SelectTemplate(Object item, DependencyObject container)
   在 System.Windows.Controls.ContentPresenter.ChooseTemplate()
   在 System.Windows.Controls.ContentPresenter.EnsureTemplate()
   在 System.Windows.Controls.ContentPresenter.OnPreApplyTemplate()
   在 System.Windows.FrameworkElement.ApplyTemplate()
   在 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   在 System.Windows.UIElement.Measure(Size availableSize)
   在 System.Windows.Controls.Border.MeasureOverride(Size constraint)
   在 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   在 System.Windows.UIElement.Measure(Size availableSize)
   在 System.Windows.Controls.Control.MeasureOverride(Size constraint)
   在 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   在 System.Windows.UIElement.Measure(Size availableSize)
   在 MS.Internal.Helper.MeasureElementWithSingleChild(UIElement element, Size constraint)
   在 System.Windows.Controls.ContentPresenter.MeasureOverride(Size constraint)
   在 System.Windows.FrameworkElement.MeasureCore(Size availableSize)
   在 System.Windows.UIElement.Measure(Size availableSize)
   在 System.Windows.ContextLayoutManager.UpdateLayout()
   在 System.Windows.ContextLayoutManager.UpdateLayoutCallback(Object arg)
   在 System.Windows.Media.MediaContext.FireInvokeOnRenderCallbacks()
   在 System.Windows.Media.MediaContext.RenderMessageHandlerCore(Object resizedCompositionTarget)
   在 System.Windows.Media.MediaContext.RenderMessageHandler(Object resizedCompositionTarget)
   在 System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   在 System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

MSI Ver:
Image

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing Space-key preview for FLAC and MP3 on Windows, then inspect the exception showing that WPFMediaKit cannot be loaded during the preview. Compare the Store and MSI behavior described in the report; done means both formats play without a crash or assembly-loading error.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
desktop
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.