Make JavaScript and XML errors non-TeamCity errors; Update JavaScript language level to ES6 in IntelliJ settings#7541
Conversation
… language level to ES6 in IntelliJ settings
gianm
left a comment
There was a problem hiding this comment.
The inspection changes look fine, so I just have questions about the two new copied-in files.
| </value> | ||
| </option> | ||
| </component> | ||
| <component name="ProjectResources"> |
There was a problem hiding this comment.
Due to the fact that these files appear to be copied from elsewhere, I have a some questions about them:
- Why do they need to be added, rather than referenced somehow without copying? (Would make a good comment here)
- Will there be a need to update them in the future, and if so what would trigger that? Or are these files not expected to update regularly?
- I don't see a license attached to
assembly-2.0.0.xsd-- meaning we need to add a comment describing the legal basis for being able to include this file. Ideally this comment takes the form of a statement of what license the file is being used under, and why we believe it falls under that license. Even separately from the legal reason for including a comment, it would be good just to document where the file came from. - I do see a license and source URL in a comment at the top of
svg11.dtd, which is good.
There was a problem hiding this comment.
Why do they need to be added, rather than referenced somehow without copying?
IntelliJ verifies XML documents by the schema. XML documents usually reference those schemas as URLs:
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.0.0 http://maven.apache.org/xsd/assembly-2.0.0.xsd">
But IntelliJ doesn't automatically go to the internet to download the resource. It needs to know what schema corresponds to what URL, statically.
(Would make a good comment here)
Unfortunately, IntelliJ has a bad habit of purging comments from these settings XMLs, so adding comments is not productive: https://youtrack.jetbrains.com/issue/IDEA-211087.
Will there be a need to update them in the future, and if so what would trigger that? Or are these files not expected to update regularly?
No, these schema documents are expected to be immutable forever. If it will be updated, it will be http://maven.apache.org/xsd/assembly-2.0.1.xsd, or whatever another version.
I don't see a license attached to assembly-2.0.0.xsd -- meaning we need to add a comment describing the legal basis for being able to include this file. Ideally this comment takes the form of a statement of what license the file is being used under, and why we believe it falls under that license. Even separately from the legal reason for including a comment, it would be good just to document where the file came from.
This document is created and managed by Apache Maven, so it must be under Apache license. I don't feel confident to edit the file itself to add a license header so that it actually diverges from the contents of http://maven.apache.org/xsd/assembly-2.0.0.xsd.
There was a problem hiding this comment.
Unfortunately, IntelliJ has a bad habit of purging comments from these settings XMLs, so adding comments is not productive: https://youtrack.jetbrains.com/issue/IDEA-211087.
I don't think this comment is essential but it would be helpful. Maybe a README in the .idea directory?
This document is created and managed by Apache Maven, so it must be under Apache license. I don't feel confident to edit the file itself to add a license header so that it actually diverges from the contents of http://maven.apache.org/xsd/assembly-2.0.0.xsd.
My understanding is that we must note this somewhere as a matter of legal hygiene. I think it's fine to edit the file to add a comment at the top with source and licensing info, something like:
<!-- Other than this comment, this file is identical to
https://maven.apache.org/xsd/assembly-2.0.0.xsd, which, as part of
Apache Maven, is licensed under the Apache 2.0 license.
-->There was a problem hiding this comment.
I think the comment would be good. The files in .idea are not bundled as part of the source or binary assembly, so the licensing info for this wouldn't belong in LICENSE; the header seems like the best place.
There was a problem hiding this comment.
I don't think this comment is essential but it would be helpful. Maybe a README in the .idea directory?
It would be so far from the site that it won't serve the purpose: people don't have the means to know that there is a comment about something in a completely different file. But I've created #7549 about this. Please vote for https://youtrack.jetbrains.com/issue/IDEA-211087 so that hopefully it's fixed faster than never.
There was a problem hiding this comment.
I've added
<!-- Other than this comment, this file is identical to
https://maven.apache.org/xsd/assembly-2.0.0.xsd, which, as part of
Apache Maven, is licensed under the Apache 2.0 license.
-->
to the file.
There was a problem hiding this comment.
However, added .idea/README.md with comments anyway.
Continue efforts to try to resolve problems that prevent TeamCity from updating to IntelliJ 2018.2 engine, started in #7499 (which didn't help).
BTW, the master build now uses this version and all that problems can be seen here: https://teamcity.jetbrains.com/viewType.html?buildTypeId=OpenSourceProjects_Druid_Inspections