Generate Cloud Endpoint: MyApp is not configured as a web application - android

I'm trying to create a new Google App Engine application.
Within a brand new Android project, I added an App Engine project and all seems well. Now when trying to generate an endpoint for a class via Google > Generate Cloud Endpoint it has a number of Unexpected Exception.
Here are some of the exceptions.
java.lang.IllegalArgumentException: Project MyApp is not a web-app project
and
org.eclipse.core.runtime.CoreException: MyApp is not configured as a web application
This doesn't seem to make sense, it's an Android app but I may be mistaken with how it should act.
How do I resolve these errors with Eclipse

I figure someone else is bound to make the same bonehead mistake I did, so I'll answer my own question instead of deleting my shame in case it can help others.
Basically this error message happens when following https://developers.google.com/eclipse/docs/endpoints-addentities and you generate the endpoint class in the wrong project.
When you create a Google App Engine powered Android app, you will have at least two projects: MyApp and MyApp-AppEngine. You need to put your entity class into the MyApp-AppEngine project and NOT your MyApp project.
If you place your class within MyApp and generate the endpoint classes that way, you'll end up confusing Java / Eclipse / yourself / etc. It will then give you the errors
java.lang.IllegalArgumentException: Project MyApp is not a web-app project
and
org.eclipse.core.runtime.CoreException: MyApp is not configured as a web application

Related

Unity Auth Error With Firebase

I implemented Firebase into a Unity app I am creating. There are two buttons that will run the two functions to create a new user and login an existing user. So far this functionality works on my PC, however whenever I try to deploy it to my android phone or Mac I end up getting the following error in the console.
DllNotFoundException: FirebaseCppApp-5.1.0
Firebase.AppUtilPINVOKE+SWIGExceptionHelper..cctor ()
Rethrow as TypeInitializationException: An exception was thrown by the type initializer for SWIGExceptionHelper
Firebase.AppUtilPINVOKE..cctor ()
Rethrow as TypeInitializationException: An exception was thrown by the type initializer for Firebase.AppUtilPINVOKE
Firebase.AppUtil.SetLogFunction (Firebase.LogMessageDelegate arg0)
It appears there is a missing .dll file, however I cannot for the life of me find out how to include it within the project file. I also have double checked the package name and it is the exact same name as the one made for my Firebase project, the google-services JSON in the root of the project, and the Api compatibility level is set to .NET 2.0. On top of that I also uninstalled and reinstalled the app a few times. I also tried using the Play Services Resolver which didn't help much at all either.
Similar error here, only with Firebase Cloud Messaging. After tinkering around in a fashion similar to yours I concluded that it was caused by corruption during import of Firebase Package.
What worked for me:
Deleted each and every folder created while importing Firebase Package.
Reimported Firebase Package

Have a trouble with developing an app for smarteyeglass

Recently,i need to build an app for smart eyeglass. with official instruction,i have to import three library project,including SmartExtensionAPI,SmartExtensionUtils SmartEyeglassAPI.and i have develop dependencies for my project when i run this app, there a lot of error information.
such as Error:(44, 57)
com.sonyericsson.extras.liveware.aef.notification is not
existing;Error:(45, 57)
com.sonyericsson.extras.liveware.aef.registration is not
existiong!Error:(49, 52)com.sonyericsson.extras.liveware.aef.control
is not existing,Error:(198, 40)Registration.Intents is not existing
and so on.
what's wrong? search for help.
thanks
It seems like you are missing registration for your extension in your application.
Please take a look at sample projects for details. You can also start developing directly using sample projects in the SDK.

Error:Execution failed for task ':backend:appengineEndpointsGetClientLibs

When adding a Google Cloud Endpoint backend to a Android app using the Google App Engine Java Module Template, two classes (amongst other things) are added to the project.
We are then encouraged to modify these classes to our own requirements. So, I decided to delete the model class (MyBean) and the endpoint class (MyEndpoint) and replace them with my own classes. When I tried to rebuild/clean the project, I get the error message:
Error:Execution failed for task ':backend:appengineEndpointsGetClientLibs'.
There was an error running endpoints command get-client-lib:
<package-name>.MyEndpoint
I looked for a couple of hours for a solution to this problem until I found the cause.So I decided to share it since this question does not even exist on SO (Please correct me if I am wrong)
Go to backend\src\main\webapp\WEB-INF\web.xml
In the web.xml file, look for the init-param and change the parameter value to the new endpoint class you've just added.
<init-param>
<param-name>services</param-name>
<param-value>com.mycompany.backend.New-Endpoint-Class-Name</param-value>
</init-param>
Rebuild the project and everything should be just fine.

Modules do not start in Google App Engine Python on Development Server

Problem:
I am trying to create a simple app to try Modules in Google App Engine Python on Development Server(Development SDK 1.9.2). But I do not see the modules getting started at runtime(log messages specifying the ports on which they are started).
Logs when I start the app using the Launcher on the development server:
2014-04-13 02:40:47 Running command: "['C:\\Python27\\pythonw.exe', 'C:\\Program Files (x86)\\Google\\google_appengine\\dev_appserver.py', '--skip_sdk_update_check=yes', '--port=11080', '--admin_port=8003', u'C:\\gaurav\\coding\\python\\androidbackend1']"
INFO 2014-04-13 02:40:50,572 devappserver2.py:764] Skipping SDK update check.
INFO 2014-04-13 02:40:50,627 api_server.py:171] Starting API server at: http://localhost:59432
INFO 2014-04-13 02:40:50,631 dispatcher.py:182] Starting module "default" running at: http://localhost:11080
INFO 2014-04-13 02:40:50,634 admin_server.py:117] Starting admin server at: http://localhost:8003
INFO 2014-04-13 02:40:56,062 module.py:627] default: "GET / HTTP/1.1" 200 12
This Modules doc page at GAE for Python does not mention anything about development server. From another link, I figured out that on development server, all the modules are started at the beginning of app execution and they only differ in the port number of their URLs
Context:
I created a new app using the Google Launcher which generates a default "main.py" and "app.yaml". I then copied the "main.py" into a file named "modulem1.py", while retaining "main.py". I copied "app.yaml" into a file named "modulem1.yaml", while retaining the "app.yaml" file. I added the following line to "modulem1.yaml":
module: modulem1
I want to use Google Endpoints API to interact between the web app and Android app. So I need to use module for that and therefore I am trying a small web app with modules
I should be missing something obvious. Appreciate any help
If you are using the Google App Engine Launcher, then you will need to provide the full path to your second yaml file modulem1.yaml
Then once you start it, you can view the Logs and see that the modulem1 module has been launched at http://localhost:8080 and the default module has been launched at http://localhost:8081

Android NoClassDefFound when referencing class from external libraries (IntelliJ IDEA 12)

I'm having an issue with IntelliJ's dependency handling in regards to external modules. Here's some context:
I'm writing an Android app which implements Google Maps. For my current feature set, I require two external libraries-- Google's Play Services Library and mapex (A third party google map extension library located here https://code.google.com/p/mapex/). I actually built most of this project in Android Studio before I was recommended to move to IntelliJ due to the easier dependency handling. But now I'm here and still having problems.
My Error
When trying to build an object from a class located in the mapex package (com.androidnatic.maps), I get this error when starting the activity the view is contained in (object has not been created yet):
07-03 11:40:35.837: ERROR/dalvikvm(3585): Could not find class 'com.androidnatic.maps.SimpleMapView', referenced from method com.example.myproject.MapActivity.showHeatMap
And then, upon creation, my app force closes and leaves this behind in logcat:
7-03 11:40:45.467: ERROR/AndroidRuntime(3585): FATAL EXCEPTION: main
java.lang.NoClassDefFoundError: com.androidnatic.maps.SimpleMapView
at com.example.myproject.MapActivity.showHeatMap(MapActivity.java:492)
Yet I'm completely stumped because my IDE gives me no sign that anything is wrong! Classes are auto-filled in when trying to access them from MyProject.
ide-fill-in http://www.tonyandrys.com/img/fillin.jpg
No build errors about missing classes, missing modules, class definitions, or anything related.
I get the same results if I try to access the class via its full package name as well.
// No dice.
final SimpleMapView mapView = new SimpleMapView(this, "apikey");
final com.androidnatic.maps.SimpleMapView mapView = new com.androidnatic.maps.SimpleMapView(this, "apikey");
It seems that there's only an issue when the application is running on my phone, as far as my IDE is concerned.
Here's the structure of MyProject:
main-project-structure http://www.tonyandrys.com/img/mainstructure.jpg
Here's my main project's dependency settings (where I assume I screwed up somewhere):
project-structure http://www.tonyandrys.com/img/projectstructure.jpg
And here is the structure of the mapex library module:
mapex-lib http://www.tonyandrys.com/img/mapexstructure.jpg
The class files that I'm trying to access live in MapExLib/gen and MapExLib/src, which are currently marked as source directories (blue).
Does anyone have any ideas on how to proceed from here?
Try to do this :
Android, IntelliJ Idea, changing module type
I had the same error "Could not find class XXX from referenced method XXX" with Intellij, involving an Android Test Module and a test which could not find the Activity class anywhere.
I set inside the Project Structure the main Module's Facet Android to Library Module (checkbox) and it worked...
Let us know

Categories

Resources