<p dir="auto">A.ts:</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="class A&lt;T&gt; { method() {} }
export = A;"><pre class="notranslate"><span class="pl-k">class</span> <span class="pl-smi">A</span><span class="pl-c1">&lt;</span><span class="pl-smi">T</span><span class="pl-c1">&gt;</span> <span class="pl-kos">{</span> <span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span><span class="pl-kos">}</span> <span class="pl-kos">}</span>
<span class="pl-k">export</span> <span class="pl-c1">=</span> <span class="pl-smi">A</span><span class="pl-kos">;</span></pre></div>
<p dir="auto">B.ts:</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import A = require('A');
new A().method();"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-smi">A</span> <span class="pl-c1">=</span> require<span class="pl-kos">(</span><span class="pl-s">'A'</span><span class="pl-kos">)</span><span class="pl-kos">;</span>
<span class="pl-k">new</span> <span class="pl-smi">A</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div>
<p dir="auto">When using code completion on the .method call in B.ts, <code class="notranslate">getCompletionEntryDetails</code> throws an exception:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TypeError: Cannot read property 'parent' of undefined
    at appendOuterTypeParameters (/home/jeffrey/nbts/build/cluster/nbts-services.js:12322:28)
    at getOuterTypeParametersOfClassOrInterface (/home/jeffrey/nbts/build/cluster/nbts-services.js:12338:20)
    at getTypeParametersOfClassOrInterface (/home/jeffrey/nbts/build/cluster/nbts-services.js:12355:35)
    at appendParentTypeArgumentsAndSymbolName (/home/jeffrey/nbts/build/cluster/nbts-services.js:11386:75)
    at walkSymbol (/home/jeffrey/nbts/build/cluster/nbts-services.js:11418:29)
    at Object.buildSymbolDisplay (/home/jeffrey/nbts/build/cluster/nbts-services.js:11425:21)
    at /home/jeffrey/nbts/build/cluster/nbts-services.js:32608:51
    at mapToDisplayParts (/home/jeffrey/nbts/build/cluster/nbts-services.js:32592:13)
    at Object.symbolToDisplayParts (/home/jeffrey/nbts/build/cluster/nbts-services.js:32607:16)
    at addFullSymbolName (/home/jeffrey/nbts/build/cluster/nbts-services.js:37752:49)"><pre class="notranslate"><code class="notranslate">TypeError: Cannot read property 'parent' of undefined
    at appendOuterTypeParameters (/home/jeffrey/nbts/build/cluster/nbts-services.js:12322:28)
    at getOuterTypeParametersOfClassOrInterface (/home/jeffrey/nbts/build/cluster/nbts-services.js:12338:20)
    at getTypeParametersOfClassOrInterface (/home/jeffrey/nbts/build/cluster/nbts-services.js:12355:35)
    at appendParentTypeArgumentsAndSymbolName (/home/jeffrey/nbts/build/cluster/nbts-services.js:11386:75)
    at walkSymbol (/home/jeffrey/nbts/build/cluster/nbts-services.js:11418:29)
    at Object.buildSymbolDisplay (/home/jeffrey/nbts/build/cluster/nbts-services.js:11425:21)
    at /home/jeffrey/nbts/build/cluster/nbts-services.js:32608:51
    at mapToDisplayParts (/home/jeffrey/nbts/build/cluster/nbts-services.js:32592:13)
    at Object.symbolToDisplayParts (/home/jeffrey/nbts/build/cluster/nbts-services.js:32607:16)
    at addFullSymbolName (/home/jeffrey/nbts/build/cluster/nbts-services.js:37752:49)
</code></pre></div>
<p dir="auto">Several other services APIs, including <code class="notranslate">getQuickInfoAtPosition</code> and <code class="notranslate">getOccurrencesAtPosition</code>, also throw the same error when used on that .method call.</p>
<ol dir="auto">
<li>
<p dir="auto">Create a new package directory</p>
</li>
<li>
<p dir="auto"><code class="notranslate">npm install github</code></p>
</li>
<li>
<p dir="auto">write the following file:</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import GH = require(&quot;github&quot;);

new GH().activity"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-smi">GH</span> <span class="pl-c1">=</span> require<span class="pl-kos">(</span><span class="pl-s">"github"</span><span class="pl-kos">)</span><span class="pl-kos">;</span>

<span class="pl-k">new</span> <span class="pl-smi">GH</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">activity</span></pre></div>
</li>
<li>
<p dir="auto">Get quick info on the word <code class="notranslate">activity</code></p>
</li>
</ol>
<p dir="auto">Expected: Quick info.<br>
Actual:</p>
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TypeError: Cannot read property 'parent' of undefined
    at appendOuterTypeParameters (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23851:28)
    at getOuterTypeParametersOfClassOrInterface (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23867:20)
    at getTypeParametersOfClassOrInterface (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23884:35)
    at appendParentTypeArgumentsAndSymbolName (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22618:75)
    at walkSymbol (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22650:25)
    at Object.buildSymbolDisplay (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22656:21)
    at C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53274:51
    at mapToDisplayParts (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53260:9)
    at Object.symbolToDisplayParts (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53273:16)
    at addFullSymbolName (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:60166:49)"><pre class="notranslate"><code class="notranslate">TypeError: Cannot read property 'parent' of undefined
    at appendOuterTypeParameters (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23851:28)
    at getOuterTypeParametersOfClassOrInterface (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23867:20)
    at getTypeParametersOfClassOrInterface (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:23884:35)
    at appendParentTypeArgumentsAndSymbolName (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22618:75)
    at walkSymbol (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22650:25)
    at Object.buildSymbolDisplay (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:22656:21)
    at C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53274:51
    at mapToDisplayParts (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53260:9)
    at Object.symbolToDisplayParts (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:53273:16)
    at addFullSymbolName (C:\Users\drosen\AppData\Roaming\npm\node_modules\typescript\lib\tsserver.js:60166:49)
</code></pre></div>