abp icon indicating copy to clipboard operation
abp copied to clipboard

Angular proxy generation: nullable array is generated as non-nullable

Open hillin opened this issue 8 months ago • 0 comments

Is there an existing issue for this?

  • [x] I have searched the existing issues

Description

All nullable arrays are generated as non-nullable in the javascript proxy.

Welcome to a new episode of proxy generation bugs ;-) Given the abundant bugs in this area, IMHO the abp team should throughly review the proxy generation system.

Reproduction Steps

public class MyDto {
  public int[]? IntArray { get; set; }
  public string[]? StringArray { get; set; }
}
> abp help     
ABP CLI 9.2.0-rc.2
> abp generate-proxy -t ng --entry-point .
export interface MyDto {
  intArray: number[];  // should be nullable
  stringArray: number[];  // should be nullable
}

Expected behavior

Generate properties with correct nullablility.

Actual behavior

All nullable array properties are generated as non-nullable.

Regression?

Possibly.

Known Workarounds

No response

Version

9.2.0-rc2

User Interface

Angular

Database Provider

None/Others

Tiered or separate authentication server

None (Default)

Operation System

Windows (Default)

Other information

https://github.com/abpframework/abp/issues/21995 https://github.com/abpframework/abp/pull/22037 https://github.com/abpframework/abp/issues/22118 https://github.com/abpframework/abp/pull/22120 https://github.com/abpframework/abp/issues/22132

hillin avatar Apr 29 '25 10:04 hillin