Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"unblockcomment" incompatible with "automatically remove trailing spaces" #4313

Closed
llan-ml opened this issue Mar 31, 2017 · 1 comment
Closed

Comments

@llan-ml
Copy link

llan-ml commented Mar 31, 2017

Description of your problem

What steps will reproduce the problem?
For example, there are codes:
"""
import numpy as np

def test():
return 1

test()
"""

  1. Enable the feature "Automatically remove trailing spaces when saving files"
  2. blockcomment (ctl+4) the piece of codes above
  3. save the file (ctl+s)
  4. unblockcomment (ctl+5)

What is the expected output? What do you see instead?
The expected output is
"""
import numpy as np

def test():
return 1

test()
"""
However, we see
“”“
import numpy as np
# def test():
return 1
# test()
”“”
Please provide any additional information below
It seems like the enabled feature (removing trailing spaces) removes the newline character when saving the file.

Versions and main components

  • Spyder Version: 3.1.3
  • Python Version: 2.7.12
  • Qt Version:
  • PyQt Version:
  • Operating system: Ubuntu 16.04

Dependencies

Please go to the menu entry Help > Optional Dependencies (or
Help > Dependencies), press the button Copy to clipboard
and paste the contents below:
jedi =0.9.0 : 0.9.0 (OK)
matplotlib >=1.0 : 1.5.3 (OK)
nbconvert >=4.0 : 4.2.0 (OK)
numpy >=1.7 : 1.11.1 (OK)
pandas >=0.13.1 : 0.18.1 (OK)
pep8 >=0.6 : 1.7.0 (OK)
psutil >=0.3 : 4.3.1 (OK)
pyflakes >=0.5.0 : 1.3.0 (OK)
pygments >=2.0 : 2.1.3 (OK)
pylint >=0.25 : 1.5.4 (OK)
qtconsole >=4.2.0: 4.2.1 (OK)
rope >=0.9.4 : 0.9.4 (OK)
sphinx >=0.6.6 : 1.4.6 (OK)
sympy >=0.7.3 : 1.0 (OK)

@ccordoba12
Copy link
Member

Thanks for reporting. We'll take a look at it in a future release.

@ccordoba12 ccordoba12 modified the milestones: v3.2, v3.2.1 Apr 26, 2017
@ccordoba12 ccordoba12 modified the milestones: v3.2.1, v3.2.2, v3.2.3 Jul 26, 2017
timhoffm added a commit to timhoffm/spyder that referenced this issue Aug 20, 2017
@ccordoba12 ccordoba12 modified the milestones: v3.2.3, v3.2.x Aug 28, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants