Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure function TSC build errors in msal-node #33208

Open
2 of 3 tasks
pragmatta opened this issue Feb 26, 2025 · 0 comments
Open
2 of 3 tasks

Azure function TSC build errors in msal-node #33208

pragmatta opened this issue Feb 26, 2025 · 0 comments
Assignees
Labels
Azure.Identity Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that

Comments

@pragmatta
Copy link

pragmatta commented Feb 26, 2025

  • Package Name: @azure/identity
  • Package Version: 4.7.0
  • Operating system: Windows (dev), Linux (Azure function)
  • nodejs
    • version: 22
  • browser
    • name/version:
  • typescript
    • version:

Describe the bug
After updating my Azure function packages, started getting TSC build errors in VSCode "Deploy to web app". First noticed this on function I had changed but getting same error on different function that was not changed. Looks like a regression in JS build.

> tsc

node_modules/@azure/msal-common/lib/types/broker/nativeBroker/INativeBrokerPlugin.d.ts:1:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

1 /// <reference types="node" resolution-mode="require"/>
                        ~~~~

node_modules/@azure/msal-common/lib/types/broker/nativeBroker/INativeBrokerPlugin.d.ts:2:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

2 /// <reference types="node" resolution-mode="require"/>
                        ~~~~

node_modules/@azure/msal-node/dist/config/Configuration.d.ts:1:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

1 /// <reference types="node" resolution-mode="require"/>
                        ~~~~

node_modules/@azure/msal-node/dist/config/Configuration.d.ts:2:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

2 /// <reference types="node" resolution-mode="require"/>
                        ~~~~

node_modules/@azure/msal-node/dist/config/Configuration.d.ts:4:8 - error TS1192: Module '"http"' has no default export.

4 import http from "http";
         ~~~~

node_modules/@azure/msal-node/dist/config/Configuration.d.ts:5:8 - error TS1192: Module '"https"' has no default export.

5 import https from "https";
         ~~~~~

node_modules/@azure/msal-node/dist/request/InteractiveRequest.d.ts:1:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

1 /// <reference types="node" resolution-mode="require"/>
                        ~~~~

node_modules/@azure/msal-node/dist/request/InteractiveRequest.d.ts:2:23 - error TS1452: 'resolution-mode' assertions are only supported when `moduleResolution` is `node16` or `nodenext`.

2 /// <reference types="node" resolution-mode="require"/>
                        ~~~~


Found 8 errors in 3 files.

Errors  Files
     2  node_modules/@azure/msal-common/lib/types/broker/nativeBroker/INativeBrokerPlugin.d.ts:1
     4  node_modules/@azure/msal-node/dist/config/Configuration.d.ts:1
     2  node_modules/@azure/msal-node/dist/request/InteractiveRequest.d.ts:1

To Reproduce
Not sure what exactly is needed for replication but these azure packages are required and azure/identity is required by them and msal-node by that
"@azure/functions": "^4.0.0",
"@azure/core-http": "^3.0.0",
"@azure/keyvault-secrets": "^4.0.0",
"@azure/storage-queue": "^12.25.0",
"@azure/communication-email": "^1.0.0",

Expected behavior
Building Azure functions should succeed.

Additional context
I have also reported this to msal-node
AzureAD/microsoft-authentication-library-for-js#7593

@github-actions github-actions bot added customer-reported Issues that are reported by GitHub users external to the Azure organization. needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Feb 26, 2025
@jeremymeng jeremymeng added Client This issue points to a problem in the data-plane of the library. Azure.Identity labels Feb 26, 2025
@github-actions github-actions bot removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Feb 26, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Azure.Identity Client This issue points to a problem in the data-plane of the library. customer-reported Issues that are reported by GitHub users external to the Azure organization. question The issue doesn't require a change to the product in order to be resolved. Most issues start as that
Projects
Status: Untriaged
Development

No branches or pull requests

3 participants