RStudio interface / behavior changes in 1.0.136 - rstudio

Various things are different in 1.0.136, e.g. running code with ctrl-enter has all sorts of strange behavior in an RMarkdown document, running code that has a syntax error somehow leads to all of the code being run in a block above (below?) the wrong code, etc. Sorry for not posting an MWE, but at the moment I just want to know if anyone is aware of these new "features" and if so how they can be turned off or better yet how I can just downgrade to the previous version of RStudio (which I can't currently find on the website).

Yes they changed some default settings that were present in the old interface.
Change the setting in markdown next to the knit button, from:
Chunk Output Inline -> Chunk Output in Console
Pictured here.
You can probably mess with the the Global Setting->Rmarkdowns under Tools to get it back the way it was before, but this was the fastest way for me.

Related

How to determine where an intellisense-like suggestion comes from? (and suppress it)

When writing Ruby code, the following suggestion comes up each time the cursor hits an end statement (intellisense-like):
It is very annoying (breaks the flow, since it must be escaped) and useless. I don't know where or what extension it comes from.
How do I determine what piece of plugin injects this suggestion?
And then, how do I shut it off?
In your settings.json file - you have the ability to control which plugin is making recommendations - mine has the following:
"editor.quickSuggestions": null // use rubocop for formatting
"ruby.intellisense": "rubyLocate",
Purely disabling the intellisense functionality would be controlled by these settings.
https://code.visualstudio.com/docs/editor/intellisense
I don't believe that you can purely turn off the 'end' only intellisense - it appears to be an all-or-none proposition.

Xcode autocomplete showing results that don't exist on object

When using App Code, autocomplete will only show results directly related to my struct. This is a great feature as it keeps everything very clean and I know that accessing these properties isn't going to give me an error.
Except I don't like App Code and it's non native looking UI.
In Xcode it's quite different. Why am I getting flatMap, map, description, debugDescription?
Obviously if its my own code, I know which properties/functions are okay to use, because I wrote them. I can just ignore the noise. But if I'm using someone else's library this can slow things down. Especially when I'm just guessing or trying to remember a function.
Is there a way to fix this — to have Xcode not show me functions/properties that I can't use?
It always shows default system objects properties if the object/class is not found.
It's the behavior of Xcode

Sublime Emmet doesn't expand conflict

(this is on a OSX latest 10.9.x)
Some of the shortcuts work with the tab, others not..
for example:
.class>ul>li*5>a
when tabbing gives
.class>ul>li*5>
while
div.class
gives correctly
<div class="class"></div>
Also html:5, input:radio expansion doesn't work (only on CTRL+E).
Should I look my key mappings? Could something from OSX be interfering? (I use OPTION+TAB to switch windows with the help of Karabiner...
Glad that helped.
Rather than looking at all plugins installed, you may want to first try entering sublime.log_commands(True) in the ST console. Then try inserting as normal. If it's another ST plugin performing an action, the command name will be listed. If you don't recognize the name of the command, you can use something like FindKeyConflicts to see what package it's associated with. The above is a plugin I wrote, but I'm sure there are other plugins that do the same thing. In most cases, the name of the command is enough to find the offending plugin.
Also adding your solution here to make it a bit more clear.
I found my answer there: https://github.com/sergeche/emmet-sublime/issues/363. Conflict with ST's autocomplete. Commented it out, and we're good. I guess now I'm missing some out of the box snippets but well.
If you would like to see the default snippets, without having to search/extract them manually, you can try using https://sublime.wbond.net/packages/PackageResourceViewer. Another plugin I wrote to help with viewing those packaged files/plugins.

Lightswitch global query breaking app

I'm trying out Lightswitch for the first time, and I'm finding some of the 'built-in' features aren't as easy to implement as the videos show. The most notable being global queries, because everyone I create is causing a specific error that I cannot find a cause for. I've stripped it down to a query that does nothing but return a 'select *' on the table, and removed any code I've added.
Here is the query in my solution explorer:
And here it is in the designer:
Simple enough, so I add a screen for the query:
Everything is pure default, so why do I get this error? It says it doesn't recognize the query at all, and gives a weird dll error.
I've tried recreating it as a couple different kinds of screens, but I followed this tutorial where they use a List and Details Screen in this way. The best I can come up with is that I'm experiencing a bug due to having VS 2012 and .NET 4.5 installed as well (don't ask me why). I'm just curious if this makes sense to anyone else, or if anyone else has been successful in creating these.
P.S. - I've also been unsuccessful in accessing the permissions I created by their name. I eventually figured out I could reference them by their index, but why is that necessary? I saw nothing about needing to add a reference to make this work.
partial void CustomerNew_CanRun(ref bool result)
{
result = User.HasPermission(Permissions.AllPermissions[1]);
}
OK, just to reassure you a bit (maybe), this is not normal, & I haven't seen this or heard of anything similar.
The fact that you can't access any of your permissions by name indicates something's definitely not right. You should be able to use Permissions.NameOfOneOfMyPermissions.
Starting from the basics, have you rebuilt the solution (note rebuilt, not just built)? What you'll often find with LightSwitch is that one error will cause a whole series of other errors to appear in the list, which can look quite daunting. When you fix the original error, the rest disappear. Double-click the error in the Error pane, & you should be taken to where the error is occurring. If you can't make sense of it, past the code here & I'll see if I can figure out what's wrong.
You'll also need to check that there isn't some code left over from any previous attempt at following the tutorial. Try adding a query with a different name, & see if the error has the new name in it, or the old one.

How to detect syntax errors when debugging Firefox extensions

When working on a large Firefox plugin, I sometimes accidentally make a syntax error not caught by my editor. When this happens, then calling
Components.utils.import("resource://modules/Foo.js")
will simply fail to import or return anything, without any kind of helpful hint as to where in the file to look for the syntax error. Is there any way I can get Firefox to give me some kind of clue when my imports fail?
EDIT: I fixed my own problem, which turned out to be that I was using code which had a global reference to the navigator object. What made this especially annoying was that the code would work when loaded in the browser (as Wladimir suggested below), but would still fail when importing in my extension.
Eventually I resorted to a sort of manual binary search: I'd delete half of the file and then see whether the import still failed. If so, then I'd delete half of what remained and repeat. As soon as it didn't fail, I had a more precise notion of where the problem was, which allowed me to either continue the binary search or scan the smaller area manually looking for the problem.
This is extremely time-consuming and I'd still appreciate any suggestions about how to speed up this debugging process.
The issue here is most likely the one described on https://developer.mozilla.org/en/Exception_logging_in_JavaScript and setting dom.report_all_js_exceptions preference to true should work. I must admit that I haven't tried that however because setting this preference makes the error console very noisy. Instead I use an ugly hack and load the module as a script in a local HTML file - this is enough to show me syntax errors and fortunately isn't something I need to do all too often (it is only an issue with syntax errors, runtime errors are reported as usually).

Resources