triniwiz / triniwiz/nativescript-plugins
[@triniwiz/nativescript-image-cache-it][IOS] bug in iOS, ImageCacheIt tag crash release version
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 87
- Forks
- 57
- Avg merge
- 1h 36m
- Merged PRs (30d)
- 4
Description
In the context of the issue, the functionality in the HTML file associated with ImageCacheIt is not functioning as expected, whereas the Image tag is operating correctly.
Currently, I am encountering challenges with the implementation of ImageCacheIt on iOS. Despite having attached a StackBlitz project for reference, there are persisting issues:
The tab functionality within the HTML file associated with ImageCacheIt is non-functional, whereas the standard tag operates correctly.
Upon attempting to launch the release version of the iOS application ns build ios --bundle --env.uglify --env.aot --release --forDevice , the application crashes
NPM version 10.4.0
Nativescript version : 8.6.5
Node.js v20.11.0
Tried on Xcode version 15.1 & 15.2
Package.json :
{
"name": "UploadTest",
"main": "./src/main.ts",
"version": "1.0.0",
"private": true,
"dependencies": {
"@angular/animations": "~16.2.0",
"@angular/common": "~16.2.0",
"@angular/compiler": "~16.2.0",
"@angular/core": "~16.2.0",
"@angular/forms": "~16.2.0",
"@angular/platform-browser": "~16.2.0",
"@angular/platform-browser-dynamic": "~16.2.0",
"@angular/router": "~16.2.0",
"@nativescript-community/ui-document-picker": "^1.1.17",
"@nativescript/angular": "^16.0.0",
"@nativescript/core": "~8.6.0",
"@nativescript/theme": "~3.0.2",
"@triniwiz/nativescript-image-cache-it": "^7.5.0",
"rxjs": "~7.8.0",
"zone.js": "~0.13.0"
},
"devDependencies": {
"@angular-devkit/build-angular": "~16.2.0",
"@angular/compiler-cli": "~16.2.0",
"@nativescript/android": "8.6.2",
"@nativescript/ios": "8.6.3",
"@nativescript/types": "~8.6.0",
"@nativescript/webpack": "~5.0.18",
"@ngtools/webpack": "~16.2.0",
"typescript": "~5.1.6"
}
}
I'm also attaching Sample project to reproduce error : src.zip
possible error could be :
Xcode build...
/Users/pap/Documents/Temp Project /UploadTest/platforms/ios/Pods/SDWebImage/SDWebImage/Core/SDWebImageDefine.m:16:65: warning:
a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
static inline NSArray<NSNumber *> * _Nonnull SDImageScaleFactors() {
^
void
1 warning generated.
/Users/pap/Documents/Temp Project /UploadTest/platforms/ios/Pods/SDWebImage/SDWebImage/Private/SDImageAssetManager.m:12:40: warning:
a function declaration without a prototype is deprecated in all versions of C [-Wstrict-prototypes]
static NSArray *SDBundlePreferredScales() {
^
void
1 warning generated.
/Users/pap/Documents/Temp Project /UploadTest/node_modules/@triniwiz/nativescript-image-cache-it/platforms/ios/src/NSURLExt.swift:8:51: warning: forming 'UnsafeRawPointer' to a variable of type 'Optional<String>'; this is likely incorrect because 'Optional<String>' may contain an object reference.
return objc_getAssociatedObject(self, &NSURLProps.uuid) as? String
^
/Users/pap/Documents/Temp Project /UploadTest/node_modules/@triniwiz/nativescript-image-cache-it/platforms/ios/src/NSURLExt.swift:12:48: warning: forming 'UnsafeRawPointer' to a variable of type 'Optional<String>'; this is likely incorrect because 'Optional<String>' may contain an object reference.
objc_setAssociatedObject(self, &NSURLProps.uuid, unwrappedValue as NSString?, .OBJC_ASSOCIATION_RETAIN_NONATOMIC)
any workaround to fix this error ASAP
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the attached sample and src/app/item/items.component.html, then reproduce the iOS release build using the reported NativeScript command. Inspect the ImageCacheIt iOS code, including NSURLExt.swift, and determine whether the tab failure and release crash share a cause. Done means the ImageCacheIt tab works and the release iOS application launches without crashing.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- angular, ios, swift, typescript
- Domain
- mobile-dev
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100