Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The FabCon + SQLCon recap series starts April 14th at 8am Pacific. If you’re tracking where AI is going inside Fabric, this first session is a can't miss. Register now

Reply
pfurbish
Frequent Visitor

Bug: Folder.Content exception

A SharePoint Folder.Content operation is throwing an exception. The query has been working for many months.  Recently, additional sub-folders were added to the root folder and now the query fails.  Below is the error information.  Any help is appreciated.

 

Paul

 

Feedback Type:
Frown (Error)

Timestamp:
2020-06-07T11:25:54.7875261Z

Local Time:
2020-06-07T07:25:54.7875261-04:00

Session ID:
c359dfda-df2a-4f25-adf2-60e7a2de601c

Release:
May 2020

Product Version:
2.81.5831.821 (20.05) (x64)

Stack Trace:
Microsoft.Mashup.Evaluator.Interface.ErrorException: Value cannot be null.
Parameter name: key ---> System.ArgumentNullException: Value cannot be null.
Parameter name: key ---> System.ArgumentNullException: Value cannot be null.
Parameter name: key
at System.ThrowHelper.ThrowArgumentNullException(ExceptionArgument argument)
at System.Collections.Generic.Dictionary`2.Insert(TKey key, TValue value, Boolean add)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointQueryBuilder..ctor(String query)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointQueryBuilder.GetPath(String query)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointUrlBuilder..ctor(String url, SharePointApiVersion version)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointTableValue.CreateFromFeedRecord(SharePointUrlBuilder urlBuilder, SharePointEnvironment environment, RecordValue feedRecord)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointTableValue.SharePointFeedEnumerator.CreateFolderRecord(RecordValue feedRecord)
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointTableValue.SharePointFeedEnumerator.MoveNext()
at Microsoft.Mashup.Engine1.Library.SharePoint.SharePointTableValue.SharePointTableEnumerator.MoveNext()
at Microsoft.Mashup.Evaluator.SimpleDocumentEvaluator.ValuePreviewValueSource.TableValuePreviewValueSource.SerializeRows(Int32 count)
at Microsoft.Mashup.Evaluator.SimpleDocumentEvaluator.ValuePreviewValueSource.TableValuePreviewValueSource.get_SmallValue()
at Microsoft.Mashup.Evaluator.Interface.TracingPreviewValueSource.get_SmallValue()
at Microsoft.Mashup.Evaluator.RemotePreviewValueSource.<>c__DisplayClass0_0.<RunStub>b__0()
at Microsoft.Mashup.Evaluator.EvaluationHost.ReportExceptions(IHostTrace trace, IEngineHost engineHost, IMessageChannel channel, Action action)
--- End of inner exception stack trace ---
at Microsoft.Mashup.Evaluator.EvaluationHost.<>c__DisplayClass11_0.<TryReportException>b__1()
at Microsoft.Mashup.Common.SafeExceptions.IgnoreSafeExceptions(IEngineHost host, IHostTrace trace, Action action)
at Microsoft.Mashup.Evaluator.EvaluationHost.TryReportException(IHostTrace trace, IEngineHost engineHost, IMessageChannel channel, Exception exception)
at Microsoft.Mashup.Evaluator.EvaluationHost.ReportExceptions(IHostTrace trace, IEngineHost engineHost, IMessageChannel channel, Action action)
at Microsoft.Mashup.Evaluator.RemotePreviewValueSource.RunStub(IEngineHost engineHost, IMessageChannel channel, Func`1 getPreviewValueSource)
at Microsoft.Mashup.Evaluator.RemoteDocumentEvaluator.Service.<>c__DisplayClass12_1`1.<OnBeginGetResult>b__0()
at Microsoft.Mashup.Evaluator.EvaluationHost.ReportExceptions(IHostTrace trace, IEngineHost engineHost, IMessageChannel channel, Action action)
at Microsoft.Mashup.Evaluator.RemoteDocumentEvaluator.Service.OnBeginGetResult[T](IMessageChannel channel, BeginGetResultMessage message, Action`1 action)
at Microsoft.Mashup.Evaluator.RemoteDocumentEvaluator.Service.OnBeginGetPreviewValueSource(IMessageChannel channel, BeginGetPreviewValueSourceMessage message)
at Microsoft.Mashup.Evaluator.MessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.ChannelMessenger.ChannelMessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.MessageHandlers.Dispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.ChannelMessenger.OnMessageWithUnknownChannel(IMessageChannel baseChannel, MessageWithUnknownChannel messageWithUnknownChannel)
at Microsoft.Mashup.Evaluator.MessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.ChannelMessenger.ChannelMessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.MessageHandlers.Dispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.EvaluationHost.Run()
at Microsoft.Mashup.Container.EvaluationContainerMain.Run(Object args)
at Microsoft.Mashup.Evaluator.SafeThread2.<>c__DisplayClass9_0.<CreateAction>b__0(Object o)
at Microsoft.Mashup.Container.EvaluationContainerMain.SafeRun(String[] args)
at Microsoft.Mashup.Container.EvaluationContainerMain.Main(String[] args)
--- End of inner exception stack trace ---
at Microsoft.Mashup.Evaluator.EvaluationHost.OnException(IEngineHost engineHost, IMessageChannel channel, ExceptionMessage message)
at Microsoft.Mashup.Evaluator.MessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.MessageHandlers.Dispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.ChannelMessenger.ChannelMessageHandlers.TryDispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.MessageHandlers.Dispatch(IMessageChannel channel, Message message)
at Microsoft.Mashup.Evaluator.Interface.IMessageChannelExtensions.WaitFor[T](IMessageChannel channel)
at Microsoft.Mashup.Evaluator.RemotePreviewValueSource.PreviewValueSource.WaitFor(Func`1 condition, Boolean disposing)
at Microsoft.Mashup.Evaluator.RemotePreviewValueSource.PreviewValueSource.get_SmallValue()
at Microsoft.Mashup.Evaluator.Interface.TracingPreviewValueSource.get_SmallValue()
at Microsoft.Mashup.Host.Document.Analysis.PackageDocumentAnalysisInfo.PackagePartitionAnalysisInfo.SetPreviewValue(EvaluationResult2`1 result, Func`1 getStaleSince, Func`1 getSampled)

PowerBINonFatalError:
{"AppName":"PBIDesktop","AppVersion":"2.81.5831.821","ModuleName":"","Component":"Microsoft.Mashup.Engine1.Library.SharePoint.SharePointQueryBuilder","Error":"System.ArgumentNullException","MethodDef":"GetPath","ErrorOffset":""}

OS Version:
Microsoft Windows NT 10.0.18363.0 (x64 en-US)

CLR Version:
4.7 or later [Release Number = 528040]

Peak Virtual Memory:
38.6 GB

Private Memory:
566 MB

Peak Working Set:
698 MB

IE Version:
11.836.18362.0

User ID:
46f52ac3-ea1d-47ad-bdd7-ec88e200f0e1

Workbook Package Info:
1* - en-US, Query Groups: 6, fastCombine: Enabled, runBackgroundAnalysis: False.

Telemetry Enabled:
True

Snapshot Trace Logs:
C:\Users\paul\AppData\Local\Microsoft\Power BI Desktop\FrownSnapShot1299534554.zip

Model Default Mode:
Import

Model Version:
PowerBI_V1

Is Report V3 Models Enabled:
False

Enabled Preview Features:
PBI_shapeMapVisualEnabled
PBI_NewWebTableInference
PBI_inlineExplore
PBI_showMinervaRibbon
PBI_showMinervaViewNavigator
PBI_hierarchicalSlicerCreation
PBI_relativeTimeSlicer

Disabled Preview Features:
PBI_SpanishLinguisticsEnabled
PBI_qnaLiveConnect
PBI_realTimeRefresh
PBI_v3ModelsPreview
PBI_dataSearchCuration

Disabled DirectQuery Options:
TreatHanaAsRelationalSource

Cloud:
GlobalCloud

DPI Scale:
100%

Supported Services:
Power BI

1 ACCEPTED SOLUTION
pfurbish
Frequent Visitor

I figure this out. 

 

Folder.contents will crash if the results contains a folder name with a "&".  I'm assuming an "&" in a file name will also cause a crash.

View solution in original post

1 REPLY 1
pfurbish
Frequent Visitor

I figure this out. 

 

Folder.contents will crash if the results contains a folder name with a "&".  I'm assuming an "&" in a file name will also cause a crash.

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.