Closed (fixed)
Project:
DrupalCI: Test Runner
Component:
Jobs and Job Handling
Priority:
Major
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
24 Oct 2015 at 20:43 UTC
Updated:
7 Mar 2017 at 18:34 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
elachlan commentedFirst roll at the patch.
Comment #3
elachlan commentedComment #4
attiks commentedThat should be it
Comment #5
elachlan commentedParent issue was marked as major, as this is blocking I am marking it as major.
Comment #6
elachlan commentedComment #7
elachlan commentedBoth this issue and #2605308: Add csslint to the testrunners required nodejs and npm. Should we create a separate issue to add those first?
Comment #8
yesct commentedComment #9
elachlan commentedWe are kind of waiting for #2609560: Base DCI containers off official containers.
Since it adds nodejs/npm to the image.
Which then allows us to do this step.
Comment #10
MixologicComment #11
wim leersUpdating issue to reflect #9.
Also commented at #2609560-33: Base DCI containers off official containers, and bumped that to major, since it blocks this major issue.
Comment #12
wim leersThis blocks #2575501: [PP-2] DrupalCI should return failed for poor code style - JS, so tagging.
Comment #13
GrandmaGlassesRopeManJust a couple of issues. Installing
eslintis probably not what we want to do, this will keep the version ofeslintlocked at the time of the Docker image creation, any additional improvements we will miss out on. Leaving the install ofeslintto thepackage.jsonthat should be included with core will help.Comment #14
wim leers#13: but that would mean the environment would need to be updated for every test run. Because the same test runner must be used for Drupal 8.1, 8.2, 8.3 …
So I think it's more feasible to specify a particular version of eslint, and then frequently update it: whenever core updates it. Or, alternatively, use whatever the latest
eslintis. Or does it change frequently in non-BC ways?Comment #15
nod_There is a new release 2-3 times a months these days. Fixing bugs, not introducing BC issues (it follows semver).
Comment #16
GrandmaGlassesRopeManDon't we download the PHP dependencies with
composereach time? This feels mostly the same.Comment #17
wim leerscomposerfetches code that is part of the Drupal application. It includes code that is executed.eslintis neither.Comment #18
elachlan commentedThe idea behind #2609560: Base DCI containers off official containers was to reduce rebuild time for containers so that doing updates several times a month would not be a hassle.
So doing this change is a good thing.
Comment #19
mile23It is the same.
For instance, all Drupal PHP CS issues are against coder 8.2.8 right now: #2744463: Add phpcs, coder 8.2.8 as --dev requirements for drupal/core Once that patch is in, both the testbot and all developers will end up installing and using the same version of the tool so we can have consistency.
The same should be true of eslint. Is there an issue in core for adding a package.json file? Once that's present we can do
npm install.As far as the environment present on the testbot, we'd need to specify npm in order to manage the package. HOWEVER. :-) Testbot is still undergoing some architectural shifts and we're not sure exactly where this functionality will land. So we can't just add it right now.
Comment #20
nod_#2809165: Add package.json to Drupal
Comment #21
mile23Core now has
core/package.jsonafter #2809477: Add ES6 to ES5 build processUnless I'm completely mistaken, that means we should use
npmto build out core's JS dependencies during the build process. That will give useslintwhich we can then execute from acode_assessmentbuild step. That will see core's.eslintrc.jsonfile and do an assessment.So the test environment needs node/npm, so we can make an npm plugin and an eslint plugin.
Comment #22
MixologicThe design philosophy of drupalci has altered somewhat in that we are now focusing on having a defined host environment for running a testbot.
What this means is that we do not need to rely on docker containers in order to add codebase validation or building functionality to the testbots, as we can rely on that software being installed on the host.
As such, I've added npm/node to the host system and it now exists in both the AMI as well as in the vagrant box. eslint will update whenever we update the hostAMI or the packer build (it will not be installed as part of the build process) as such, drpal's concerns about eslint getting behind are valid, however its probably stable enough that we do not need to be on the bleeding edge of it, and its very easy to update the version/ami at will.
This is no longer blocking eslint/csslint, and work is already proceeding on those, so Im marking this fixed.
Comment #23
GrandmaGlassesRopeMan@Mixologic
Could you clarify which version of Node, eslint are installed currently?
Comment #24
MixologicSure thing: