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

Unable to use Identity in react-native #31713

Open
1 task
Chandanyadav opened this issue Nov 11, 2024 · 6 comments
Open
1 task

Unable to use Identity in react-native #31713

Chandanyadav opened this issue Nov 11, 2024 · 6 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. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that

Comments

@Chandanyadav
Copy link

Chandanyadav commented Nov 11, 2024

Describe the bug
In our Node.js application, we are utilizing the Azure Identity. However, upon running the server, I encounter the following issue within the Azure Identity package:

`/node_modules/@azure/identity/dist/index.js: child_process could not be found within the project or in these directories:
node_modules
../../node_modules
15 | var promises = require('fs/promises');
16 | var https = require('https');

17 | var child_process = require('child_process');
| ^
18 | var crypto = require('crypto');
19 | var util = require('util');
20 | var open = require('open');
`

I've located the file responsible for the error within the node_modules directory. This file contains the following code at the beginning:

`'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var msalCommon = require('@azure/msal-node');
var logger$o = require('@azure/logger');
var abortController = require('@azure/abort-controller');
var coreUtil = require('@azure/core-util');
var coreClient = require('@azure/core-client');
var coreRestPipeline = require('@azure/core-rest-pipeline');
var coreTracing = require('@azure/core-tracing');
var fs = require('fs');
var os = require('os');
var path = require('path');
var promises = require('fs/promises');
var https = require('https');
var child_process = require('child_process');
var crypto = require('crypto');
var util = require('util');
var open = require('open');
`

Screenshots

Image

@github-actions github-actions bot added Azure.Core 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. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team question The issue doesn't require a change to the product in order to be resolved. Most issues start as that labels Nov 11, 2024
Copy link

Copy link

Thank you for your feedback. Tagging and routing to the team member best able to assist.

@jeremymeng
Copy link
Member

I don't think we support @azure/identity on react-native yet. One of the reasons was that our dependency msal-node didn't provide good support either.

@xirzec xirzec assigned KarishmaGhiya and unassigned xirzec Nov 11, 2024
@xirzec xirzec changed the title node_modules/@azure/identity/dist/index.js: child_process could not be found within the project or in these directories in React Native Unable to use Identity in react-native Nov 11, 2024
@xirzec
Copy link
Member

xirzec commented Nov 11, 2024

@KarishmaGhiya are there auth flows we expect to work inside React Native?

@Chandanyadav
Copy link
Author

Chandanyadav commented Nov 12, 2024

Do we have any alternate approach to sending events to event-hubs in React native? (https://learn.microsoft.com/en-us/azure/event-hubs/event-hubs-node-get-started-send?tabs=passwordless%2Croles-azure-portal)

@jeremymeng
Copy link
Member

Do we have any alternate approach to sending events to event-hubs in React native? (https://learn.microsoft.com/en-us/azure/event-hubs/event-hubs-node-get-started-send?tabs=passwordless%2Croles-azure-portal)

@Chandanyadav you should probably log a new issue as this is for @azure/identity. It is possible to send events via REST api https://learn.microsoft.com/en-us/rest/api/eventhub/. I also have been working on a prototype of client SDK for that. Note that consuming is not supported via REST.

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. needs-team-attention Workflow: This issue needs attention from Azure service team or SDK team 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

4 participants