无法在iOS真实设备上的设备上应用更改

时间:2019-04-07 01:59:28

标签: ios nativescript

更改开发的tns run ios.cert文件后,我在真实设备上运行.mobileprovision错误。 我删除了keychain-access中的旧证书,然后双击.cert文件和.mobileprovision文件, 我什至将cli和tns-core-module更新到最新版本,但仍然无法正常工作。

有人可以帮助我吗?

我使用mac。 cli版本是5.3.1 xcode版本是10.1 我的package.json在这里:

"nativescript": {
    "id": "com.softbrain.discounteasy",
    "tns-android": {
      "version": "5.2.1"
    },
    "tns-ios": {
      "version": "5.3.1"
    }
  },
"dependencies": {
    "@angular/animations": "~7.1.0",
    "@angular/common": "~7.1.0",
    "@angular/compiler": "~7.1.0",
    "@angular/core": "~7.1.0",
    "@angular/forms": "~7.1.0",
    "@angular/http": "~7.1.0",
    "@angular/platform-browser": "~7.1.0",
    "@angular/platform-browser-dynamic": "~7.1.0",
    "@angular/router": "~7.1.0",
    "@danvick/ngx-translate-nativescript-loader": "^2.0.0",
    "@ngx-translate/core": "^11.0.1",
    "crypto-js": "^3.1.9-1",
    "nativescript-angular": "~7.1.0",
    "nativescript-clipboard": "^1.1.7",
    "nativescript-code-push": "^1.0.1",
    "nativescript-exit": "^1.0.1",
    "nativescript-feedback": "^1.3.5",
    "nativescript-hex-string": "0.0.4",
    "nativescript-imagepicker": "^6.1.2",
    "nativescript-localstorage": "^2.0.0",
    "nativescript-microsoft-appcenter": "^1.2.1",
    "nativescript-plugin-firebase": "^8.0.1",
    "nativescript-theme-core": "^1.0.4",
    "nativescript-toast": "^1.4.6",
    "nativescript-windowed-modal": "^5.0.6",
    "reflect-metadata": "~0.1.8",
    "rxjs": "~6.3.3",
    "rxjs-compat": "^6.4.0",
    "tns-core-modules": "^5.3.1",
    "tns-platform-declarations": "^5.1.2",
    "zone.js": "^0.8.26"
  },
  "devDependencies": {
    "@angular-devkit/core": "~7.1.0",
    "@angular/cli": "^7.1.0",
    "@angular/compiler-cli": "~7.1.0",
    "@nativescript/schematics": "~0.4.0",
    "@ngtools/webpack": "^7.1.4",
    "nativescript-dev-sass": "^1.6.0",
    "nativescript-dev-typescript": "~0.7.0",
    "nativescript-dev-webpack": "^0.19.0",
    "tns-android": "^5.1.0",
    "tns-ios": "^5.1.1",
    "typescript": "~3.1.1",
    "uglifyjs-webpack-plugin": "^2.1.1"
  },

以及此处的构建日志:

nativescript-plugin-firebase: /Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/.pluginfirebaseinfo not found, forcing prepare!
nativescript-plugin-firebase: running release build or change in environment detected, forcing prepare!
Detected short imports in your application. Please note that short imports are deprecated since NativeScript 5.2.0. More information can be found in this blogpost https://www.nativescript.org/blog/say-goodbye-to-short-imports-in-nativescript

In file /Users/softbraintechnologylimited/projects/DiscountEasyUI/app/pages/tabs/home-page/home-page/home-page.component.ts line import * as application from 'application' is short import. Add tns-core-modules/ in front of the required/imported module.

In file /Users/softbraintechnologylimited/projects/DiscountEasyUI/app/shared/pipes/image-cache.pipe.ts line import { ImageSource, fromResource } from 'image-source' is short import. Add tns-core-modules/ in front of the required/imported module.

In file /Users/softbraintechnologylimited/projects/DiscountEasyUI/app/shared/pipes/image-cache.pipe.ts line import { Cache } from 'ui/image-cache' is short import. Add tns-core-modules/ in front of the required/imported module.

In file /Users/softbraintechnologylimited/projects/DiscountEasyUI/app/shared/pipes/image-cache.pipe.ts line import { isFileOrResourcePath, isDataURI } from 'utils/utils' is short import. Add tns-core-modules/ in front of the required/imported module.

Hook skipped because either bundling or livesync is in progress.
Hook skipped because either bundling or livesync is in progress.
Preparing project...
Successfully prepared plugin nativescript-angular for ios.
Successfully prepared plugin nativescript-clipboard for ios.
Successfully prepared plugin nativescript-code-push for ios.
Successfully prepared plugin nativescript-feedback for ios.
Successfully prepared plugin nativescript-hex-string for ios.
Successfully prepared plugin nativescript-imagepicker for ios.
Successfully prepared plugin nativescript-localstorage for ios.
Successfully prepared plugin nativescript-microsoft-appcenter for ios.
Successfully prepared plugin nativescript-plugin-firebase for ios.
Successfully prepared plugin nativescript-theme-core for ios.
Successfully prepared plugin nativescript-toast for ios.
Successfully prepared plugin nativescript-windowed-modal for ios.
Successfully prepared plugin tns-core-modules for ios.
Successfully prepared plugin nativescript-intl for ios.
Successfully prepared plugin nativescript-appversion for ios.
Successfully prepared plugin nativescript-zip for ios.
nativescript-permissions is not supported for ios.
Successfully prepared plugin nativescript-permissions for ios.
Successfully prepared plugin tns-core-modules-widgets for ios.
Installing pods...
Analyzing dependencies
Pre-downloading: `ISMessages` from `https://github.com/EddyVerbruggen/ISMessages.git`, commit `580ac8cab611e2f92ebdd62b2201f9dada36ccd4`
Downloading dependencies
Installing AppCenter (1.14.0)
Installing Firebase (5.16.0)
Installing FirebaseAnalytics (5.5.0)
Installing FirebaseAnalyticsInterop (1.2.0)
Installing FirebaseCore (5.2.0)
Installing FirebaseInstanceID (3.7.0)
Installing FirebaseMessaging (3.3.0)
Installing GoogleAppMeasurement (5.5.0)
Installing GoogleUtilities (5.5.0)
Installing ISMessages (1.2)
Installing Protobuf (3.7.0)
Installing QBImagePickerController (3.4.0)
Installing SSZipArchive (2.1.4)
Installing Toaster (2.0.4)
Installing nanopb (0.3.901)
Generating Pods project
Integrating client project

[!] Please close any current Xcode sessions and use `DiscountEasyUI.xcworkspace` for this project from now on.
Sending stats
Pod installation complete! There are 7 dependencies from the Podfile and 15 total pods installed.
Project successfully prepared (iOS)
Configure firebase
Android not installed, skipping CodePush hook.
Building project...
Xcode build...
2019-04-06 09:39:21.580 xcodebuild[1297:29067]  DTDeviceKit: deviceType from df1b668dc0b68ae30113d5198979559ab1938293 was NULL
warning: Swift 3 mode has been deprecated and will be removed in a later version of Xcode. Please migrate "Toaster" to Swift 4.2 using "Convert > To Current Swift Syntax…" in the Edit menu. (in target 'Toaster')
warning: Swift 3 mode has been deprecated and will be removed in a later version of Xcode. Please migrate "Toaster" to Swift 4.2 using "Convert > To Current Swift Syntax…" in the Edit menu. (in target 'Toaster')
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastWindow.swift:24:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let shared = ToastWindow(frame: UIScreen.main.bounds)
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Toaster/Sources/ToastCenter.swift:36:19: warning: static declarations are implicitly 'final'; use 'public' instead of 'open'
  open static let `default` = ToastCenter()
  ~~~~            ^
  public
/Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/ISMessages/ISMessages/Classes/ISMessages.m:198:1: warning: conflicting return type in
      implementation of 'accessibilityPerformEscape': 'BOOL' (aka 'signed char') vs 'bool' [-Wmismatched-return-types]
- (bool)accessibilityPerformEscape {
^  ~~~~
In module 'UIKit' imported from /Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/Pods/Target Support Files/ISMessages/ISMessages-prefix.pch:2:
/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS12.1.sdk/System/Library/Frameworks/UIKit.framework/Headers/UIAccessibility.h:276:1: note: 
      previous definition is here
- (BOOL)accessibilityPerformEscape NS_AVAILABLE_IOS(5_0);
^  ~~~~
1 warning generated.
note: Using new build systemnote: Planning buildnote: Constructing build description
Xcode build...
2019-04-06 09:40:04.685 xcodebuild[3913:36112] [MT] IDEDistribution: -[IDEDistributionLogging _createLoggingBundleAtPath:]: Created bundle at path '/var/folders/qx/nqzfs3217731kb43q_pcpvfh0000gn/T/DiscountEasyUI_2019-04-06_09-40-04.685.xcdistributionlogs'.
Exported DiscountEasyUI to: /Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/build/Debug-iphoneos
Project successfully built.
Installing on device df1b668dc0b68ae30113d5198979559ab1938293...
Unable to apply changes on device: df1b668dc0b68ae30113d5198979559ab1938293. Error is: Failed to install /Users/softbraintechnologylimited/projects/DiscountEasyUI/platforms/ios/build/Debug-iphoneos/DiscountEasyUI.ipa on device with identifier df1b668dc0b68ae30113d5198979559ab1938293. Error is: Could not install application.

1 个答案:

答案 0 :(得分:0)

该配置文件中是否包含该设备?将配置文件拖动到TextEdit应用程序中,然后查找:

<key>ProvisionedDevices</key>

此后是否列出了df1b668dc0b68ae30113d5198979559ab1938293?如果不是,请在Apple Developer Portal中更新配置文件以包括您的设备。然后,使用更新的配置文件重试。

我认为无法安装应用程序的唯一其他原因是设备不符合最低要求。例如,如果设备的iOS版本小于应用程序的最低部署版本。

要查看有关安装失败的更多信息,请打开控制台应用程序( 非终端机 ),将未锁定的电话连接到计算机,然后在中选择设备控制台应用程序。尝试再次安装该应用。

在“控制台”窗口顶部的“搜索”框中,输入应用程序的名称,然后按Enter键以基于该名称过滤日志。

Search box

您将看到很多文本,其中包含有关安装的详细信息。看起来像这样,但是应该在某处指示错误:

default 23:04:32.280735 -0400   streaming_zip_conduit   com.mycompany.SuperApp:5:1:1:1:Beginning installation for file:///var/mobile/Media/PublicStaging/SuperApp.app/ with options {
    AllowInstallLocalProvisioned = 1;
    CFBundleIdentifier = "com.mycompany.SuperApp";
    DisableDeltaTransfer = 1;
    InstallDeltaTypeKey = InstallDeltaTypeSparseIPAFiles;
    IsUserInitiated = 1;
    PackageType = Developer;
}
default 23:04:32.288006 -0400   lsd com.mycompany.SuperApp:5:1:1:1:Ininstall file:///var/mobile/Media/PublicStaging/SuperApp.app/ with options {
    AllowInstallLocalProvisioned = 1;
    CFBundleIdentifier = "com.mycompany.SuperApp";
    DisableDeltaTransfer = 1;
    InstallDeltaTypeKey = InstallDeltaTypeSparseIPAFiles;
    IsUserInitiated = 1;
    PackageType = Developer;
}
default 23:04:32.289279 -0400   lsd com.mycompany.SuperApp:5:1:1:1:Ininstall file:///var/mobile/Media/PublicStaging/SuperApp.app/ with options {
    AllowInstallLocalProvisioned = 1;
    CFBundleIdentifier = "com.mycompany.SuperApp";
    DisableDeltaTransfer = 1;
    InstallDeltaTypeKey = InstallDeltaTypeSparseIPAFiles;
    IsUserInitiated = 1;
    PackageType = Developer;
}
default 23:04:32.292304 -0400   installd    0x16b15f000 -[MIClientConnection _doInstallationForURL:withOptions:completion:]: Install of "/var/mobile/Media/PublicStaging/SuperApp.app" type Developer (LSInstallType = (null)) requested by lsd (pid 31819)
default 23:04:32.306147 -0400   assertiond  Request to create termination assertion <BKSTerminationAssertionCreateEvent: 0x105ec9a00; Identifier: 29899-552C42A1-9731-49B7-B96B-41A0B2D360AB; Name: FBSApplicationTerminationAssertion; Target BundleID: com.mycompany.SuperApp; Efficacy: Unconditional> from client <BKClientHandle: 0x105f0da40; installd:29899; connections: 1>
default 23:04:32.309880 -0400   SpringBoard termination assertion efficacy for com.mycompany.SuperApp (app not found) changed to 3
default 23:04:32.310150 -0400   installd    Acquired termination assertion for event <BKSTerminationAssertionCreateEvent: 0x10a802170; Identifier: 29899-552C42A1-9731-49B7-B96B-41A0B2D360AB; Name: FBSApplicationTerminationAssertion; Target BundleID: com.mycompany.SuperApp; Efficacy: Unconditional>
default 23:04:32.321511 -0400   installd    0x16b15f000 -[MIInstaller performInstallationWithError:]: Installing <MIInstallableBundle ID=com.mycompany.SuperApp; Version=1, ShortVersion=1.0>
default 23:04:32.321804 -0400   installd    com.mycompany.SuperApp:7:5:1:1:Start : Install (New)
default 23:04:32.822905 -0400   installd    0x16b15f000 -[MIContainer makeContainerLiveReplacingContainer:reason:waitForDeletion:withError:]: Made container live for com.mycompany.SuperApp at /private/var/mobile/Containers/Data/Application/E18E5DFA-A7E2-4B20-AA88-571213D25CA4
default 23:04:32.827238 -0400   installd    0x16b15f000 -[MIContainer makeContainerLiveReplacingContainer:reason:waitForDeletion:withError:]: Made container live for com.mycompany.SuperApp at /private/var/containers/Bundle/Application/53C45EA1-44C3-4AAE-BD6E-72EE3F82B8BA
default 23:04:32.859543 -0400   installd    com.mycompany.SuperApp:7:5:2:1:Success (End) : Install (New)
default 23:04:32.859738 -0400   installd    0x16b15f000 -[MIInstaller performInstallationWithError:]: Install Successful for (Developer:com.mycompany.SuperApp); Staging: 0.01s; Waiting: 0.00s; Preflight/Patch: 0.01s, Verifying: 0.46s; Overall: 0.57s

那里应该有更多线索。

相关问题