leetcode-cli icon indicating copy to clipboard operation
leetcode-cli copied to clipboard

Error line number is not correct. (vsc-leetcode-cli)

Open kgfly opened this issue 6 years ago • 1 comments

This is an issue of vsc-leetcode-cli (@jdneo). Since https://github.com/leetcode-tools/leetcode-cli does not have an issue tab, I report the issue here. ^_^

Problem Summary

Error line number is not correct when the source is download with "x"

How to reproduce

leetcode show 1316 -gx -l python3 (You don't need make change to the file) leetcode test 1316.distinct-echo-substrings.py

Observed: × Compile Error × Error: Line 3: IndentationError: expected an indented block × Error: Line 3: IndentationError: expected an indented block × Your Input: "abcabcabc" × Expected Answer: × Stdout:

Expected: Because I download the source with "x", the source code has a big comment part. The correct line number should be 47, instead of 3. This is very annoying.

Environment

  • OS version: Windows 10
  • Node version: v12.14.1
  • Npm version: 6.13.4

Thanks.

kgfly avatar Jan 12 '20 09:01 kgfly

The issue is due to

@lc code=start

@lc code=end

@jdneo , is it possible to remove them from the downloaded code? or provide an extra option?

kgfly avatar Jan 20 '20 00:01 kgfly