Skip to content

url.parse result differences in 5.7.x to 5.6.x #5393

@tombell

Description

@tombell
  • Version: v5.7.0
  • Platform: Darwin Kernel Version 15.3.0: Thu Dec 10 18:40:58 PST 2015; root:xnu-3248.30.4~1/RELEASE_X86_64 x86_64

I updated to Node 5.7.0 today, which results in my Cordova build breaking due to a change in the output of url.parse.

In Node 5.5.0 the output of parsing https://* was the following:

{ protocol: 'https:',
  slashes: true,
  auth: null,
  host: '',
  port: null,
  hostname: '',
  hash: null,
  search: null,
  query: null,
  pathname: '/*',
  path: '/*',
  href: 'https:///*' }

However this changed when updating to 5.7.0:

Url {
  protocol: 'https:',
  slashes: true,
  auth: null,
  host: '',
  port: null,
  hostname: '',
  hash: null,
  search: null,
  query: null,
  pathname: null,
  path: null,
  href: 'https://' }

The pathname being null now broke the Cordova CLI library. Was this change intended to be breaking?

Metadata

Metadata

Assignees

No one assigned

    Labels

    confirmed-bugIssues with confirmed bugs.urlIssues and PRs related to the legacy built-in url module.

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions