# I'm getting "contextResource cannot be null" as a bundling error. How do I fix this?

**URL:** <https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008>\
**Category:** Questions\
**Created:** [December 13, 2020, 1:56pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008 "2020-12-13T13:56:02Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![tobi](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/t/b9e5f3/32.png) [@tobi](https://forum.defold.com/u/tobi)\
**Post date:** [December 13, 2020, 1:56pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/1 "2020-12-13T13:56:02Z")

</div>

After adding the google play services extension, I’ve been getting the bundling error.  
I use version 1.2.176. The extensions I use are as follows:  
Admob  
Iap  
Gpgs  
Thanks in advance.

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [December 13, 2020, 9:51pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/2 "2020-12-13T21:51:03Z")

</div>

What happens if you remove the extensions one by one? When does it start working again?

---

<div class="post-metadata">

**Author:** ![tobi](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/t/b9e5f3/32.png) [@tobi](https://forum.defold.com/u/tobi)\
**Post date:** [December 13, 2020, 9:59pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/3 "2020-12-13T21:59:06Z")

</div>

Yes it does. The problem is peculiar to the gpgs extension.

---

<div class="post-metadata">

**Author:** ![britzl](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/britzl/32/23_2.png) [@britzl](https://forum.defold.com/u/britzl)\
**Post date:** [December 13, 2020, 10:07pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/4 "2020-12-13T22:07:36Z")

</div>

> [@tobi](#):
>
> The problem is peculiar to the gpgs extension

Ok, so an empty project with the latest version of GPGS added triggers the error or is it in combination with the other extensions. May I suggest that you try GPGS+IAP and exclude AdMob?

I believe there is a conflict of dependencies between the different extensions, specifically GPGS and AdMob.

You can try to auto-migrate the extensions to AndroidX: [Migrating to AndroidX - #4 by britzl](https://forum.defold.com/t/migrating-to-androidx/66726/4)

---

<div class="post-metadata">

**Author:** ![tobi](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/t/b9e5f3/32.png) [@tobi](https://forum.defold.com/u/tobi)\
**Post date:** [December 14, 2020, 12:01am UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/5 "2020-12-14T00:01:14Z")

</div>

I tried GPGS alone and GPGS+IAP but to no avail. I still encountered the same issue. Is migrating the extensions to AndroidX the only solution?

---

<div class="post-metadata">

**Author:** ![SkaterDad](https://forum-defold.b-cdn.net/user_avatar/forum.defold.com/skaterdad/32/41137_2.png) [@SkaterDad](https://forum.defold.com/u/SkaterDad)\
**Post date:** [December 14, 2020, 2:41am UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/6 "2020-12-14T02:41:35Z")

</div>

> [@tobi](#):
>
> tried GPGS alone and GPGS+IAP but to no avail. I still encountered the same issue. Is migrating the extensions to AndroidX the only solution?

I use those extensions as well, on Defold 1.2.176 and 1.2.177 without issues. Works with or without the AndroidX jetifier flag. I don’t use AdMob, though.

Which versions of the extensions are you using?

---

<div class="post-metadata">

**Author:** ![tobi](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/t/b9e5f3/32.png) [@tobi](https://forum.defold.com/u/tobi)\
**Post date:** [December 14, 2020, 8:54am UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/7 "2020-12-14T08:54:18Z")

</div>

[https://github.com/defold/extension-iap/archive/2.0.2.zip](https://github.com/defold/extension-iap/archive/2.0.2.zip)  
[https://github.com/Lerg/extension-admob/archive/legacy.zip](https://github.com/Lerg/extension-admob/archive/legacy.zip)  
[https://github.com/defold/extension-gpgs/archive/2.2.0.zip](https://github.com/defold/extension-gpgs/archive/2.2.0.zip)

---

<div class="post-metadata">

**Author:** ![tobi](https://forum-defold.b-cdn.net/letter_avatar_proxy/v4/letter/t/b9e5f3/32.png) [@tobi](https://forum.defold.com/u/tobi)\
**Post date:** [December 14, 2020, 10:29pm UTC](https://forum.defold.com/t/im-getting-contextresource-cannot-be-null-as-a-bundling-error-how-do-i-fix-this/67008/8 "2020-12-14T22:29:45Z")

</div>

Auto-migrating to AndroidX fixed the issue. Thanks a lot for your help.
