Error reports from xna adrotator 0.3

Oct 2, 2012 at 12:48 PM
Edited Oct 2, 2012 at 7:34 PM

Hello,

I've got these error reports from users of my games.

Maybe it helps.

   at Microsoft.Xna.Framework.Graphics.GraphicsHelpers.ThrowExceptionFromResult(UInt32 result)
   at Microsoft.Xna.Framework.Graphics.Texture2D..ctor(GraphicsDevice graphicsDevice, Stream stream, Int32 width, Int32 height, XnaImageOperation operation)
   at Microsoft.Xna.Framework.Graphics.Texture2D.FromStream(GraphicsDevice graphicsDevice, Stream stream)
   at AdRotatorXNA.Helpers.ImageDownload.<>c__DisplayClass2.<GetImageFromURL>b__0(Object s, OpenReadCompletedEventArgs e)
   at System.Net.WebClient.OnOpenReadCompleted(OpenReadCompletedEventArgs e)
   at System.Net.WebClient.OpenReadOperationCompleted(Object arg)
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(RuntimeMethodInfo rtmi, Object obj, BindingFlags invokeAttr, Binder binder, Object parameters, CultureInfo culture, Boolean isBinderDefault, Assembly caller, Boolean verifyAccess, StackCrawlMark& stackMark)
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, StackCrawlMark& stackMark)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   at System.Delegate.DynamicInvokeOne(Object[] args)
   at System.MulticastDelegate.DynamicInvokeImpl(Object[] args)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.Dispatch(DispatcherPriority priority)
   at System.Windows.Threading.Dispatcher.OnInvoke(Object context)
   at System.Windows.Hosting.CallbackCookie.Invoke(Object[] args)
   at System.Windows.RuntimeHost.ManagedHost.InvokeDelegate(IntPtr pHandle, Int32 nParamCount, ScriptParam[] pParams, ScriptParam& pResult)

 

 

An unexpected error has occurred.
   at Microsoft.Xna.Framework.Graphics.GraphicsHelpers.ThrowExceptionFromResult(UInt32 result)
   at Microsoft.Xna.Framework.Graphics.Texture2D..ctor(GraphicsDevice graphicsDevice, Stream stream, Int32 width, Int32 height, XnaImageOperation operation)
   at Microsoft.Xna.Framework.Graphics.Texture2D.FromStream(GraphicsDevice graphicsDevice, Stream stream)
   at AdRotatorXNA.AdSmaatoComponent.somaAd_NewAdAvailable(Object sender, EventArgs e)
   at SOMAWP7.SomaAd.<>c__DisplayClassb.<notifyUser>b__8()
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(RuntimeMethodInfo rtmi, Object obj, BindingFlags invokeAttr, Binder binder, Object parameters, CultureInfo culture, Boolean isBinderDefault, Assembly caller, Boolean verifyAccess, StackCrawlMark& stackMark)
   at System.Reflection.RuntimeMethodInfo.InternalInvoke(Object obj, BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture, StackCrawlMark& stackMark)
   at System.Reflection.MethodBase.Invoke(Object obj, Object[] parameters)
   at System.Delegate.DynamicInvokeOne(Object[] args)
   at System.MulticastDelegate.DynamicInvokeImpl(Object[] args)
   at System.Windows.Threading.DispatcherOperation.Invoke()
   at System.Windows.Threading.Dispatcher.Dispatch(DispatcherPriority priority)
   at System.Windows.Threading.Dispatcher.OnInvoke(Object context)
   at System.Windows.Hosting.CallbackCookie.Invoke(Object[] args)
   at System.Windows.RuntimeHost.ManagedHost.InvokeDelegate(IntPtr pHandle, Int32 nParamCount, ScriptParam[] pParams, ScriptParam& pResult)


Coordinator
Oct 2, 2012 at 12:57 PM

Sounds like there is an issue in the image download on some clients, possibly a corrupt image.

Can you provide a little more detail in which providers you are using and in which regions the client are reporting these issues.

Oct 2, 2012 at 7:34 PM

I use smaato, inner-active and pubcenter.

I've got error reports like this from china, russia, india and i think usa but I'm not sure.

Jan 26, 2013 at 9:33 AM

I'm also getting loads of these exceptions after starting to show inneractive and mobfox ads. I'm using AdRotator XNA 0.4.

It seems that about 20-50% of sessions that serve inneractive or mobfox ads end because of these exceptions.

This data was provided by Flurry, whereas MS dev center started to report huge amount of crashes because of UnAuthorizedAccessException after I started using inneractive and mobfox.

Coordinator
Jan 26, 2013 at 12:30 PM

Can you include some of those error reports from MS and Flurry to help diagnose the issue

also do you have a way to recreate the issue reliably (or even traces/activity from the clients themselves) plus the exact config

 

one last thing, did you have the issue with 0.3?

 

Jan 26, 2013 at 11:11 PM

After investigating the problem more, it's clear that there's no new problem with AdRotator. I messed some things up and that was the cause for UnAuthorizedAccesExceptions.

But the problem the starter of this thread mentioned seems to exist. MS reports following:

InvalidOperationException at

Microsoft.Xna.Framework.Graphics.GraphicsHelpers.ThrowExceptionFromResult                                                                 84       
6                          Microsoft.Xna.Framework.Graphics.Texture2D..ctor                                                                                          548      
7                          Microsoft.Xna.Framework.Graphics.Texture2D.FromStream                                                                                     96       
8                          AdRotatorXNA.AdSmaatoComponent.somaAd_NewAdAvailable                                                                                      404      
9                          .__c__DisplayClassb._notifyUser_b__8                                                                                                      84       
10       mscoree3_7.dll                                                                                                                                              428848   
11       mscoree3_7.dll                                                                                                                                              222523   
12       mscoree3_7.dll                                                                                                                                              221143   
13                         System.Reflection.RuntimeMethodInfo.InternalInvoke                                                                                        112      
14                         System.Reflection.RuntimeMethodInfo.InternalInvoke                                                                                        1556     
15                         System.Reflection.MethodBase.Invoke                                                                                                       104      
16                         System.Delegate.DynamicInvokeOne                                                                                                          564      
17                         System.MulticastDelegate.DynamicInvokeImpl                                                                                                84       
18                         System.Windows.Threading.DispatcherOperation.Invoke                                                                                       80       
19                         System.Windows.Threading.Dispatcher.Dispatch                                                                                              404

 

and

InvalidOperationException at

                        Microsoft.Xna.Framework.Graphics.GraphicsHelpers.ThrowExceptionFromResult    84       
6                          Microsoft.Xna.Framework.Graphics.Texture2D..ctor                             548      
7                          Microsoft.Xna.Framework.Graphics.Texture2D.FromStream                        96       
8                          .__c__DisplayClass2._GetImageFromURL_b__0                                    392      
9                          System.Net.WebClient.OnOpenReadCompleted                                     88       
10                         System.Net.WebClient.OpenReadOperationCompleted                              96       
11                         .WorkItem.WaitCallback_Context                                               104      
12                         System.Threading.ExecutionContext.Run                                        324      
13                         .WorkItem.doWork                                                             220      
14                         System.Threading.Timer.ring                                                  296     

 

these aren't thrown very frequently, both in around 2-5% of gaming sessions.

Coordinator
Jan 27, 2013 at 8:47 PM

Sounds like something I was suspecting, we noticed some odd latency errors from the internal network checking we do to ensure it doesn't cause issue when there is no network, it's using the standard Microsoft API but I've heard more and more reports of issues using it in low bandwidth situations.

Looks like I'll have to rip that out again and sort out another method for bad network tracking (the alternative caused a few headaches but I guess I'll now have to face the music)

 

I'll wee what I can do with the time I have.