*error TS1003: Identifier expected - angular-calendar

I am following this tutorial enter link description here for an angular calender app. I am stuck in an error that contains this error in the compille time:
error TS1003: Identifier expected. when i try to import
import { ... } from 'angular-calendar-scheduler';.
I dont know what is the problem.
Any help will be appreciated!

Related

Initialization error with CDYelpFusionKit

Trying to use the CDYelpFusionKit api for an app, and I'm getting an error on the first step:
let yelpAPIClient = CDYelpAPIClient(apiKey: "myapikeyhere")
It's saying that it's an
Use of unresolved identifier 'CDYelpAPIClient'
but I have already installed the dependencies with cocoapods.
You also need to import the framework
import CDYelpFusionKit

NSUrlErrorDomain can't find the code and how to deal with it anywhere

This is the error code I'm getting when I try to pull data from a server, while debugging on my device through Xcode.
error NSError? domain: "NSURLErrorDomain" - code: 4294966274 0x15d9ae90
What does it mean? How I solve it?
I found this site with a list of enums
https://developer.apple.com/reference/foundation/foundation_constants/1508628-url_loading_system_error_codes
But it doesn't give numbers only the enum strings.

Parse local datastore doesn't work - Swift 2

I am currently using the latest version of Parse 1.14.2 and Bolts 1.8.4.Parse is implemented correctly and I have been using it for a long time now. The problem I'm facing now is when I try to use Parse's local datastore. I have the following code in my AppDelegate.swift:
Parse.enableLocalDatastore()
Parse.setApplicationId("ID",
clientKey: "Client_Key")
I have the following code to create and save a string named firstName in a class named contact:
let contact = PFObject(className: "contact")
contact["firstName"] = "Jack"
contact.pinInBackground()
Here is the code to retrieve objects from the created class:
let query = PFQuery(className: "contact")
query.fromLocalDatastore()
query.getFirstObjectInBackgroundWithBlock({ (object, error) -> Void in
if error == nil {
if let contact = object {
print(contact.objectForKey("firstName"))
}
}
})
I have added libsqlite3.dylib to my project. My app doesn't crash when I run this code but it simply gives me the following message when I try to retrieve objects:
2016-08-29 11:31:38.049 App_Demo[14436:3504319] [Bolts] Warning: `BFTask` caught an exception in the continuation block.
This behavior is discouraged and will be removed in a future release.
Caught Exception: Method requires Pinning enabled.
Can anyone help me to work around this issue? I am guessing the issue is that this version of Bolts cannot pin Parse objects in the background and I need to work my way around this bug. Any help would be appreciated as I have been stuck at this for a while and can't find too much info online.
Edited: I have tried downgrading Bolts, but then Parse downgrades with it in Cocoapod and it causes errors in Xcode.
it's not objectforkey.
You need to call object["UsedName"] "UsedName" being the key. Hope that helps.

(Swift) 'use of unresolved identifier 'FIRStorage'

I am using firebase and I have the following line of code:
let storageRef = FIRStorage.storage().reference()
which gives me the error 'use of unresolved identifier 'FIRStorage'.
These are my imports in my file:
import UIKit
import Firebase
In the video tutorial I am following the person in the video only has these two imports and gets no error. 'FIRStorage' also seems to be an actual class in the Firebase documentation. Is there an import I am missing? Is there something wrong with my frameworks or podfile?
Here are my pods:
Any help is greatly appreciated!
You need install FirebaseStorage to use it
Follow this instruction: https://firebase.google.com/docs/storage/ios/start
You need to the following steps:
import FirebaseStorage
FIRStorage has been renamed to Storage
Hopefully you find it helpful.

Importing AVFoundation and using AudioQueueOutputCallback or AudioQueueInputCallback crashes source editor

I have a weird problem - it might be something in my code, but I don't think so. So if anyone has faced this before could shed some light, or can try to reproduce it on their machine and share the results, I'd appreciate it.
Xcode used: V. 7.3.
When using AudioQueue within AVFoundation, using AudioQueueOutputCallback or AudioQueueInputCallback repeatedly crashes the source editor with error "An internal error occurred. Source editor functionality is limited. Attempting to restore..." - to no avail. The Issue Navigator (as seen in the screenshot attached), displays "Command failed due to signal: Segmentation fault: 11".
With the presence of "import AVFoundation" at the top of the file, using a snippet such as the one below, produces the problem I mentioned:
var outputCallback: AudioQueueOutputCallback = {
(inUserData, outQA, outBuffer) in
...
}
Please do note using a similar pattern with other closures is just fine. The problem seems to be specific to AVFoundation and creating closures of type AudioQueueOutputCallback or AudioQueueInputCallback.
Steps to Reproduce:
1. Create a new project (or file).
2. import AVFoundation
3. Write the following snippet within the class:
var outputCallback: AudioQueueOutputCallback = {
(inUserData, outQA, outBuffer) in
return
}
Expected Results:
No error. Being able to use the closure handler "outputCallback".
Actual Results:
Xcode source editor crashes repeatedly with error "An internal error occurred. Source editor functionality is limited. Attempting to restore..." - to no avail. The Issue Navigator (as seen in the screenshot attached), displays "Command failed due to signal: Segmentation fault: 11".
Any ideas would be appreciated.
Edit: Playground breakdown screenshot:
Edit 2: Adding details of bug Reported to Apple (never got a response)
When using AudioQueue within AVFoundation, using AudioQueueOutputCallback or AudioQueueInputCallback repeatedly crashes the source editor with error "An internal error occurred. Source editor functionality is limited. Attempting to restore..." - to no avail. The Issue Navigator (as seen in the screenshot attached), displays "Command failed due to signal: Segmentation fault: 11".
With the presence of "import AVFoundation", using a snippet such as the following produces the aforementioned problem:
var outputCallback: AudioQueueOutputCallback = {
(inUserData, outQA, outBuffer) in
...
}
Please do note using a similar pattern with other closures is just fine. The problem seems to be specific to AVFoundation and creating closures of type AudioQueueOutputCallback or AudioQueueInputCallback.
Steps to Reproduce:
Create a new project (or file).
import AVFoundation
Write the following snippet within the class:
var outputCallback: AudioQueueOutputCallback = {
(inUserData, outQA, outBuffer) in
return
}

Resources