microsoft / microsoft/TypeScript-Sublime-Plugin

AttributeError: 'NoneType' object has no attribute 'get_mapping'

Open
#668 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
1.7k
Forks
236
Avg merge
21d 13h
Merged PRs (30d)
1

Description

I just saw these things on my console, not sure why they are coming up:

Traceback (most recent call last):
  File "F:\SublimeText\sublime_plugin.py", line 1072, in run_
    return self.run(edit)
  File "F:\SublimeText\Data\Packages\TypeScript\typescript\commands\references.py", line 35, in run
    mapping = ref_info.get_mapping(str(cursor[0]))
AttributeError: 'NoneType' object has no attribute 'get_mapping'
Traceback (most recent call last):
  File "F:\SublimeText\sublime_plugin.py", line 1072, in run_
    return self.run(edit)
  File "F:\SublimeText\Data\Packages\TypeScript\typescript\commands\references.py", line 35, in run
    mapping = ref_info.get_mapping(str(cursor[0]))
AttributeError: 'NoneType' object has no attribute 'get_mapping'

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reading typescript/commands/references.py at line 35 and reproduce the references command in the reported Sublime Text setup. Trace why ref_info is None; done means the reported AttributeError no longer occurs when the command runs.

Written by the indexing model from the issue text.

Assessment

Tech stack
python, typescript
Domain
tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.