ProviderError: Must be authenticated!
at HttpProvider.request (D:\Testusinghardhat\node_modules\hardhat\src\internal\core\providers\http.ts:45:19)
at HDWalletProvider.request (D:\Testusinghardhat\node_modules\hardhat\src\internal\core\providers\accounts.ts:131:34)
at GanacheGasMultiplierProvider._isGanache (D:\Testusinghardhat\node_modules\hardhat\src\internal\core\providers\gas-providers.ts:175:30)
at GanacheGasMultiplierProvider.request (D:\Testusinghardhat\node_modules\hardhat\src\internal\core\providers\gas-providers.ts:164:23)
at EthersProviderWrapper.send (D:\Testusinghardhat\node_modules\@nomiclabs\hardhat-ethers\src\ethers-provider-wrapper.ts:13:20)
at Object.getSigners (D:\Testusinghardhat\node_modules\@nomiclabs\hardhat-ethers\src\helpers.ts:35:20)
at getContractFactoryByAbiAndBytecode (D:\Testusinghardhat\node_modules\@nomiclabs\hardhat-ethers\src\helpers.ts:242:21)
at getContractFactory (D:\Testusinghardhat\node_modules\@nomiclabs\hardhat-ethers\src\helpers.ts:69:29)
at main (D:\Testusinghardhat\scripts\deploy.js:4:21)
Thanks @abcoathup now its working … Instead of ProjectId of Infura i used alchemyApiKey so that was the mistake .now i changed to InfuraId now its working.
failed to get chainId, falling back on net_version...
An unexpected error occurred:
ProviderError: Must be authenticated!
at HttpProvider.request (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\http.ts:78:19)
at AutomaticSenderProvider.request (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\accounts.ts:351:34)
at AutomaticGasProvider.request (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\gas-providers.ts:136:34)
at AutomaticGasPriceProvider.request (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\gas-providers.ts:153:36)
at ChainIdValidatorProvider._getChainIdFromEthNetVersion (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\chainId.ts:33:45)
at ChainIdValidatorProvider._getChainId (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\chainId.ts:17:36)
at processTicksAndRejections (node:internal/process/task_queues:95:5)
at ChainIdValidatorProvider.request (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat\src\internal\core\providers\chainId.ts:55:29)
at DeploymentsManager.getChainId (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat-deploy\src\DeploymentsManager.ts:443:23)
at DeploymentsManager.loadDeployments (E:\medichain-nextjs\medichain-hardhat\node_modules\hardhat-deploy\src\DeploymentsManager.ts:619:17)
error Command failed with exit code 1.
I am getting this error