question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support running on M1 Macs [PowerShell]

See original GitHub issue

I’m testing an arm64 build of core tools and the PowerShell worker cannot run. Note, I’m testing with PowerShell 7.2 as that is the first version that supports arm64 (see here).

This is the error I’m running into:

Unhandled exception. System.IO.IOException: Error loading native library “/Users/erijiz/tools/func-arm/workers/powershell/7.2/runtimes/osx/native/libgrpc_csharp_ext.x64.dylib”. [2022-02-04T21:37:02.426Z] at Grpc.Core.Internal.UnmanagedLibrary…ctor(String[] libraryPathAlternatives)

I tried updating the Grpc.Core package, but it didn’t help. The latest source code for the Grpc.Core package does not list osx-arm64 (see here) and I don’t expect them to add it considering the package is in maintenance mode. I believe the only fix will be to switch to the new grpc-dotnet package (see #751), which does not use any native dependencies.

The only workaround for users right now is to try x64 emulation.

I recommend the PowerShell worker team addresses #751 and then I’d be happy to test the worker on my M1 Mac again.

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5

github_iconTop GitHub Comments

2reactions
ejizbacommented, May 17, 2022

I tested func start with an http, timer, & queue function on v4.5.0 of the host (which includes the fix for https://github.com/Azure/azure-functions-powershell-worker/issues/751) and everything appears to be working now on an M1 Mac 🎉

As noted earlier, this only applies to PowerShell 7.2

1reaction
invisibleaxmcommented, Jul 21, 2022

i know its an old issue but wanted to say thanks as this was a major blocker for me. Thumbs up!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Installing PowerShell on macOS
PowerShell 7.0 or higher require macOS 10.13 and higher. All packages are available on our GitHub releases page. After the package is installed, ......
Read more >
Support running on M1 Macs · Issue #2834 · Azure ...
Update: Core tools support for M1 macs has been released for both npm and brew. In addition to work on core tools, each...
Read more >
Learn PowerShell on MacBook M1 - is it possible?
You can absolutely use/learn PowerShell 7 on a MacBook M1. My primary machine is a MacBook Pro M1 and I use PowerShell 7...
Read more >
Install Powershell in Mac OS + m1 chip - YouTube
Install Powershell in Mac OS + m1 chip - Install brew, run : brew install --cask powershell /bin/bash -c "$(curl -fsSL ...
Read more >
Boost Your PowerShell 7 on M1 macOS: Ultimate Installation ...
PowerShell 7 is supported on M1 macOS. You can install it on your M1-based Mac to utilize the powerful command-line tool and enhance...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found