parse-community / Parse-SDK-dotNET

Parse SDK for .NET, Xamarin, Unity.
http://parseplatform.org
Apache License 2.0
323 stars 261 forks source link

resolved issue " Xamarin project error System.EntryPointNotFoundException: GetModuleFileName" #317

Closed hirenvyas closed 4 years ago

hirenvyas commented 5 years ago
codecov[bot] commented 5 years ago

Codecov Report

Merging #317 into master will increase coverage by 0.04%. The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #317      +/-   ##
==========================================
+ Coverage   58.77%   58.81%   +0.04%     
==========================================
  Files          91       91              
  Lines        6128     6134       +6     
==========================================
+ Hits         3602     3608       +6     
  Misses       2526     2526
Impacted Files Coverage Δ
Parse/Public/ParseClient.cs 75.86% <100%> (+1.78%) :arrow_up:

Continue to review full report at Codecov.

Legend - Click here to learn more Δ = absolute <relative> (impact), ø = not affected, ? = missing data Powered by Codecov. Last update 077b48e...26c70a5. Read the comment docs.

TobiasPott commented 5 years ago

Hi @hirenvyas could you elaborate on what this changes do and which problems it addresses? Does it only apply to the Xamarin workflow or did you do any checks on .NET Standard or .NET Framework 4.x or even Unity?

hirenvyas commented 5 years ago

hello @TobiasPott : On Past When I used that Package I got error " Xamarin project error System.EntryPointNotFoundException: GetModuleFileName: on my Android project its work great for iOS , The issue behind is Assembly not getting entry point to load in Android platform.

TobiasPott commented 5 years ago

@Hiren-Vyas I see the problem and similar issues happen when using the GetEntryAssembly() inside Unity3D projects targeting mobile platforms.

Unfortunately this does not finally solve #300. Alex described his assumption about the cause being the calling assembly in case of Xamarin (I'll support this assumption).

If we took the GetExecutingAssembly() solution you suggest the parse caching and internal information (specific everything in VersionInformation struct) will use the information of the Parse.dll instead of the actual application running the Parse code. As far as I understand the current state and would expect it to be, the information should reflect the actual applications info (e.g. your xamarin app name and versioning).

To solve this issue in a broader way it is necessary to add additional configuration or build options to the Parse SDK assembly. I'm doing it in a very rough way for our Unity3D applications and could imagine that some sort of platform configuration can be derived from it.

TobiasPott commented 4 years ago

Due to upcoming changes to the repository and the incompleteness of this pull request, the changes included will not be applied. It should be possible to use the Parse SDK with Xamarin for platforms like Android and iOS alike.

If new problems arise in the future please create a new issue to discuss solutions or create a pull request to provide fixes.