SAP / cloud-sdk-js

Use the SAP Cloud SDK for JavaScript / TypeScript to reduce development effort when building applications on SAP Business Technology Platform that communicate with SAP solutions and services such as SAP S/4HANA Cloud, SAP SuccessFactors, and many others.
Apache License 2.0
161 stars 55 forks source link

Build error happened with @sap-cloud-sdk/core@1.48.0 #1536

Closed zjhua2002 closed 3 years ago

zjhua2002 commented 3 years ago

Hello Colleagues,

The baf-date-time releasev13 pipelines are failed : Build error happened with @sap-cloud-sdk/core@1.48.0(refer to log info section below).

Could you Please help to fix the issue?

To Reproduce Steps to reproduce the behavior:

  1. Set up in local machine git clone git@github.wdf.sap.corp:BIG/baf-date-and-time.git
  2. Execute npm install npm run build
  3. See error

Expected behavior build successfully without errors. Previously we can build successfully with @sap-cloud-sdk/core@1.31.0

Screenshots n/a

Used Versions: $ node -v v14.16.0

Code Examples n/a

Log file 08:15:05 node_modules/@sap-cloud-sdk/core/dist/odata-common/selectable/enum-field.d.ts(51,50): error TS1110: Type expected. 08:15:05 npm ERR! code ELIFECYCLE 08:15:05 npm ERR! errno 2 08:15:05 npm ERR! @sap/baf-date-and-time@13.3.7 build: tsc 08:15:05 npm ERR! Exit status 2 08:15:05 npm ERR! 08:15:05 npm ERR! Failed at the @sap/baf-date-and-time@13.3.7 build script. 08:15:05 npm ERR! This is probably not a problem with npm. There is likely additional logging output above. 08:15:05
08:15:05 npm ERR! A complete log of this run can be found in: 08:15:05 npm ERR! /home/node/.npm/_logs/2021-08-23T02_45_04_202Z-debug.log

Additional context n/a

FrankEssenberger commented 3 years ago

Hi @zjhua2002,

since we just released version 1.48.0 I wonder if this brought in the error. Could you perhaps fix the SDK version to the previous release and check if the error persists? This would help cornering the root cause.

Best Frank

jjtang1985 commented 3 years ago

Hi @zjhua2002 ,

I guess this error error TS1110: Type expected occurs typically because of an old TypeScript version. Could you please try version 4.1.5 or newer version of TypeScript and see whether this will fix the issue?

Best regards, Junjie

zjhua2002 commented 3 years ago

Hello @jjtang1985

Thanks for your tips. After I changed my typescript to higher version, now it works fine now. Thanks.

Best regards, Peyton Zhong