Page MenuHomePhabricator

[Task] Use package manager
Closed, ResolvedPublic

Description

Use npm package manager to install and update dependencies.
Update script paths in index.html

package.json:

{
  "name": "Wikidata-Query-Service",
  "version": "0.0.1",
  "dependencies": {
    "jquery": "*",
    "codemirror": "*",
    "vis": "*",
    "bootstrap": "*"
  },
  "devDependencies": {
    "qunit": "*"
  },
  "scripts": {
    "test": "node ./test/run.js"
  }
}

Event Timeline

Jonas raised the priority of this task from to Needs Triage.
Jonas updated the task description. (Show Details)
Jonas added subscribers: Jonas, Aklapper.
Jonas set Security to None.
Jonas renamed this task from [Task] Use bower package manager to [Task] Use package manager.Oct 20 2015, 1:57 PM
Jonas updated the task description. (Show Details)

When will the package manager be run? How will the deployment process change?

When will the package manager be run? How will the deployment process change?

As far as I understood @Smalyshev there is no toolchain for deploying and building right now.

There is a toolchain for building (see above) but deployment is manual right now.

Question: Why is not the GUI a completely independent project / repo / build /deployment from WDQS?

One reason to not have to do a full maven build for every GUI patch can be seen here: https://integration.wikimedia.org/ci/job/wikidata-query-rdf/777/console. The CI failed because of a network problem.

Using npm is a really good idea, but perhaps the first step is to just split the front end out from the main Blazegraph package.

Why is not the GUI a completely independent project / repo / build /deployment from WDQS?

Good idea. Nobody did the work yet.

I already proposed that, so +2 from my side.

The reason why it was in the same project was that it is part of the full service package. But we could split out the component and import it using regular maven dependency handling, so that should not be a big issue. I propose making an new ticket for this.

I have actively started working on this. You can see the work here: https://github.com/christopher-johnson/wdqs-gui

Since using node requires a lot of refactoring and code style changes, I am interested in the developing the GUI as a separate dev branch or package. And when or if it meets with general approval, then it can be merged into production. I am using Gulp for the live build tasks and everything is installed with npm.

It also now runs completely independently of Blazegraph as a stand-alone app.

BTW current setup is already using npm, albeit only for testing.

Change 292907 had a related patch set uploaded (by Jonas Kress (WMDE)):
Use npm install to load vendor files

https://gerrit.wikimedia.org/r/292907

Change 292907 merged by jenkins-bot:
Use npm install to load vendor files

https://gerrit.wikimedia.org/r/292907