[Python] Problem installing agent on macOS M1

The latest version of the new relic agent pip3 is managing to install is 7.4.0.172 on macOS machines running M1 Apple Silicon processors (arm64).

All the newest versions of the agent fails to install due to “inconsistent metadata version” on the package.

Running Python 3.10.6 (latest available and installed via brew).

Follows a few parts of the output of a simple pip3 install -U newrelic:


Requirement already satisfied: newrelic in /opt/homebrew/lib/python3.10/site-packages (7.4.0.172)
Collecting newrelic
  Using cached newrelic-8.0.0.179.tar.gz (881 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/07/b9/44f9ab7751365d20fd81238455e9bc0964f65e425521fb021bbe300e5701/newrelic-8.0.0.179.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*): Requested newrelic from https://files.pythonhosted.org/packages/07/b9/44f9ab7751365d20fd81238455e9bc0964f65e425521fb021bbe300e5701/newrelic-8.0.0.179.tar.gz has inconsistent version: filename has '8.0.0.179', but metadata has '0.0.0'
  Using cached newrelic-7.16.0.178.tar.gz (879 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/b8/13/5c87086af3e52c191dc36d8d5ee4579172979d26d0728a283a54f85a4d3e/newrelic-7.16.0.178.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/b8/13/5c87086af3e52c191dc36d8d5ee4579172979d26d0728a283a54f85a4d3e/newrelic-7.16.0.178.tar.gz has inconsistent version: filename has '7.16.0.178', but metadata has '0.0.0'
  Using cached newrelic-7.14.0.177.tar.gz (879 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/a5/4f/1e5a7c7b21e25fb554ad534d028651ad2f55c2014521cf20a726d68439f1/newrelic-7.14.0.177.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/a5/4f/1e5a7c7b21e25fb554ad534d028651ad2f55c2014521cf20a726d68439f1/newrelic-7.14.0.177.tar.gz has inconsistent version: filename has '7.14.0.177', but metadata has '0.0.0'
  Using cached newrelic-7.12.0.176.tar.gz (871 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/64/32/156d412f77808f2983ff3799556a46e1ea65d9f2a0961c982b0a4c40a94c/newrelic-7.12.0.176.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/64/32/156d412f77808f2983ff3799556a46e1ea65d9f2a0961c982b0a4c40a94c/newrelic-7.12.0.176.tar.gz has inconsistent version: filename has '7.12.0.176', but metadata has '0.0.0'
  Using cached newrelic-7.10.0.175.tar.gz (858 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/76/7f/ced0b98ae790f58fb0b2c2a16bda995fa916140cca24b7697599a80fc6a9/newrelic-7.10.0.175.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/76/7f/ced0b98ae790f58fb0b2c2a16bda995fa916140cca24b7697599a80fc6a9/newrelic-7.10.0.175.tar.gz has inconsistent version: filename has '7.10.0.175', but metadata has '0.0.0'
  Using cached newrelic-7.8.0.174.tar.gz (852 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/35/4d/c1b1bbb730076282afbc161ae889dbd00da42e4b36d70046e2a843679252/newrelic-7.8.0.174.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/35/4d/c1b1bbb730076282afbc161ae889dbd00da42e4b36d70046e2a843679252/newrelic-7.8.0.174.tar.gz has inconsistent version: filename has '7.8.0.174', but metadata has '0.0.0'
  Using cached newrelic-7.6.0.173.tar.gz (847 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/85/e7/a6b658d85019ec9a587fc8cc967ab076f5e9a68c5d0479f0d9c3d9730d2f/newrelic-7.6.0.173.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*): Requested newrelic from https://files.pythonhosted.org/packages/85/e7/a6b658d85019ec9a587fc8cc967ab076f5e9a68c5d0479f0d9c3d9730d2f/newrelic-7.6.0.173.tar.gz has inconsistent version: filename has '7.6.0.173', but metadata has '0.0.0'

Hello @ygbr.

Thank you for reaching out and welcome to the Explorer’s Hub!

While this is out of scope for myself, I am going to loop in a support engineer from our Python team to help out. Please reach out if there are any changes on your end or if you have further questions. Our team will reach out via this post when available.

1 Like

Hi @michaelfrederick, did the support engineers from the Python team gave any feedback on this issue?

It seems this is still happening for the latest 8.1.0.180 version on M1 Macs:

Collecting newrelic
  Using cached newrelic-8.1.0.180.tar.gz (884 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Installing backend dependencies ... done
  Preparing metadata (pyproject.toml) ... done
Discarding https://files.pythonhosted.org/packages/73/59/9a1070788d2462bc38ed7af95f0c0878a597a82307daa60c1015443572b5/newrelic-8.1.0.180.tar.gz (from https://pypi.org/simple/newrelic/) (requires-python:>=2.7,!=3.0.*,!=3.1.*,!=3.2.*,!=3.3.*,!=3.4.*,!=3.5.*,!=3.6.*): Requested newrelic from https://files.pythonhosted.org/packages/73/59/9a1070788d2462bc38ed7af95f0c0878a597a82307daa60c1015443572b5/newrelic-8.1.0.180.tar.gz has inconsistent version: filename has '8.1.0.180', but metadata has '0.0.0'

This prevents some of our senior engineers and SRE to pre-test some newrelic application instrumentation on local dev environments (generally ARM Macs) before sending those changes to production (which runs on linux servers/containers)

I have also found an issue related to this on the newrelic python agent GitHub if anyone else wants to follow it:

https://github.com/newrelic/newrelic-python-agent/issues/621

Hi there @ygbr -

I think I may have the answer of you here which is that the M1 processor is not supported at this time. I can file a feature request for you on this if you would like.

Hi @hross,

I’d be glad if you could file a feature request for this.

Having NR agent support for dev environments running on Apple Silicon is vital for developers during integration of NR instrumentation on python applications.

Thanks

You got it! This has definitely been requested before and we will let you know if we hear anything.