So I am following this tutorial [https://www.youtube.com/watch?v=74zOY-vgkyw&list=PLEoMzSkcN8oPH1au7H6B7bBJ4ZO7BXjSZ&index=3&t=220s](https://www.youtube.com/watch?v=74zOY-vgkyw&list=PLEoMzSkcN8oPH1au7H6B7bBJ4ZO7BXjSZ&index=3&t=220s) and I have been receiving the error mentioned in the title. I tried searching it up to see if I could find any solutions and the only thing I could find suggested that I run the following command `M-x package-refresh-contents` which gave me a new error `Failed to download 'elpa' archive` I tried looking this error up online but I couldn't find a clear solution.
This is the config I am using
(setq inhibit-startup-message t)
(tooltip-mode -1) ; relegate tooltips to echo area only
(menu-bar-mode -1) ; disable the menu bar
(if (fboundp 'tool-bar-mode)
(tool-bar-mode -1)) ; disable the toolbar
(if (fboundp 'scroll-bar-mode)
(scroll-bar-mode -1)) ; disable visible scrollbar
(menu-bar-mode -1) ; Disable the menu bar
;; Set up the visible bell
(setq ring-bell-function #'ignore
visible-bell nil)
(add-to-list 'default-frame-alist '(fullscreen . maximized))
(set-face-attribute 'default nil :height 150)
(load-theme 'tango-dark)
;; Initialize package sources
(require 'package)
(setq package-archives '(("melpa", "https://melpa.org/packages/")
("org", "https://orgmode.org/elpa/")
("elpa", "https://elpa.gnu.org/packages/")))
(package-initialize)
(unless package-archive-contents
(package-refresh-contents))
;; Intialize package on non linux platforms
(unless (package-installed-p 'use-package)
(package-install 'use-package))
(require 'use-package)
(setq use-package-always-ensure t)
Also not sure if this helps but I am on a M1 Mac running Monterey and I am using GNU Emacs 28.1