Skip to content

nodejs_binary with invalid entry_point #692

Closed

Description

@manekinekko

The bin entry is empty, in this file can be empty: https://github.com/bazelbuild/rules_nodejs/blob/master/internal/npm_install/generate_build_file.js#L774 (edited)

And we end up with:

# /xxx/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel
nodejs_binary(
    name = "terser-webpack-plugin__bin",
    entry_point = ":", <---- THIS
    install_source_map_support = False,
    data = [":terser-webpack-plugin__pkg"],
)

This seems to be related to @npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files.

Detailed error logs: ``` Unlinking deps in /internal/e2e/bazel_workspaces_compat + sedi s#"file:///Users/wassim/OSPO/projects/rules_nodejs/dist/npm_bazel_\([a-z_]*\)$*[0-9]*"#"bazel://@npm_bazel_\1//:npm_package"# package.json

Running legacy e2e test fine_grained_symlinks
Unlinking deps in /internal/e2e/fine_grained_symlinks

  • sedi s#"file:///Users/wassim/OSPO/projects/rules_nodejs/dist/npm_bazel_([a-z_])$[0-9]*"#"bazel://@npm_bazel_\1//:npm_package"# package.json
    checking deps: release
    all deps built
    Linking deps in /internal/e2e/fine_grained_symlinks
  • yarn test
    yarn run v1.13.0
    warning package.json: No license field
    $ bazel test //...
    DEBUG: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/build_bazel_rules_nodejs/internal/jasmine_node_test/jasmine_node_test.bzl:45:5:
    WARNING: @build_bazel_rules_nodejs will no longer provide jasmine_node_test at a later release
    Instead, add a devDependency on @bazel/jasmine
    and change the load statement to
    load("@npm_bazel_jasmine//:index.bzl", "jasmine_node_test")

ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:821:1: @npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__bin_bin: invalid label ':' in attribute 'entry_point' in 'nodejs_binary' rule: ':' is not a valid package-relative label
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:821:1: @npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__bin_bin: missing value for mandatory attribute 'entry_point' in 'nodejs_binary' rule
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:CHANGELOG.md' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:LICENSE' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:README.md' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/TaskRunner.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/cjs.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/index.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/minify.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/options.json' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:dist/worker.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/.bin/terser' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/.bin/webpack' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/CHANGELOG.md' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/LICENSE' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/README.md' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/package.json' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/src/ValidationError.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/src/index.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:node_modules/schema-utils/src/validateOptions.js' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/terser-webpack-plugin/BUILD.bazel:788:1: Target '@npm//node_modules/terser-webpack-plugin:package.json' contains an error and its package is in error and referenced by '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files'
ERROR: /private/var/tmp/_bazel_wassim/f873c5279f1132570d4684bf1f4ac2c4/external/npm/node_modules/webpack/BUILD.bazel:593:1: Target '@npm//node_modules/terser-webpack-plugin:terser-webpack-plugin__files' contains an error and its package is in error and referenced by '@npm//node_modules/webpack:webpack__pkg'
ERROR: Analysis of target '//:test' failed; build aborted: Analysis failed
INFO: Elapsed time: 0.536s
INFO: 0 processes.
FAILED: Build did NOT complete successfully (0 packages loaded, 101 targets configured)
FAILED: Build did NOT complete successfully (0 packages loaded, 101 targets configured)

</details>

Activity

  1. self-assigned this
    on Apr 15, 2019
  2. added a commit that references this issue on Jun 6, 2019
    188ae59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions