question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Cannot read property 'key.filepath' of undefined

See original GitHub issue
[Error - 12:29:44] Request textDocument/definition failed.
  Message: Request textDocument/definition failed with message: Cannot read property 'key.filepath' of undefined
  Code: -32603 

I’m not exactly sure what triggered this, but it happened while trying to autocomplete internal let valet: Val... in the code below:

import Foundation

import PromiseKit
import Valet

open class BioPass {
    enum Error: Swift.Error {
        case notAvailable
        case failedEncodingPassword
        case failedCreatingSAC
        case unhandledKeychainError(OSStatus)
        case unexpectedPasswordData
    }

    let serviceName: String

    internal let valet: Val

    public init(_ serviceName: String = Bundle.main.bundleIdentifier!) {

        if serviceName == "" { fatalError("serviceName cannot be an empty string") }

        self.serviceName = serviceName
    }

Both PromiseKit and Valet are installed as dependencies with Swift Package Manager.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:8 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
vknabelcommented, Mar 31, 2018

Fixed in 2.3.0

1reaction
vknabelcommented, Mar 17, 2018

@LinusU good catch! Was actually related to #11 and occured if there is no documentation like in your window.

vscode-swift-development-environment-2.3.0.vsix.zip

Read more comments on GitHub >

github_iconTop Results From Across the Web

Node.js TypeError: Cannot read property 'path' of undefined
I found that the error "Cannot read property path of undefined" when using multer in find upload was due to the fileFilter option...
Read more >
Cannot read property 'path' of undefined · Issue #124 - GitHub
Make sure there are no dashes (-) in your file names. It fixes the error. But strange part is, it was working with...
Read more >
Why is the error "Cannot read properties of undefined (reading ...
I'm building a LWC to be used as a flow screen component. In the LWC, I allow the border color of the component...
Read more >
cannot read properties of undefined (reading 'filename') multer
It means the file is not parsed, which means the request is not correct. Change data property to include only formData , no...
Read more >
How to solve "can not read property path of undefined" in ...
file.fieldname may be undefined. That is why the complete path becomes undefined. Instead, try looking at req.file for the name. Here is what...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found