this is my first post and I write it out of desperation (excuse me, my English is a translator) I created a small game in unity and it works quite well on Android all the verses except android 8, there is this error throwing me can you help me?
java.lang.RuntimeException:
at android.app.ActivityThread.performLaunchActivity (ActivityThread.java:3303)
at android.app.ActivityThread.handleLaunchActivity (ActivityThread.java:3411)
at android.app.ActivityThread.-wrap12 (Unknown Source)
at android.app.ActivityThread$H.handleMessage (ActivityThread.java:1994)
at android.os.Handler.dispatchMessage (Handler.java:108)
at android.os.Looper.loop (Looper.java:166)
at android.app.ActivityThread.main (ActivityThread.java:7529)
at java.lang.reflect.Method.invoke (Native Method)
at com.android.internal.os.Zygote$MethodAndArgsCaller.run (Zygote.java:245)
at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:921)
Caused by: java.lang.IllegalStateException:
at android.app.Activity.onCreate (Activity.java:1081)
at com.unity3d.player.UnityPlayerActivity.onCreate (Unknown Source:4)
at android.app.Activity.performCreate (Activity.java:7383)
at android.app.Instrumentation.callActivityOnCreate (Instrumentation.java:1218)
at android.app.ActivityThread.performLaunchActivity (ActivityThread.java:3256)
Related
This is the error: (it is not complete but this is what VS gives me)
XDG0062 System.Reflection.TargetInvocationException: Exception has
been thrown by the target of an invocation. --->
Windows.UI.Xaml.Markup.XamlParseException: The text associated with
this error code could not be found.
No matching constructor found on type 'SMPlayer.MediaControl'. [Line:
163 Position: 25] at
Windows.UI.Xaml.Application.LoadComponent(Object component, Uri
resourceLocator, ComponentResourceLocation componentResourceLocation)
at SMPlayer.MediaControl.InitializeComponent() at
SMPlayer.M SMPlayer MainPage.xaml 151
However, my MediaControl does have a constructor, which is defined here. (Sorry for posting the link instead of the code). And MediaControl.g.i.cs does not have Line 163.
Nonetheless, my project still compiles and runs correctly even with that error. And my MediaControl is displayed properly.
What is wrong?
I have UWP app that I use Frame.Navigate() method a lot. By default it seems to be performing transitions with an animation that makes next screen appear sliding from bottom. However, for my case it makes more sense if next screen comes from right or left.
So, to change this default behaviour, I used the following code from this MSDN document:
// Navigate to the right, ie. from LeftPage to RightPage
myFrame.Navigate(typeof(RightPage), null, new SlideNavigationTransitionInfo() { SlideNavigationTransitionEffect.FromRight } );
// Navigate to the left, ie. from RightPage to LeftPage
myFrame.Navigate(typeof(LeftPage), null, new SlideNavigationTransitionInfo() { SlideNavigationTransitionEffect.FromLeft } );
but I get this error:
Cannot initialize type 'SlideNavigationTransitionInfo' with a
collection initializer because it does not implement
'System.Collections.IEnumerable'
Changing code like this
myFrame.Navigate(typeof(RightPage), null, new SlideNavigationTransitionInfo() { Effect = SlideNavigationTransitionEffect.FromRight } );
causes app to crash by Invalid cast exception.
This was an old app that I'm updating so I suspected that might cause the issue and I updated the target version. Now targetting section looks like:
Target version: 1809 (10.0; Build 17763);
Min version : (10.0; 10240)
but still, problem persists.
Any idea how to solve this?
The first syntax error is quite self-explanatory; while the InvalidCastException seems to be caused by the fact that you are running you code on an OS with a version lower than 1809.
SlideNavigationTransitionEffect Enum was added in 1809. You can compile your code successfully because you have installed the SDK for 1809, but at runtime, if you don’t check beforehand, this code fails if runtime doesn’t support it.
//remove this from your code and it should be running well
Effect = SlideNavigationTransitionEffect.FromRight
In this case, you can set the Min version as 1809, to enforce this app can only be installed on 1809 or higher. Or you can write version adaptive code to check the OS support for the API, in this way, you can keep you Min version as low as desired to target a wider range of devices.
If you prefer , You can simply use XAML page transitions, its also compatible with min version 10240:
just put below lines in your RightPage or LeftPage XAML source.
<Page.Transitions>
<TransitionCollection>
<EdgeUIThemeTransition Edge="Left">
</EdgeUIThemeTransition>
</TransitionCollection>
</Page.Transitions>
I'm developing an application using AWS Lambda and DynamoDB. I'm getting the error below when I try to test my lambda function.
Error:
{
"errorType": "AggregateException",
"errorMessage": "One or more errors occurred. (Could not load type 'Amazon.Runtime.Internal.AsyncRunner' from assembly 'AWSSDK.Core, Version=3.3.0.0, Culture=neutral, PublicKeyToken=885c28607f98e604'.)",
"stackTrace": [
"at System.Threading.Tasks.Task.ThrowIfExceptional(Boolean includeTaskCanceledExceptions)",
"at System.Threading.Tasks.Task.Wait(Int32 millisecondsTimeout, CancellationToken cancellationToken)",
"at ProChiller.SyncDevices.QueryDevices(Devices input)",
"at lambda_method(Closure , Stream , Stream , ContextInfo )"
],
"cause": {
"errorType": "TypeLoadException",
"errorMessage": "Could not load type 'Amazon.Runtime.Internal.AsyncRunner' from assembly 'AWSSDK.Core, Version=3.3.0.0, Culture=neutral, PublicKeyToken=885c28607f98e604'.",
"stackTrace": [
"at Amazon.DynamoDBv2.DataModel.DynamoDBContext.LoadAsync[T](Object hashKey, CancellationToken cancellationToken)",
"at ProChiller.SyncDevices.d__6.MoveNext()"
]
}
}
As you can see it seems to not be able to load 'AsyncRunner' from the AWSSDK.
Code:
private static AmazonDynamoDBClient amazonDynamoDBClient = new AmazonDynamoDBClient();
public static Devices GetDeviceHandler(Devices input, ILambdaContext context)
{
var task = QueryDevices(input);
task.Wait();
return task.Result;
}
static async Task<Devices> QueryDevices(Devices device)
{
DynamoDBContext dbctx = new DynamoDBContext(amazonDynamoDBClient);
var operation = dbctx.LoadAsync<Devices>(device.TccvID);
Devices devices = await operation;
return devices;
}
What I've Tried:
I tried a number of different ways of querying with Dynamo, but this method is the cleanest and normally gets me the results I'm looking for.
Now I swear I had this code or very similar code working before at one point and I have in the past had issues with the SDK version causing problems when it was updated. I tried rolling back the version of the AWSSDK.Core to see if it was a problem with the newer version of it and my code. However, no matter what version I rollback to I still get the same error.
I've googled around in hopes that someone had a similar issue with that type load , but I could find anyone having written about this specific error or one similar enough that I could extrapolate. I was hoping maybe there was documentation of a specific SDK version I should be running for this type, but was not able to find anything.
The code I've posted is actually a paired down version where I tried to make it as simple as possible in hopes that there was something else I was doing that was causing this error.
Other Build Info:
The application is .Net Core 1.0.
AWSSDK.Core version is 3.3.24.3, but I do notice that in the error is says 'version=3.3.0.0'.
The Question:
Does anyone have an idea what might be causing this type load error? Is there a specific version of the SDK I should roll back to in order to fix this or am I barking up the wrong tree?
Thanks in advance for any help!
Short answer is I think you need to update to a newer version of AWSSDK.DynamoDBv2.
We had a pull request that removed the need for AsyncRunner from AWSSDK.Core that AWSSDK.DynamoDBv2 needed and so it was removed. In hindsight seeing your problem it wasn't the right decision to remove. If you update both your AWSSDK.Core and AWSSDK.DynamoDBv2 packages you would have been fine but in this case you updated just AWSSDK.Core but your older version of AWSSDK.DynamoDBv2 is still referencing AsyncRunner from AWSSDK.Core.
I'll have a discussion with the team and see about adding back AsyncRunner for cases like this.
Im tray to compile a Visual Studio Solution and get this error.
Error 1 Error inesperado en la tarea "ResolveManifestFiles".
System.ArgumentException: Value does not fall within the expected range.
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.NativeMethods.GetAssemblyIdentityFromFile(String filePath, Guid& riid)
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.MetadataReader.ImportAttributes()
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.MetadataReader.get_Attributes()
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.MetadataReader.get_Name()
at Microsoft.Build.Tasks.Deployment.ManifestUtilities.AssemblyIdentity.FromManagedAssembly(String path)
at Microsoft.Build.Tasks.ResolveManifestFiles.IsFiltered(ITaskItem item)
at Microsoft.Build.Tasks.ResolveManifestFiles.GetOutputAssemblies(PublishInfo[] publishInfos, List`1& assemblyList)
at Microsoft.Build.Tasks.ResolveManifestFiles.GetOutputAssembliesAndSatellites(PublishInfo[] assemblyPublishInfos, PublishInfo[] satellitePublishInfos)
at Microsoft.Build.Tasks.ResolveManifestFiles.Execute()
at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
at Microsoft.Build.BackEnd.TaskBuilder.d__20.MoveNext() Ziruma
Im not sure what is the problem. Project compiling until i try to generate the final instalation package. Please, help me.
Am trying to run Sharpen to convert some Java code to c#. Below is the detail of the instruction I am following, environment and problem statement.
Instruction followed:
http://www.pauldb.me/post/14916717048/a-guide-to-sharpen-a-great-tool-for-converting-java
http://community.versant.com/documentation/reference/db4o-7.12/net2/reference/index_Left.html#CSHID=sharpen%2Fhow_to_setup_sharpen.htm|StartTopic=Content%2Fsharpen%2Fhow_to_setup_sharpen.htm|SkinName=RedVersant
Environment:
Eclipse 4.2.0
JDK 1.7 (jdk1.7.0_03)
Problem:
I am able to set up the project in Eclipse and run the build file to convert the code. While executing the target "sharpen-docs" of the build file it errors out with the following message in the eclipse configuration log.
Any help will be much appreciated. Thanks in advance.
!ENTRY org.eclipse.osgi 2 0 2012-07-31 13:23:04.507
!MESSAGE
!STACK 0
org.osgi.framework.BundleException: The activator sharpen.core.Sharpen for bundle sharpen.core is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:172)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:300)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:263)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:236)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
at org.eclipse.core.launcher.Main.main(Main.java:34)
Caused by: java.lang.ClassNotFoundException: sharpen.core.Sharpen
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:165)
... 25 more
Root exception:
java.lang.ClassNotFoundException: sharpen.core.Sharpen
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:165)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.start(AbstractBundle.java:300)
at org.eclipse.osgi.framework.util.SecureAction.start(SecureAction.java:440)
at org.eclipse.osgi.internal.loader.BundleLoader.setLazyTrigger(BundleLoader.java:263)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:236)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
at org.eclipse.core.launcher.Main.main(Main.java:34)
!ENTRY org.eclipse.osgi 4 0 2012-07-31 13:23:04.737
!MESSAGE Application error
!STACK 1
org.eclipse.core.runtime.CoreException: Plug-in sharpen.core was unable to load class sharpen.core.SharpenApplication.
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.throwException(RegistryStrategyOSGI.java:194)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:176)
at org.eclipse.core.internal.registry.ExtensionRegistry.createExecutableExtension(ExtensionRegistry.java:905)
at org.eclipse.core.internal.registry.ConfigurationElement.createExecutableExtension(ConfigurationElement.java:243)
at org.eclipse.core.internal.registry.ConfigurationElementHandle.createExecutableExtension(ConfigurationElementHandle.java:55)
at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:191)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110)
at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353)
at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629)
at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584)
at org.eclipse.equinox.launcher.Main.run(Main.java:1438)
at org.eclipse.equinox.launcher.Main.main(Main.java:1414)
at org.eclipse.core.launcher.Main.main(Main.java:34)
Caused by: java.lang.ClassNotFoundException: sharpen.core.SharpenApplication
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:501)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:421)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:412)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:340)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadClass(AbstractBundle.java:1212)
at org.eclipse.core.internal.registry.osgi.RegistryStrategyOSGI.createExecutableExtension(RegistryStrategyOSGI.java:174)
... 17 more
For the records:
The problem got resolved after I install Java 6 .. thanks Anders for pointing towards this.