Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[User Model] Fixes #640

Merged
merged 7 commits into from
Sep 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 28 additions & 6 deletions MIGRATION_GUIDE_v3_to_v5.md
Original file line number Diff line number Diff line change
Expand Up @@ -251,14 +251,36 @@ The debug namespace is accessible via `OneSignal.Debug` and provides access to d

# Troubleshooting

If you run into the following errors :
```
Assets/OneSignal/Example/OneSignalExampleBehaviou.cs: error CS0246: The type or namespace name '...' could not be found (are you missing a using directive or an assembly reference?)
```

`Assets/OneSignal/Example/OneSignalExampleBehaviou.cs: error CS0246: The type or namespace name '...' could not be found (are you missing a using directive or an assembly reference?)`

`Assets/OneSignal/Attribution/OneSignalVSAttribution.cs: error CS0117: 'OneSignal' does not contain a definition for '...'`
```
Assets/OneSignal/Attribution/OneSignalVSAttribution.cs: error CS0117: 'OneSignal' does not contain a definition for '...'
```

1. Delete the directory at `Assets/OneSignal` and the xml file at `Assets/Plugins/Android/OneSignalConfig.plugin/AndroidManifest.xml`

- If you would like to regenerate the OneSignal assets, remove the OneSignal Unity SDK packages (Android, Core, iOS) from your project and import the OneSignal SDK again.
2. Check the menu at **Window > OneSignal SDK Setup** to see if there are any remaining steps to run

If you would like to regenerate the OneSignal assets, remove the OneSignal Unity SDK packages (Android, Core, iOS) from your project and import the OneSignal SDK again.
```
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':unityLibrary:mergeReleaseJavaResource'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.MergeJavaResWorkAction
> 2 files found with path 'META-INF/kotlinx_coroutines_core.version' from inputs:
- /Users/.../Library/Bee/Android/Prj/Mono2x/Gradle/unityLibrary/libs/org.jetbrains.kotlinx.kotlinx-coroutines-core-jvm-1.6.4.jar
- /Users/.../Library/Bee/Android/Prj/Mono2x/Gradle/unityLibrary/libs/org.jetbrains.kotlinx.kotlinx-coroutines-core-1.6.4.jar
```
```
FAILURE: Build failed with an exception.
* What went wrong:
Execution failed for task ':launcher:mergeReleaseJavaResource'.
> A failure occurred while executing com.android.build.gradle.internal.tasks.Workers$ActionFacade
> More than one file was found with OS independent path 'META-INF/kotlinx_coroutines_core.version'.
```

1. Go to **Player Settings** and click the Android Tab. Under **Publishing Settings**, enable the following:
- Custom Main Gradle Template
- Custom Gradle Properties Template
2. Resolve Android dependencies with EDM4U at **Assets > External Dependency Manager > Android Resolver > Force Resolve**
Binary file not shown.
Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
@@ -1,4 +1,57 @@
# Version 1.2.169 - Jan 20, 2021
# Version 1.2.177 - Aug 14, 2023
* iOS Resolver - Added `/opt/homebrew/bin` to Cocoapod executable search path.
Fixes #627

# Version 1.2.176 - Apr 27, 2023
* Android Resolver - Added two Android Resolver settings to determine whether
EDM4U injects custom local Maven repo path as a relative path or full path.
Fixes #537
* Android Resolver - Inject Maven Repo to `settingTemplate.gradle` from
Unity 2022.2+
Fixes #594
* Android Resolver - Jetifier option is enabled by default now.
* Android Resolver - `Explode Aar` option applies to all cases, whether the
project will be exported or not.
Fixes #584
Fixes #287

# Version 1.2.175 - Nov 16, 2022
* General - Added tvOS podfile support to the iOS resolver.

# Version 1.2.174 - Oct 06, 2022
* General - Added tvOS support to the iOS resolver.
* General - Fixed #484 - Changed `EditorMeasurement` to use secure connection.
* Android Resolver - Fixed Android Resolver unable to resolve
`mainTemplate.gradle` in Unity `2022.2+` or `2023.1+`.

# Version 1.2.173 - Sep 28, 2022
* General - Added tvOS library support to the export unity package scripts.

# Version 1.2.172 - Jun 23, 2022
* iOS Resolver - Stop forcing `ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES` to `YES`,
which seems to cause problem for some when submitting apps. See #526 for more
information.

# Version 1.2.171 - May 11, 2022
* iOS Resolver - Change `Enable Swift Framework Support Workaround` setting to
be `ON` by default since more pods are using Swift Framework now.

# Version 1.2.170 - Apr 4, 2022
* Android Resolver - Fixes #498 - Fix the path separator of the Maven repo
injected to `mainTemplate.gradle`.
* iOS Resolver - Fixes #470 - Switch default Cocoapods master repo from Github
to CDN.
* iOS Resolver - `Link Framework Statically` setting is now default to `true`.
That is, `use_frameworks! :linkage => static` will be added to `Podfile` by
default instead of `use_frameworks!`. This can be changed in iOS Resolver
settings. This fixes odd behaviors when pods include static libraries, ex.
Firebase Analytics.
* iOS Resolver - Added a workaround when app crashes on launch due to
`Library not loaded: @rpath/libswiftCore.dylib` when some pods includes Swift
framework. This is turned `OFF` by default and can be changed in iOS Resolver
settings.

# Version 1.2.169 - Jan 20, 2022
* General - Fixes #425 - Change to save `GvhProjectSettings.xml` without
Unicode byte order mark (BoM).
* Android Resolver - Remove reference to `jcenter()`
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Binary file not shown.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ This causes the following problems:
Unity project can be complex and a burden on a Unity plugin maintainer.
* The process of resolving conflicting dependencies on platform specific
libraries is pushed to the developer attempting to use a Unity plugin.
The developer trying to use you plugin is very likely to give up when
The developer trying to use your plugin is very likely to give up when
faced with Android or iOS specific build errors.
* The process of resolving conflicting Unity plugins (due to shared Unity
plugin components) is pushed to the developer attempting to use your Unity
Expand All @@ -36,6 +36,9 @@ This causes the following problems:

EDM provides solutions for each of these problems.

If, after reading this, you need to debug usage of EDM in a Unity project,
consult the debugging [step-by-step guide](troubleshooting-faq.md).

## Android Dependency Management

The *Android Resolver* component of this plugin will download and integrate
Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
Assets/ExternalDependencyManager/Editor/1.2.177/Google.IOSResolver.dll
Assets/ExternalDependencyManager/Editor/1.2.177/Google.IOSResolver.dll.mdb
Assets/ExternalDependencyManager/Editor/1.2.177/Google.JarResolver.dll
Assets/ExternalDependencyManager/Editor/1.2.177/Google.JarResolver.dll.mdb
Assets/ExternalDependencyManager/Editor/1.2.177/Google.PackageManagerResolver.dll
Assets/ExternalDependencyManager/Editor/1.2.177/Google.PackageManagerResolver.dll.mdb
Assets/ExternalDependencyManager/Editor/1.2.177/Google.VersionHandlerImpl.dll
Assets/ExternalDependencyManager/Editor/1.2.177/Google.VersionHandlerImpl.dll.mdb
Assets/ExternalDependencyManager/Editor/CHANGELOG.md
Assets/ExternalDependencyManager/Editor/Google.VersionHandler.dll
Assets/ExternalDependencyManager/Editor/Google.VersionHandler.dll.mdb
Assets/ExternalDependencyManager/Editor/LICENSE
Assets/ExternalDependencyManager/Editor/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 6 additions & 0 deletions OneSignalExample/Assets/OneSignal/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
### Changed
- `InstallEdm4uStep` now imports version [1.2.177](https://github.com/googlesamples/unity-jar-resolver/releases/tag/v1.2.177) of [EDM4U](https://github.com/googlesamples/unity-jar-resolver)
- Updated included Android SDK to [5.0.1](https://github.com/OneSignal/OneSignal-Android-SDK/releases/tag/5.0.1)
### Fixed
- Sending VSAttribution data from the editor

## [5.0.2]
### Fixed
- Stop foreground notifications from displaying after calling prevent default on iOS
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,6 @@ public async void PromptForPush() {
_log("Notification permission accepeted");
else
_log("Notification permission denied");

_log($"Notification permission is: {OneSignal.Notifications.Permission}");
}

public void ClearPush() {
Expand All @@ -325,10 +323,16 @@ public void ClearPush() {
_log("Notifications cleared");
}

public void GetPermissionNative() {
public void GetNotificationsPermission() {
var permission = OneSignal.Notifications.Permission;

_log($"Notifications permission is: <b>{permission}</b>");
}

public void GetNotificationsPermissionNative() {
var permissionNative = OneSignal.Notifications.PermissionNative;

_log($"Permission Native is: <b>{permissionNative.ToString()}</b>");
_log($"Notifications native permission is: <b>{permissionNative.ToString()}</b>");
}

/*
Expand Down
Loading
Loading