(I’ve also removed the ‘<’ and ‘>’ symbols surrounding my password, shown below, which I believe should not have been there in the first place, and that did not work either)
Correct, they should not be there. Also, now I remember why I stopped using Replit, this exact reason. I could never get the secrets editor to work, so I just copied everything over to glitch.com on their editor and it worked fine. I think it has something to do with the way it formats.
My .env on any other editor appears like this:
MONGO_URI="mongodb+srv://~~~~~~~"
Aside from that, the only other thing I can think of that was stopping me from connecting was that I was using my account name and password (doesn’t work) instead of my authorized user name and password. Beside that I am not sure, never could get Replit to work with my database and also could not find an answer for making it work. I just went to Glitch (or codesandbox) because your .env file works exactly the same as VSCode (just name a file .env and input your secrets).
I wish I had the actual answer because it would have saved me a day of troubleshooting a couple months ago.
So, you have a malformed URI. Setting MONGO_URI to the string you get from your MongoDB account like mongodb+srv://user:pass@cluster... in repl.it secrets editor will work, even without using the advanced version. The user has to be the database user and its password, not the username/password you use to login to your cloud.mongodb.com account.
The URI is available from the project page (with the graphs). Click “connect” above the graphs and then select the “connect your application” option. Copy the URI and replace <password> with your database user password which is editable from the project page by selecting “database access” under “security” on the left and then editing the appropriate user.
I forked your project, added by credentials, and passed the test without incident.