@Boris Layvant Thanks for reaching out.
As per the error it looks like the assembly couldn't found. In the past I do see the same behavior customer reporting the same here. Uninstalling all version of func-cli (core tool) and azure-cli, and then re-installing it with the latest issue fixed this issue.
I'm glad that you were able to resolve your issue and thank you for posting your solution so that others experiencing the same thing can easily reference this! Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others", I'll repost your solution in case you'd like to "Accept" the answer.
Issue:
You observed below error creating the azure function using CLI
Microsoft.Azure.WebJobs.Extensions.Http: Could not load file or assembly 'System.Net.Http.Formatting, Version=5.2.8.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35'. The system cannot find the file specified.`
`Value cannot be null. (Parameter 'provider')
Solution:
Suggested you to uninstall and install the function core tool and azure cli and see if it helps you to resolve the issue. You confirmed that you were able to resolve the issue by clearing nuget cache and re-installing Azure Functions Core Tools following https://github.com/Azure/azure-functions-core-tools/issues/3096
Thank you again for your time and patience throughout this issue.