Skip to content
This repository has been archived by the owner on Aug 2, 2023. It is now read-only.

Debugger raising IndexError #786

Closed
brettcannon opened this issue Sep 6, 2018 · 4 comments
Closed

Debugger raising IndexError #786

brettcannon opened this issue Sep 6, 2018 · 4 comments
Assignees

Comments

@brettcannon
Copy link
Member

brettcannon commented Sep 6, 2018

microsoft/vscode-python#2499

PS C:\Users\Hugh.Groves> cd '\\global.arup.com\americas\Jobs\STJ\230000\230597-00(ACDO)\4-04 Engineering\4-04-02 Concrete\02 Calculations\19 Staged Construction\99-Tools\CreateBatches'; ${env:PYTHONIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFNIOENCODING}='UTF-8'; ${env:PYTHONUNBUFFERED}='1'; ${env:PYTHONPATH}='c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd'; & 'C:\Users\Hugh.Groves\AppDthon.exe' '-m' 'ptvsd' '--host' 'localhoata\Local\Continuum\Anaconda3\envs\p3\python.exe' '-m' 'ptvsd' '--host' 'localhost' '--port' '53026' '\\global.arup.com\americas\Jobs\STJ\230000\230597-00(ACDO)\4-04 Engineering\4-04-02 Concrete\02 Calculations\19 Staged Construction\99-Tools\CreateBatches\CreateBatches_02.py'
Traceback (most recent call last):
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\wrapper.py", line 1254, in done
    fut.result()
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\futures.py", line 40, in result
    reraise(self._exc_info)
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\reraise3.py", line 8, in reraise
    raise exc_info[1].with_traceback(exc_info[2])
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\futures.py", line 155, in callback
    x = it.send(fut.result())
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\wrapper.py", line 1605, in on_stackTrace
    norm_path = self.path_casing.un_normcase(unquote(str(xframe['file'])))  # noqa
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\pathutils.py", line 30, in un_normcase
    file_path_to_return = self._get_actual_filename(file_path)
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\pathutils.py", line 60, in _get_actual_filename
    fragments += ["{}[{}]".format(d[:-1], d[-1])]
IndexError: string index out of range
Traceback (most recent call last):
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\wrapper.py", line 1254, in donetal\ptvsd\ptvsd\wrapper.py", line 1254, in done
    fut.result()                                                                               tal\ptvsd\ptvsd\futures.py", line 40, in result
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\futures.py", line 40, in result                                                tal\ptvsd\ptvsd\reraise3.py", line 8, in reraise
    reraise(self._exc_info)
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\futures.py", line 155, in callbacktal\ptvsd\ptvsd\reraise3.py", line 8, in reraise
    raise exc_info[1].with_traceback(exc_info[2])
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\futures.py", line 155, in callback    x = it.send(fut.result())
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\wrapper.py", line 1605, in on_stackTrace
    norm_path = self.path_casing.un_normcase(unquote(str(xframe['file'])))  # noqa  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\pathutils.py", line 30, in un_normcase
    file_path_to_return = self._get_actual_filename(file_path)
  File "c:\Users\Hugh.Groves\.vscode\extensions\ms-python.python-2018.8.0\pythonFiles\experimental\ptvsd\ptvsd\pathutils.py", line 60, in _get_actual_filename    fragments += ["{}[{}]".format(d[:-1], d[-1])]
IndexError: string index out of range
@DonJayamanne
Copy link
Contributor

Changing priority as users are able to use the debugger in some cases.

@karthiknadig
Copy link
Member

Is there any detail on the folder structure where this occurs?

@DonJayamanne
Copy link
Contributor

No

@avnigo
Copy link

avnigo commented Sep 14, 2018

Regarding the folder structure, this issue occurs when the filepath of the .py being debugged is on a network drive (e.g. ‘\\global.arup.com’).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants