Alveo / alveo-transcriber

Web application to transcribe data for the Alveo project
https://alveo.github.io/alveo-transcriber/
BSD 3-Clause "New" or "Revised" License
1 stars 1 forks source link

Angular5 upgrade: angular2-json2csv broken #3

Closed davidlirving closed 6 years ago

davidlirving commented 6 years ago
ERROR in ./node_modules/angular2-json2csv/src/csv.service.ts
Module build failed: Error: /home/david/git/alveo-transcriber/node_modules/angular2-json2csv/src/csv.service.ts is missing from the TypeScript compilation. Please make sure it is in your tsconfig via the 'files' or 'include' property.
The missing file seems to be part of a third party library. TS files in published libraries are often a sign of a badly packaged library. Please open an issue in the library repository to alert its author and ask them to package the library using the Angular Package Format (https://goo.gl/jB3GVv).
    at AngularCompilerPlugin.getCompiledFile (/home/david/git/alveo-transcriber/node_modules/@angular/cli/node_modules/@ngtools/webpack/src/angular_compiler_plugin.js:653:23)
    at plugin.done.then (/home/david/git/alveo-transcriber/node_modules/@angular/cli/node_modules/@ngtools/webpack/src/loader.js:467:39)
    at <anonymous>
    at process._tickCallback (internal/process/next_tick.js:160:7)
 @ ./node_modules/angular2-json2csv/index.js 2:20-48
 @ ./src/app/annotator/annotator.module.ts
 @ ./src/app/alveo/alveo.module.ts
 @ ./src/app/app.module.ts
 @ ./src/main.ts
 @ multi ./src/main.ts

As per https://github.com/angular/angular-cli/issues/8284

You have TS files in your node_modules. This really goes against how libraries should be packaged: libraries should never ship their source .ts files.

angular2-json2csv is not considered packaged correctly and is currently unusable

Disabling for now

davidlirving commented 6 years ago

Replaced angular2-json2csv with json2csv in commit https://github.com/Alveo/alveo-transcriber/commit/4e92f7d1ca27d10ff38e4894c5afb59d7b2e96f7

CSV exports work once more, and now output field information too.