Language-specific soft tab size doesn't seem to work for me


#1

Currently using beta channel Atom 1.9.0-beta0, but this issue seems to exist for me for several versions now.

Using the Atom settings dialogs, I have soft tabs configured with a global tab length of 2 and in keeping with pep8, my python tab length is overridden to 4 (settings -> packages -> language-python) in all of the settings sections (grammar, console grammar, etc.)

When I’m editing a python file, the tab guide lines are every 2 spaces, hitting tab inserts 2 spaces, and using tab and shift-tab to indent and outdent blocks of code also appears to indent/outdent 2 spaces. Due to my language-python settings, it seems like all of these should be operating as if soft tabs represent 4 spaces. I’ve confirmed python grammar is active via the Atom status bar.

If I change my global settings to 4 spaces, then sure, python works with 4. I don’t think this is python-specific, I don’t think any of my language-specific settings regarding tab size work, so I can’t set my global size to 4 and then set Ruby size to 2, etc. It just moves the problem around.

Am I misunderstanding how this is supposed to work or is something broken (at least with my install/configuration if not Atom as a whole)?

There was an old thread that touched language-specific tab settings but I thought it’d be better to create a new thread versus bump the old one. Here is a link to the old thread for reference: Different tab size depending on language

Thanks


#2

Have you followed the suggestions in the Debugging document? Also, could you give the following information?

  • What OS and version are you running?
  • Can you reproduce the issue after completely exiting Atom and restarting using atom --safe?

I cannot reproduce the problem you’re describing using vAtom v1.10.0-dev-b702a09 on Mac OS X 10.11.5. I have also not heard of any regressions of this feature in any version of Atom. So yes, I am assuming that there is something wrong with either how you’ve configured things (especially since the default configuration of Atom is 2 space tabs and 4 space tabs for Python) or there is a package that you’ve installed that is causing a problem.


#3

That helped, thank you. After restarting in --safe, something I should have thought of doing on my own, the tab size setting started working. So I began the hunt for the offending package and found it was one I installed a very, very long time ago (and subsequently forgotten about) called “editor-settings”. I disabled it and soft tab size works perfectly.

Thank you for the nudge in the right direction.