nx icon indicating copy to clipboard operation
nx copied to clipboard

NX 20: NX DevKit Undocumented Breaking Change

Open gcko opened this issue 1 year ago • 0 comments

Documentation issue

  • [ ] Reporting a typo
  • [X] Reporting a documentation bug
  • [X] Documentation improvement
  • [ ] Documentation feedback

Is there a specific documentation page you are reporting?

https://nx.dev/deprecated

Additional context or description

With the update to NX 20, any existing plugins that still make use of workspace in the ExecutorContext will now break. Although this has been marked as deprecated in the codebase since NX 16, it was not publicly disclosed in the NX 20 Release announcements and it does not show up in the deprecated section.

Link to Blame information: https://github.com/nrwl/nx/blame/d131b0b67709560d816b0df394c762e72a7b51d6/packages/nx/src/config/misc-interfaces.ts#L248-L253C60

For reference, this is what was removed

/**
   * Deprecated. Use projectsConfigurations or nxJsonConfiguration
   * The full workspace configuration
   * @todo(vsavkin): remove after v17
   */
  workspace?: ProjectsConfigurations & NxJsonConfiguration;

This caused an unexpected failure of at least one plugin that I am aware of: https://github.com/koliveira15/nx-sonarqube/issues/116

gcko avatar Oct 16 '24 07:10 gcko