質問編集履歴

5

誤記修正

2018/12/17 08:00

投稿

hw_test
hw_test

スコア13

test CHANGED
@@ -1 +1 @@
1
- xcodeのソースを新しいverの環境へ移すとThread 1:signal SIGABRTが出力され
1
+ xcodeのソースを新しいverの環境へ移すと落ち
test CHANGED
@@ -1,6 +1,4 @@
1
- xcodeのソースを新しいverの環境へ移すとThread 1:signal SIGABRT出力されてしまい
1
+ xcodeのソースを新しいverの環境へ移すと実行時にアプリ起動直後に止まってしまいます。
2
-
3
- アプリが起動直後に止まってしまいます。
4
2
 
5
3
 
6
4
 
@@ -30,11 +28,7 @@
30
28
 
31
29
 
32
30
 
33
- 問題としては、新しいverの環境だとxcodeの実行を押すとThread 1:signal SIGABRTと出力され、
34
-
35
- 一番初め画面が表示されたまま次の面へ遷移しません。
31
+ 問題箇所
36
-
37
-
38
32
 
39
33
  ```main.m
40
34
 
@@ -52,15 +46,11 @@
52
46
 
53
47
  ```
54
48
 
55
- 上記のreturnの行でThread 1:signal SIGABRTが出おり、この行を消して実行してもそこで同じエラーが出した
49
+ 上記のreturnの行で落ち
56
50
 
57
51
 
58
52
 
59
- Output画面には以下の2つのエラーも出力されていました。
53
+ Output画面には以下のエラーも出力されていました。
60
-
61
-
62
-
63
- Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application window are excepted to have a root view controller at the end of application launch'
64
54
 
65
55
 
66
56
 
@@ -75,149 +65,3 @@
75
65
  特に何もエラーは出ていませんでした。
76
66
 
77
67
  https://teratail.com/questions/8372
78
-
79
-
80
-
81
- 2018/12/14 追記
82
-
83
-
84
-
85
- エラー詳細
86
-
87
- ```
88
-
89
- 2018-12-14 10:45:00.622204+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> willMoveToParentViewController <JASidePanelController: 0x102844600>
90
-
91
- 2018-12-14 10:45:00.622391+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> didMoveToParentViewController <JASidePanelController: 0x102844600>
92
-
93
- 2018-12-14 10:45:00.654390+0900 WeldingManagementSystem[1512:961641] <WeldListViewController: 0x10170dca0> willMoveToParentViewController <UINavigationController: 0x10181f800>
94
-
95
- 2018-12-14 10:45:00.764714+0900 WeldingManagementSystem[1512:961641] *** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKitCore/UIKit-3698.93.8/UIApplication.m:3855
96
-
97
- 2018-12-14 10:45:00.765230+0900 WeldingManagementSystem[1512:961641] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
98
-
99
- *** First throw call stack:
100
-
101
- (0x1d2fdfea0 0x1d21b1a40 0x1d2ef5c1c 0x1d39e3140 0x1ffda3710 0x1ff63f358 0x1ff647fd8 0x1ff63efd4 0x1ff63f974 0x1ff63da74 0x1ff63d720 0x1ff6428e0 0x1ff643840 0x1ff642798 0x1ff647684 0x1ffda17a0 0x1ff98abac 0x1d5a149d4 0x1d5a1f79c 0x1d5a1ee94 0x101614dc8 0x101618a10 0x1d5a53a9c 0x1d5a53728 0x1d5a53d44 0x1d2f701cc 0x1d2f7014c 0x1d2f6fa30 0x1d2f6a8fc 0x1d2f6a1cc 0x1d51e1584 0x1ffda5054 0x100ecfcd0 0x1d2a2abb4)
102
-
103
- libc++abi.dylib: terminating with uncaught exception of type NSException
104
-
105
- (lldb)
106
-
107
-
108
-
109
- ```
110
-
111
-
112
-
113
- 画面表示部分ソース
114
-
115
- ```
116
-
117
- - (BOOL)application:(UIApplication *)application
118
-
119
- didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
120
-
121
- self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
122
-
123
-
124
-
125
- // ウィンドウ初期化 おためし
126
-
127
- //self.window.rootViewController = [UIViewController new];
128
-
129
-
130
-
131
- // SidePanelの初期設定
132
-
133
- self.sidePenelController = [[JASidePanelController alloc] init];
134
-
135
- self.sidePenelController.shouldDelegateAutorotateToVisiblePanel = NO;
136
-
137
- self.sidePenelController.allowLeftSwipe = NO;
138
-
139
- self.sidePenelController.leftPanel = [[LeftMenuViewController alloc] init];
140
-
141
- self.sidePenelController.centerPanel = [[UINavigationController alloc]
142
-
143
- initWithRootViewController:[[WeldListViewController alloc] init]];
144
-
145
-
146
-
147
- self.window.rootViewController = self.sidePenelController;
148
-
149
- [self.window makeKeyAndVisible];
150
-
151
-
152
-
153
- // NavigationBarの背景画像を設定する
154
-
155
- UIImage *image = [UIImage imageNamed:@"bg_navigationbar.png"];
156
-
157
- [[UINavigationBar appearance] setBackgroundImage:image
158
-
159
- forBarMetrics:UIBarMetricsDefault];
160
-
161
- [[UINavigationBar appearance]
162
-
163
- setTintColor:[CommonFunction hexToUIColor:@"FFFFFF" alpha:1.0]];
164
-
165
-
166
-
167
- // NavigationBarのタイトルフォントを変更する
168
-
169
- [[UINavigationBar appearance]
170
-
171
- setTitleTextAttributes:
172
-
173
- [NSDictionary
174
-
175
- dictionaryWithObjectsAndKeys:
176
-
177
- [UIFont boldSystemFontOfSize:30],UITextAttributeFont,
178
-
179
- [CommonFunction hexToUIColor:TITLE_BAR_TEXT_COLOR
180
-
181
- alpha:1.0], // タイトルの文字色
182
-
183
- NSForegroundColorAttributeName,
184
-
185
- nil, // シャドウの色
186
-
187
- NSShadowAttributeName, // シャドウの強さ(x, y)
188
-
189
- nil
190
-
191
- ]];
192
-
193
-
194
-
195
- // NSUserDefaultsに初期値を登録する
196
-
197
- NSUserDefaults *ud = [NSUserDefaults standardUserDefaults];
198
-
199
- NSMutableDictionary *defaults = [NSMutableDictionary dictionary];
200
-
201
- [defaults setObject:@"FALSE" forKey:KEY_LOGIN_OK];
202
-
203
- [ud registerDefaults:defaults];
204
-
205
-
206
-
207
- // DBの初回open
208
-
209
- if (![self firstOpenDatabase]) {
210
-
211
- [CommonFunction errAlertShow:ERR_DB_OPEN_ERROR];
212
-
213
- }
214
-
215
-
216
-
217
- return YES;
218
-
219
- }
220
-
221
-
222
-
223
- ```

4

コメント追記

2018/12/17 08:00

投稿

hw_test
hw_test

スコア13

test CHANGED
File without changes
test CHANGED
@@ -82,7 +82,9 @@
82
82
 
83
83
 
84
84
 
85
- ```エラー詳細
85
+ エラー詳細
86
+
87
+ ```
86
88
 
87
89
  2018-12-14 10:45:00.622204+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> willMoveToParentViewController <JASidePanelController: 0x102844600>
88
90
 
@@ -106,7 +108,11 @@
106
108
 
107
109
  ```
108
110
 
111
+
112
+
109
- ```画面表示部分ソース
113
+ 画面表示部分ソース
114
+
115
+ ```
110
116
 
111
117
  - (BOOL)application:(UIApplication *)application
112
118
 

3

詳細追記

2018/12/14 02:18

投稿

hw_test
hw_test

スコア13

test CHANGED
File without changes
test CHANGED
@@ -80,6 +80,32 @@
80
80
 
81
81
  2018/12/14 追記
82
82
 
83
+
84
+
85
+ ```エラー詳細
86
+
87
+ 2018-12-14 10:45:00.622204+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> willMoveToParentViewController <JASidePanelController: 0x102844600>
88
+
89
+ 2018-12-14 10:45:00.622391+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> didMoveToParentViewController <JASidePanelController: 0x102844600>
90
+
91
+ 2018-12-14 10:45:00.654390+0900 WeldingManagementSystem[1512:961641] <WeldListViewController: 0x10170dca0> willMoveToParentViewController <UINavigationController: 0x10181f800>
92
+
93
+ 2018-12-14 10:45:00.764714+0900 WeldingManagementSystem[1512:961641] *** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKitCore/UIKit-3698.93.8/UIApplication.m:3855
94
+
95
+ 2018-12-14 10:45:00.765230+0900 WeldingManagementSystem[1512:961641] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
96
+
97
+ *** First throw call stack:
98
+
99
+ (0x1d2fdfea0 0x1d21b1a40 0x1d2ef5c1c 0x1d39e3140 0x1ffda3710 0x1ff63f358 0x1ff647fd8 0x1ff63efd4 0x1ff63f974 0x1ff63da74 0x1ff63d720 0x1ff6428e0 0x1ff643840 0x1ff642798 0x1ff647684 0x1ffda17a0 0x1ff98abac 0x1d5a149d4 0x1d5a1f79c 0x1d5a1ee94 0x101614dc8 0x101618a10 0x1d5a53a9c 0x1d5a53728 0x1d5a53d44 0x1d2f701cc 0x1d2f7014c 0x1d2f6fa30 0x1d2f6a8fc 0x1d2f6a1cc 0x1d51e1584 0x1ffda5054 0x100ecfcd0 0x1d2a2abb4)
100
+
101
+ libc++abi.dylib: terminating with uncaught exception of type NSException
102
+
103
+ (lldb)
104
+
105
+
106
+
107
+ ```
108
+
83
109
  ```画面表示部分ソース
84
110
 
85
111
  - (BOOL)application:(UIApplication *)application
@@ -90,7 +116,7 @@
90
116
 
91
117
 
92
118
 
93
- // ウィンドウ初期化 h.honda
119
+ // ウィンドウ初期化 おためし
94
120
 
95
121
  //self.window.rootViewController = [UIViewController new];
96
122
 
@@ -189,29 +215,3 @@
189
215
 
190
216
 
191
217
  ```
192
-
193
-
194
-
195
- ```エラー詳細
196
-
197
- 2018-12-14 10:45:00.622204+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> willMoveToParentViewController <JASidePanelController: 0x102844600>
198
-
199
- 2018-12-14 10:45:00.622391+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> didMoveToParentViewController <JASidePanelController: 0x102844600>
200
-
201
- 2018-12-14 10:45:00.654390+0900 WeldingManagementSystem[1512:961641] <WeldListViewController: 0x10170dca0> willMoveToParentViewController <UINavigationController: 0x10181f800>
202
-
203
- 2018-12-14 10:45:00.764714+0900 WeldingManagementSystem[1512:961641] *** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKitCore/UIKit-3698.93.8/UIApplication.m:3855
204
-
205
- 2018-12-14 10:45:00.765230+0900 WeldingManagementSystem[1512:961641] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
206
-
207
- *** First throw call stack:
208
-
209
- (0x1d2fdfea0 0x1d21b1a40 0x1d2ef5c1c 0x1d39e3140 0x1ffda3710 0x1ff63f358 0x1ff647fd8 0x1ff63efd4 0x1ff63f974 0x1ff63da74 0x1ff63d720 0x1ff6428e0 0x1ff643840 0x1ff642798 0x1ff647684 0x1ffda17a0 0x1ff98abac 0x1d5a149d4 0x1d5a1f79c 0x1d5a1ee94 0x101614dc8 0x101618a10 0x1d5a53a9c 0x1d5a53728 0x1d5a53d44 0x1d2f701cc 0x1d2f7014c 0x1d2f6fa30 0x1d2f6a8fc 0x1d2f6a1cc 0x1d51e1584 0x1ffda5054 0x100ecfcd0 0x1d2a2abb4)
210
-
211
- libc++abi.dylib: terminating with uncaught exception of type NSException
212
-
213
- (lldb)
214
-
215
-
216
-
217
- ```

2

エラー詳細と画面作成のソース追加

2018/12/14 02:17

投稿

hw_test
hw_test

スコア13

test CHANGED
File without changes
test CHANGED
@@ -75,3 +75,143 @@
75
75
  特に何もエラーは出ていませんでした。
76
76
 
77
77
  https://teratail.com/questions/8372
78
+
79
+
80
+
81
+ 2018/12/14 追記
82
+
83
+ ```画面表示部分ソース
84
+
85
+ - (BOOL)application:(UIApplication *)application
86
+
87
+ didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
88
+
89
+ self.window = [[UIWindow alloc] initWithFrame:[[UIScreen mainScreen] bounds]];
90
+
91
+
92
+
93
+ // ウィンドウ初期化 h.honda
94
+
95
+ //self.window.rootViewController = [UIViewController new];
96
+
97
+
98
+
99
+ // SidePanelの初期設定
100
+
101
+ self.sidePenelController = [[JASidePanelController alloc] init];
102
+
103
+ self.sidePenelController.shouldDelegateAutorotateToVisiblePanel = NO;
104
+
105
+ self.sidePenelController.allowLeftSwipe = NO;
106
+
107
+ self.sidePenelController.leftPanel = [[LeftMenuViewController alloc] init];
108
+
109
+ self.sidePenelController.centerPanel = [[UINavigationController alloc]
110
+
111
+ initWithRootViewController:[[WeldListViewController alloc] init]];
112
+
113
+
114
+
115
+ self.window.rootViewController = self.sidePenelController;
116
+
117
+ [self.window makeKeyAndVisible];
118
+
119
+
120
+
121
+ // NavigationBarの背景画像を設定する
122
+
123
+ UIImage *image = [UIImage imageNamed:@"bg_navigationbar.png"];
124
+
125
+ [[UINavigationBar appearance] setBackgroundImage:image
126
+
127
+ forBarMetrics:UIBarMetricsDefault];
128
+
129
+ [[UINavigationBar appearance]
130
+
131
+ setTintColor:[CommonFunction hexToUIColor:@"FFFFFF" alpha:1.0]];
132
+
133
+
134
+
135
+ // NavigationBarのタイトルフォントを変更する
136
+
137
+ [[UINavigationBar appearance]
138
+
139
+ setTitleTextAttributes:
140
+
141
+ [NSDictionary
142
+
143
+ dictionaryWithObjectsAndKeys:
144
+
145
+ [UIFont boldSystemFontOfSize:30],UITextAttributeFont,
146
+
147
+ [CommonFunction hexToUIColor:TITLE_BAR_TEXT_COLOR
148
+
149
+ alpha:1.0], // タイトルの文字色
150
+
151
+ NSForegroundColorAttributeName,
152
+
153
+ nil, // シャドウの色
154
+
155
+ NSShadowAttributeName, // シャドウの強さ(x, y)
156
+
157
+ nil
158
+
159
+ ]];
160
+
161
+
162
+
163
+ // NSUserDefaultsに初期値を登録する
164
+
165
+ NSUserDefaults *ud = [NSUserDefaults standardUserDefaults];
166
+
167
+ NSMutableDictionary *defaults = [NSMutableDictionary dictionary];
168
+
169
+ [defaults setObject:@"FALSE" forKey:KEY_LOGIN_OK];
170
+
171
+ [ud registerDefaults:defaults];
172
+
173
+
174
+
175
+ // DBの初回open
176
+
177
+ if (![self firstOpenDatabase]) {
178
+
179
+ [CommonFunction errAlertShow:ERR_DB_OPEN_ERROR];
180
+
181
+ }
182
+
183
+
184
+
185
+ return YES;
186
+
187
+ }
188
+
189
+
190
+
191
+ ```
192
+
193
+
194
+
195
+ ```エラー詳細
196
+
197
+ 2018-12-14 10:45:00.622204+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> willMoveToParentViewController <JASidePanelController: 0x102844600>
198
+
199
+ 2018-12-14 10:45:00.622391+0900 WeldingManagementSystem[1512:961641] <LeftMenuViewController: 0x102016d20> didMoveToParentViewController <JASidePanelController: 0x102844600>
200
+
201
+ 2018-12-14 10:45:00.654390+0900 WeldingManagementSystem[1512:961641] <WeldListViewController: 0x10170dca0> willMoveToParentViewController <UINavigationController: 0x10181f800>
202
+
203
+ 2018-12-14 10:45:00.764714+0900 WeldingManagementSystem[1512:961641] *** Assertion failure in -[UIApplication _runWithMainScene:transitionContext:completion:], /BuildRoot/Library/Caches/com.apple.xbs/Sources/UIKitCore/UIKit-3698.93.8/UIApplication.m:3855
204
+
205
+ 2018-12-14 10:45:00.765230+0900 WeldingManagementSystem[1512:961641] *** Terminating app due to uncaught exception 'NSInternalInconsistencyException', reason: 'Application windows are expected to have a root view controller at the end of application launch'
206
+
207
+ *** First throw call stack:
208
+
209
+ (0x1d2fdfea0 0x1d21b1a40 0x1d2ef5c1c 0x1d39e3140 0x1ffda3710 0x1ff63f358 0x1ff647fd8 0x1ff63efd4 0x1ff63f974 0x1ff63da74 0x1ff63d720 0x1ff6428e0 0x1ff643840 0x1ff642798 0x1ff647684 0x1ffda17a0 0x1ff98abac 0x1d5a149d4 0x1d5a1f79c 0x1d5a1ee94 0x101614dc8 0x101618a10 0x1d5a53a9c 0x1d5a53728 0x1d5a53d44 0x1d2f701cc 0x1d2f7014c 0x1d2f6fa30 0x1d2f6a8fc 0x1d2f6a1cc 0x1d51e1584 0x1ffda5054 0x100ecfcd0 0x1d2a2abb4)
210
+
211
+ libc++abi.dylib: terminating with uncaught exception of type NSException
212
+
213
+ (lldb)
214
+
215
+
216
+
217
+ ```

1

誤記修正

2018/12/14 02:16

投稿

hw_test
hw_test

スコア13

test CHANGED
@@ -1 +1 @@
1
- xcodeを新しいverの環境へ移すとThread 1:signal SIGABRTが出力される
1
+ xcodeのソースを新しいverの環境へ移すとThread 1:signal SIGABRTが出力される
test CHANGED
@@ -1,4 +1,4 @@
1
- xcodeを新しいverの環境へ移すとThread 1:signal SIGABRTが出力されてしまい
1
+ xcodeのソースを新しいverの環境へ移すとThread 1:signal SIGABRTが出力されてしまい
2
2
 
3
3
  アプリが起動直後に止まってしまいます。
4
4