I'm getting 110 warnings in my build after installing Azure SDK 2.3 that I don't recall seeing before. They are all for the file "Microsoft.WindowsAzure.targets".
An example of one such warning is:
The element 'PropertyGroup' in namespace 'http://schemas.microsoft.com/developer/msbuild/2003' has invalid child element 'CloudToolsVersion'.
Has anyone else encountered this problem or know the right way to fix it?
Well, it looks like I just needed to close any open editors for msbuild project files to get those to disappear. Other answers I found suggested on the web were to disable schema validation or to extend the schema myself.
Very scary! From your solution and hints from other similar questions, I think I know what's going on: When any build script file (such as a .props) is open in a text editor, it turns on /validate. This is used to see red wavies in the editor and gives the warnings when the project is loaded by any MSBuild task. The schema holds the various element used by the MS targets infrastructure, and doesn't know anything else. I'm not sure what good that is, but there you have it.
Related
I'm implementing an app, which uses (kotlin.text.)StringBuilder instances at various points. Since today, I have to double-click the variable name and, after that, double-click 'value' to see the content shown as one character per line (next to 'value', it also says e.g. char[20]). Until yesterday, I was able to see their contents in the variables view of the debugger right after double-clicking the variable name and - what is even more important - in one single string line. I have to compare the content of several instances and therefore cannot work efficiently with this view.
Is there some kind of setting, which needs to be reset? Has anyone else experienced this? Is this an intended behavior or am I the only one having this bug/behavior?
After getting this, I already tried restarting android studio, as well as upgrading all components to the latest version. I also tried creating an entirely new project with only one StringBuilder to rule out any problems in my current project - but, no luck so far.
Any hint would be much appreciated!
You need to add a .toString() call to your string builder to get the value of the string.
I finally figured out the solution to the problem. It was indeed a setting I had to reset. As I did not actively change it, this solution might be useful to others, too.
Via 'Setting > Build, Execution, Deployment > Debugger > Data Views > Java', I found the option 'Enable 'toString()' object view:'. After selecting this option, everything worked again as before.
Thanks to everyone, who tried to figure out the solution!
I'm developing an DSL with jetbrains MPS. It's not obvious to use, but I succeeded so far with the design-part.
It's possible to right-click on a solutions node and "run" it, assuming the language is executable (extends executing.util). Plus I use a seperately developed jar as a library (used by the generator).
I build a new project to test, as simple as possible, added some extra nodes and loops in the generator, the error occures and it can't be undone.
As far as I can see, there are several possible sources of errors.
dependencies (they are tricky in MPS)
my jar
wrong cached files or so
Executing "run" causes the following error:
error: could not find or load main class MySolution.package.map_concept
Has some of you out there experience with this?
Tell me, if there are some extra information that would help.
It seems that you have added the jar file as a model to the language, which makes it invisible for the solution. Following the instructions at https://confluence.jetbrains.com/display/MPSD32/Getting+the+dependencies+right#Gettingthedependenciesright-AddingexternalJavaclassesandjarstoaprojectruntimesolutions and creating a separate library solution worked for me.
To me this looks like a problem of the generator. Have you fully rebuilt the project - right-click on the "project" node in the structure tree?
Is the root mapping template correct? If you can share your project, I can have a look.
A small tip that could have saved me some time and might also solve this problem for someone else, even if you followed the instructions in other answers.
When prompted to add your libraries to modules after including the libraries on Java tab, dismiss the window if you already included them in the first place on the Common tab. Otherwise they are listed once despite having been added twice, leading to a compilation failure.
I dropped in an external jar file using the new jar design element of Notes 9.
I tried referencing it from a managed bean, and was able to compile. In runtime, I get a NoClassDefFoundError when I try to use the methods in the jar.
I have refreshed, cleaned, and rebuilded. Version 9 server and designer.
I remember in the past with 8.5.3 there was lots of issues getting the build path correct, but I thought that the new jar design element was supposed to take care of the issues. Most of the research I have found is from the days of 8.5.3 and earlier.
Any advice would be appreciated. (I am purposely not tagging java on this question since I think only XPagers would understand what to advise here)
2 steps to fix a potential issue:
Remove the database from designer. Delete the workspace project (only the project not the entire workspace!)
Add the database back. Check in the Java build path (right click in the navigator view on the database) that the Jar directory is included
Sometimes step 2 alone does the job, so start with that first.
As I remember early R9 versions have had issues with Java/JAR design elements. Put your JARs into WEB-INF folder (Project Browser view), that is my preferred way to use them.
Are JAR files in WebContent/WEB-INF/lib available to Java design elements in Domino Designer?
The solution that Stephan posted worked for my first attempt yesterday, so I am leaving it as the accepted answer. Today, I had to change the package name and the issue cropped up again.
This time nothing that Stephan or Frantisek suggested work to fix the NoClassDefFoundError exception. After trying everything, I came across this blog post. (A big thanks to Panu Haaramo who posted it in the comments in the answer of the SO that Frantisek's links to)
http://lotusandjava.blogspot.fi/2012/10/xpage-javalangnoclassdeffounderror.html
Renaming the jar caused the runtime engine to find the class file properly. Try this as well, as the solutions above to fix this problem. It is certainly an easy fix.
When I add AFDownloadRequestOperation I get several errors that result in the inability for me to successfully build my project...
These errors all seem to be of a redeclaration nature. My first mind is to go into the files that display the error and individually delete the other declarations.
But I figured that it may cause more errors and/or not be the best method to resolve my issue. Is anyone familiar with this issue?
I have attached a screenshot of what I see.
My best guess is that Xcode is complaining about there being multiple files in the project that declare the #interface for AFDownloadRequestOperation. Note that AFDownloadRequestOperation has never been a part of the standard AFNetworking library, so I would suggest that you make sure that you are using the most up-to-date version of the canonical source available.
You may find CocoaPods to be helpful for managing your dependencies, as an alternative to manually adding source files to your project.
I'm probably using the wrong terminology but basically I would like to dump the findings from the panel to the right of the scrollbar to a file for later review. See the screenshot below for what I mean. It's the part of the screen with the orange and green lines on. Does anyone know if this is possible?
If anyone is interested I have filed a feature request for this with JetBrains here.
As far as I know it's not possible, at least with the built in features. Maybe it's possible by writing a plugin.
The only thing which I know to get something like this:
Goto the 'Code Issues' Inspector: Resharper->Code Issues in Current Solution or any other of these options
On the window which shows the issues is a 'Export' button. With that button you can export the issues of the project/solution/file.
The report format is pretty simple list of issues as text. Like this:
5 issues found
Common Practices and Code Improvements (1 issue)
<DemoApp>\Program.cs (1 issue)
Property 'Title' can be made private
Potential Code Quality Issues (4 issues)
<DemoApp>\Program.cs (4 issues)
Auto-implemented property accessor is never used
Auto-implemented property accessor is never used
Class 'Comment' is never instantiated
Class 'Program' is never instantiated
It's now possible to use Resharper's Command Line to produce a xml with the issues on a given solution.
It's not exactly the 'export' functionality you wanted, but it might be useful still.
You just have to run the tool and pass the file where it will save the issues. For example:
inspectcode /o="D:\Resharper\MyIssues.xml" [PathToSolutionFile]
I've noticed this produces more issues than the plugin inside Visual Studio does, for some reason. I really think the Resharper's team should concentrate on using the same code to analyze the files instead of different implementations like it seems to be now.