Admob is not showing ads on real device after build. Expo React-native - reactjs

Expo SDK Version: 36.0.0
Platforms(Android/iOS/web/all): Android
I use the expo Admob lib to implement AdMob banners and interstitial Ads on my App. When running through expo cli on my emulator it works perfectly. When I use real adUnitID it shows a real ad. However, after building the apk file and installing on real devices, the Ads are not showing anymore.
My implementation is quite simple:
<AdMobBanner
bannerSize="mediumRectangle"
adUnitID={'ca-app-pub-my-key/my-key'}
onAdViewDidReceiveAd={() => adReceived('success')}
onDidFailToReceiveAdWithError={() => adReceived('err')}
/>
adReceived(arg) - it’s just a logger, which save results, do I have success request to Google ad server or not.
On real device I have err messages. So, it looks like then app doesn’t have permission to making request to the internet.
I don’t have permission section in my app.json, and any other specific setting in this file. According to Configuration with app.json page - To use ALL permissions supported by Expo, do not specify the "permissions" key.
I found on stackoverflow and expo-forum a lot of relevant topics. And no one provided any working solution.
If I should provide some additional information, please specify what I need to add.
If there is a solution to this, which I didn’t find then please add the link.
Let’s help to resolve this question once and forever for all developers.
Thanks!

According to this post, there are six reasons. But probably, you did not update your payment details or your region has a slower fill-rate. Slower fill-rate means, there are less advertisers targeting these markets (in your region or language).

how I fixed the problem
first of all - you can add an argument with error
onDidFailToReceiveAdWithError={(errorCode) => console.log(errorCode)}
secondly
When I added my apps to the Google Play store and install it from the store, then my app start showing Ad correctly

Related

Registering your app in Teams is failing with error "You don't have permissions to add Hello World to this team."

I am following Get started on the Microsoft Teams platform with Node.js and App Studio
to add app in MSTeams. All the steps worked as per the documentation, however the last step "Register your app in Teams" failed during installing of the application. Below is the image attached
I also tried to upload the custom application , but it also throws error that something went wrong.
Below are the images:
Here are the permissions, I have enabled them all to test, still the issue remains the same
Can someone please suggest to fix this issue?
You need to make sure that you have the correct permissions to side-load custom apps into Teams, and this can be controlled at the Org (i.e. Tenant) level, the Team level, and the individual level. Have a look here for more.

Codename One Preferences/Storage permissions

I have developed and published an app in Google Play Store, which only send simple String request to REST API and store the results in the Preferences. The same app is also submitted to Windows Store for publication, however it was rejected due to the following reason:
The app declares use of the sensitive capability [musicLibrary, picturesLibrary, videosLibrary] without appearing to access the declared capability. Please removed the sensitive capability declaration and re-submit the app.
Upon inspection to Google Play Store submission, I noticed the same permissions are requested:
This app has access to:Photos/Media/Filesread the contents of your USB storagemodify or delete the contents of your USB storageStorageread the contents of your USB storagemodify or delete the contents of your USB storageOtherreceive data from Internetview network connectionsfull network accessprevent device from sleeping
So my question is, do Preferences really need these permissions, or can I set some kind of build hints to remove these permission requests, especially for UWP build? I have also tried to set android.blockExternalStoragePermission build hint, but the permissions are still requested in Android build. I have yet to try iOS build since currently I don't have Apple Developer account.
Thank you very much in advance.
Edit #1 (23/10/2018):
Upon further inspection, I found that I have mistakenly uploaded the version that didn't declare android.blockExternalStoragePermission to Google Play Store, so all good on Android version.
Currently I'm not using any of cn1libs, and here's the list of all classes imported in my application:
java.util.HashMapjava.util.Mapjava.util.Randomcom.codename1.components.InfiniteProgresscom.codename1.components.ToastBarcom.codename1.components.ToastBar.Statuscom.codename1.io.CharArrayReadercom.codename1.io.JSONParsercom.codename1.io.Logcom.codename1.io.NetworkManagercom.codename1.io.Preferencescom.codename1.io.rest.Responsecom.codename1.io.rest.Restcom.codename1.l10n.L10NManagercom.codename1.ui.Buttoncom.codename1.ui.Componentcom.codename1.ui.Containercom.codename1.ui.Dialogcom.codename1.ui.FontImagecom.codename1.ui.Formcom.codename1.ui.Labelcom.codename1.ui.events.ActionEventcom.codename1.ui.events.ActionListenercom.codename1.ui.layouts.BorderLayoutcom.codename1.ui.layouts.FlowLayoutcom.codename1.ui.layouts.GridLayoutcom.codename1.ui.plaf.Bordercom.codename1.ui.plaf.Stylecom.codename1.ui.plaf.UIManagercom.codename1.ui.util.Resources
So my original question remain, how do I set the build hints to prevent the same external storage read/write permission in Windows and iOS?
See the section titled "Android Permissions" here, for a list of some API's that might trigger extra permissions. I suggest extracting the manifest from the XML and inspecting it. It should include two permissions based on your description you should have two permissions there:
android.permission.WRITE_EXTERNAL_STORAGE - which you should have been disabled when you applied android.blockExternalStoragePermission
android.permission.INTERNET - this one you actually need
I'm assuming you have a permission for media access and here it becomes a question of where it came from?
Did you use a cn1lib that might include a feature that triggers this?
Do you have a feature in the app that isn't active yet?
Once you have the specific name or results of this investigation comment here and I'll revise the answer with more details.

Trying to code sign Mac app with Developer ID - get com.apple.developer.maps entitlement is not allowed (error code -67050)

I am code signing a Mac app using my Developer ID certificate so we can send it to beta testers. Thanks to helpful articles here I made sure I have the right certificate and private key. (This is a new app id) When I select Developer ID and Archive, I select to distribute with Developer ID and it validates all the checks successfully (Using Xcode 6.1) and creates my app file. When I launch it I crash with this in console (another great tip found here to check console for the REAL error):
killed com.[appname.OSX][pid 5946] because its use of the com.apple.developer.maps entitlement is not allowed (error code -67050)
11/7/14 11:26:23.263 com.apple.xpc.launchd[1]: (com.VIPorbit.OSX.192016[5946]) Binary is improperly signed.
So, I know the docs say you cannot distribute an app with Maps outside of the MacApp Store, but I assume this mean selling Mac apps as is often done. We are using the Mac App Store all the way. Also I can successfully archive and submit to the Mac App Store and we're in review.
The challenge is we want to get this out to some beta folks and Maps is a key feature we've added. I really don't want to go the old route with getting this Mac info and adding it to the provisioning file, defeats the purpose of the Developer ID option.
Anyone else experience this?
You can't distribute an application utilizing MapKit with a Developer ID.
MapKit is an Mac App Store-only feature.
It's a shame that this is not clear from the documentation.
If you want to test the app before the Mac App Store submission, I am afraid you have to add beta-testers' machines to the provisioning profile and sign the bundle with a "Mac Developer: ..." code signing identity.
😔

why i couldn't see any text in "http://crawlservice.appspot.com/?key=123456&url=http://mydomain.com#!article"?

Ok, i found this link https://code.google.com/p/gwt-platform/wiki/CrawlerSupport#Using_gwtp-crawler-service that explain how you can make your GWTP app crawlable.
I got some GWTP experience, but i know nothing about AppEngine.
Google said its "crawlservice.appspot.com" can parse any Ajax page. Now I have a page "http://mydomain.com#!article" that has an artice that was pulled from Database. Say that page has the text "this is my article". Now I open this link:
crawlservice.appspot.com/?key=123456&url=http://mydomain.com#!article, then i can see all javascript but I couldn't find the text "this is my article".
Why?
Now let check with a real life example
open this link https://groups.google.com/forum/#!topic/google-web-toolkit/Syi04ArKl4k & you will see the text "If i open that url in IE"
Now you open http://crawlservice.appspot.com/?key=123456&url=https://groups.google.com/forum/#!topic/google-web-toolkit/Syi04ArKl4k you can see all javascript but there is no text "If i open that url in IE",
Why is it?
SO if i use http://crawlservice.appspot.com/?key=123456&url=mydomain#!article then Can google crawler be able to see the text in mydomain#!article?
also why the key=123456, it means everyone can use this service? do we have our own key? does google limit the number of calls to their service?
Could you explain all these things?
Extra Info:
Christopher suggested me to use this example
https://github.com/ArcBees/GWTP-Samples/tree/master/gwtp-samples/gwtp-sample-crawler-service
However, I ran into other problem. My app is a pure GWTP, it doesn't have appengine-web.xml in WEB-INF. I have no idea what is appengine or GAE mean or what is Maven.
DO i need to register AppEngine?
My Appp may have a lot of traffic. Also I am using Godaddy VPS. I don't want to register App Engine since I have to pay for Google for extra traffic.
Everything in my GWTP App is ok right now except Crawler Function.
So if I don't use Google App Engine, then how can i build Crawler Function for GWTP?
I tried to use HTMLUnit for my app, but HTMLUnit doesn't work for GWTP (See details in here Why HTMLUnit always shows the HostPage no matter what url I type in (Crawlable GWT APP)? )
I believe you are not allowed to crawl Google Groups. Probably they are actively trying to prevent this, so you do not see the expected content.
There's a couple points I wish to elaborate on:
The Google Code documentation is no longer maintained. You should look on Github instead: https://github.com/ArcBees/GWTP/wiki/Crawler-Support
You shouldn't use http://crawlservice.appspot.com. This isn't a Google service, it's out of date and we may decide to delete it down the road. This only serves as a public example. You should create your own application on App Engine (https://appengine.google.com/)
There is a sample here (https://github.com/ArcBees/GWTP-Samples/tree/master/gwtp-samples/gwtp-sample-crawler-service) using GWTP's Crawler Service. You can basically copy-paste it. Just make sure you update the <application> tag in appengine-web.xml to the name of your application and use your own service key in CrawlerModule.
Finally, if your client uses GWTP and you followed the documentation, it will work. If you want to try it manually, you must encode the Query Parameters.
For example http://crawlservice.appspot.com/?key=123456&url=http://www.arcbees.com#!service will not work because the hash (everything including and after #) is not sent to the server.
On the other hand http://crawlservice.appspot.com/?key=123456&url=http%3A%2F%2Fwww.arcbees.com%2F%23!service will work.

I cannot compile "out-of-the-box" - google's example cloud backend IOS client

Why am I getting "duplicate symbol _kCloudBackendClientID" compiling the project "solutions-mobile-backend-starter-ios-client-master" from Google?
This is right out of the box - I have xCode 5.0.2 (5A3005)
I am trying out their Mobile Backend Starter... ugh so tedious to get this working.
As of March 28 2014.. yes, the google app engine mobile backend starter for ios is a real pain in the a** to get working. I'm using XCode 5.1 and managed to get it all working after about 8 hours of trial and error.
The setup guide is here -
https://developers.google.com/cloud/samples/mbs/ios/
There are a lot of steps required to get the push notification certificates and provisioning profiles and app id's setup properly. One stumbling block is that when doing development builds, XCode forces your bundle identifier to have ".dev" at the end. Be sure you have this in the provisioning profile that you create with the attached push notification certificate.
There are several things broken with the code. First the compiler error:
1) Change #include "Constants.m" to #include "Constants.h" in MessagesTableViewController.m
Now the runtime errors:
2) Add Splash1/2/3ViewController.h and .m to the project. If you don't do this you get a crash on startup related to some exception related to UIViewController
3) Implement this in CloudBackendIOSClientAppDelegate.m
- (void)application:(UIApplication *)application
didReceiveRemoteNotification:(NSDictionary *)userInfo
fetchCompletionHandler:(void (^)(UIBackgroundFetchResult result))handler
{
/* copy-paste the code from the previous didReceiveRemoteNotification */
//add this
if (handler)
handler(UIBackgroundFetchResultNoData);
}
This API seems to be new as of IOS7 and (I guess) is required to receive push notifications on IOS7.
The other thing I had to do was go into the app engine configuration on the app engine website. On the "Backends" tab, you have to make sure your 'worker' backend is started.
If you get all of this done properly you should be able to go down to the "Custom/Mobile Backend settings" tab, scroll to the bottom, and send a broadcast message successfully.
Hey Google people, if you are reading this you can compensate me with some free tech support on the next hurdles I have to jump through ;)

Resources