labibramadhan / cordova-sunmi-inner-printer

29 stars 32 forks source link

Impossible to build, how to fix ? #7

Open lucydjo opened 6 years ago

lucydjo commented 6 years ago

27 actionable tasks: 4 executed, 23 up-to-date (node:3984) UnhandledPromiseRejectionWarning: Unhandled promise rejection (rejection id: 1): Error: /Users/lucaspojo/Documents/GitHub/hello/platforms/android/gradlew: Command failed with exit code 1 Error output: /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:12: error: package woyou.aidlservice.jiuiv5 does not exist import woyou.aidlservice.jiuiv5.ICallback; ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:13: error: package woyou.aidlservice.jiuiv5 does not exist import woyou.aidlservice.jiuiv5.IWoyouService; ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:35: error: cannot find symbol private IWoyouService woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:47: error: package IWoyouService does not exist woyouService = IWoyouService.Stub.asInterface(service); ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:159: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:164: error: package ICallback does not exist printerService.printerInit(new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:194: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:199: error: package ICallback does not exist printerService.printerSelfChecking(new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:238: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:252: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:267: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:281: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:287: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:292: error: package ICallback does not exist printerService.getPrintedLength(new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:322: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:328: error: package ICallback does not exist printerService.lineWrap(count, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:358: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:364: error: package ICallback does not exist printerService.sendRAWData(d, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:394: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:400: error: package ICallback does not exist printerService.setAlignment(align, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:430: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:436: error: package ICallback does not exist printerService.setFontName(tf, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:466: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:472: error: package ICallback does not exist printerService.setFontSize(fs, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:502: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:510: error: package ICallback does not exist printerService.printTextWithFont(txt, tf, fs, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:541: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:573: error: package ICallback does not exist printerService.printColumnsText(clst, clsw, clsa, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:604: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:611: error: package ICallback does not exist printerService.printBitmap(bitMap, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:646: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:657: error: package ICallback does not exist printerService.printBarCode(d, s, h, w, tp, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:687: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:695: error: package ICallback does not exist printerService.printQRCode(d, size, level, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:725: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:731: error: package ICallback does not exist printerService.printOriginalText(txt, new ICallback.Stub() { ^ /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:761: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:776: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:792: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:808: error: cannot find symbol final IWoyouService printerService = woyouService; ^ symbol: class IWoyouService location: class Printer /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/innerprinter/Printer.java:814: error: package ICallback does not exist printerService.printText(msgs, new ICallback.Stub() { ^ Note: /Users/lucaspojo/Documents/GitHub/hello/platforms/android/app/src/main/java/com/sunmi/utils/BitmapUtils.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. 41 errors

FAILURE: Build failed with an exception.

BUILD FAILED in 1s (node:3984) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

uokivan commented 5 years ago

I also have same case...

uokivan commented 5 years ago

Find the way to fix it, downgraded the android version by ionic cordova platform add android@6.3.0

https://github.com/labibramadhan/cordova-sunmi-inner-printer/issues/5

Thanks @labibramadhan

sarveshamrit commented 4 years ago

@lucaspojo @uokivan How did u solve this error in phonegap project