How to configure SublimeLinter to enforce pep8 errors? - sublimetext2

I am trying to get SublimeLinter to enforce pep8 errors as a plugin to sublime text 2. When I install it, it seems to immediately show a small list of errors, but not nearly the full list that I get by running
pep8 file.py
If I look in my sublime text 2 console, then i see the full list of pep8 errors. However, I want these to be shown in the sublime text 2 gui, when you go to "Show Error List."
If I go to "Show Error List," it says I have no lint errors, but I see hundreds of lint errors in the console.
In the package configuration file it has pep8 set to true by default, but doesnt seem to be enforcing all of the errors.
For someone who has used this plugin, how can I get it to list all of the pep8 errors from the main "Show Error List" window instead of the console?
===
Update: After a while of poking around, I have narrowed down. In the SublimeLinter plugin (file python.py) there is a line:
pep8.Checker(filename, good_lines).check_all()
This is what actually runs pep8 on the file. When it encounters an error it is supposed to call the pep8.Checker.report_error function, and there is a custom callback defined in the plugin. However, I have traced it, and I see that it is not being called. The checker is running correctly and producing out. I have examined the pep8 code here https://github.com/jcrocholl/pep8/blob/master/pep8.py, but no luck.
I imagine there is a very simple fix... probably a configuration somewhere. If anyone has insights, that would be appreciated.

Related

How do I solve 'Web Compiler found an error in compilerconfig.json'?

On trying to re-compile all files in a solution, using Visual Studio 2017, I get this uninformative error message:
Web Compiler found an error in compilerconfig.json
To begin with, there is more than one compilerconfig.json file in the solution.
Secondly, there is no indication whatsoever of what the error is, where it occurs (line number, for instance).
Any ideas how I can go about solving this?
In Visual Studio's Solution Explorer, right-click the compilerconfig.json file and click "Task Runner Explorer". In the left pane you will see "compilerconfig.json/all files", right-click on it and then click on "Run". You will see the details of the execution which, in my case, included the useful information about how to correct the error.
I was able to solve this issue for myself by using individual file compiling, instead of "All files".
I was getting a "Compiling successful!" message, but that didn't seem true because my compile file didn't contain my change. So here's what I did:
Open Window > Task Runner Explorer. In your left column, there is a task for "All Files". That's fine. Ignore it.
Compile your SCSS files individually. Do this by right clicking on each SCSS file in that list, and then Bindings > After Build. (Or add the task to whatever event you prefer. I chose After Build.)
Open any SCSS file in your project and add a test. I added something like #TEST2 {color: hotpink;} to my SCSS file.
Now when you save, your compiling takes a few seconds longer. Now open main.css and see if your change (#TEST2) exists in the file.
I just went through this and didn't find an easy way but I got past it.
My issue turns out to be a missing input file that was supposed to be compiled.
Method of attack:
Try to compile each compilerconfig.json file (right-click -> Web Compiler -> re-compile all files)
repeat until you find the file in question
Remove all data from this file and add entries in one at a time (or scan it to make sure your files are there, which ever fits your situation)
The root problem is that the Web Compiler didn't install successfully. I had the same problem as described in the other answers and went down a rabbit hole to figure out why I couldn't compile. Turns out I had to help the tool install itself. See this comment for details:
https://github.com/madskristensen/WebCompiler/issues/390#issuecomment-475427735
Once I did the steps listed in that comment, I able to both compile files again and was explicitly told by the tool which line of my SCSS had an error.
For an information:
I got the same error in VS2019 webcompiler. And I found a solution ie;
Project should be open as a "Web Site".
Do not open as a folder. This simple thing is solved my issue.

Sublime Text LaTeXTools console autohide

The build script in the LaTeXTools plugin for Sublime Text editor pops up the console, where the result of the compilation is written.
I would like the console to auto-hide once the compilation is finished and there are no errors (and to stay open otherwise).
I knew how to achieve this with Sublime Text 2. (I think I inserted two lines sublime.active_window().run_command("show_panel", {"panel": "console", "toggle": True}))
somewhere in the build script.)
How to achieve this behavior with Sublime Text 3?
How to (properly) achieve this behavior with Sublime Text 2?
This functionality has now been added natively to the LaTeXTools package, using the hide_build_panel
preference in the LaTeXTools settings file. Check the documentation.
There are four levels of hiding behavior available:
always
if there were no errors
if there were no errors or warnings
never
Extract from the documentation. Possible values:
always: never show the build panel at all
no_errors: only show the build panel if errors occur
no_warnings: only hide the panel if no warnings occur
no_badboxes: only hide the panel if no warnings or badbox messages occur; this only differs from no_warnings if display_bad_boxes is set to true.
never: never hide the build panel. Any other value will be interpreted as the default.
I have no idea what I'm doing, but the following works reasonably well (LaTeXtools revision 2014-3-12).
In the file makePDF.py insert a line
self.window.run_command("hide_panel", {"panel": "output.exec"})
between lines no. 370 and 371 (the definition of the do_finish function).
This probably won't survive LaTeXtools package update..
self.window.run_command("hide_panel", {"panel": "output.exec"})
I added this command in the run(self) method (makePDF.py) after in the "else" block, when asking for errors of the LaTeX run (line 177).
It works perfectly, but won't survive an LaTeXTools package update.

checkstyle ant task clickable console entry

I don't know much about eclipse, but one of my juniors asked this. We use checkstyles to scan our code. When we get an error, the file that errored shows in the console display. How do we setup checkstyle and eclipse so that you can click on the class name in the display and go to the file. An example of what we are seeing
[checkstyle] C:\Users\me\Code\RP40\cmcBL\src\main\java\com\foo\bar\client\ProductsDocumentResource.java:98:50: Must have at least one statement.
is there a way to make that clickable?
Use Eclipse-CS, the Checkstyle Eclipse plugin. This will make Checkstyle warnings appear in Eclipse in the 'Problems' view. There, you can click on the entry and it will take you directly to the corresponding line of code.

What is the location of log file for sublime text 2 on Mac OSX

I'm trying figure out why JSON syntax highlighting seem to work sometimes but not always. Is there a log which sublime text 2 logs to?
You can access the console by hitting Ctrl-` (that's the button to the left of 1 and above Tabon US keyboards) in Windows/Linux, or Command-` in OSX, or by the menu View -> Show Console. This allows you to scroll through the history of your session and look for any errors. It is also the console to the internal version of Python 2.6 embedded in ST2, similar to the >>> that you see if you start Python from the command line, so you can use it to get all sorts of system information that way, if you know how to use the API and, of course, Python.

How to make Flashdevelop errors appear in Results Panel?

I am using Flashdevelop to build an Actionscript 3.0 game. It was originally a FlashIDE project but I decided to migrate the project to FlashDevelop. I also changed some asset and property names, as a result there were a lot of syntax error. The errors keep coming out in the Output Panel instead of Results Panel (is that normal) when compiled. I know that when I click errors in the Results Panel it will open and point the error in the Code Panel. I can't do that with errors in the Output Panel (I assume its normal). Is there something I can do to make the errors clickable ?
Even a simple error like this doesnt come out in the Results panel:
Loading configuration file H:\04 Noveline\03 GD\GD03\Folder (aaaa)\TEST\obj\MeccatomedinaConfig.xml
H:\FD(1)\TEST\src\Game.as(75): col: 3 Error: Access of undefined property sssss.
sssss
^
Build halted with errors (fcsh).
(fcsh)
afaik it's impossible to make output panel clickable. but you can press F10 to open program settings dialog and check if your results panel is disabled. and also disable output panel if it's really annoying)
The errors should appear in the results panel and the output panel. Make sure the results panel is open.
Remove parentheses from project path to workaround the issue.
(As Stucko & Markus von Broady wrote in comments.)
This issue is still around for FlashDevelop 5.1.1.1.
I have logged the issue here for ref:
https://github.com/fdorg/flashdevelop/issues/1676