community-skeleton
community-skeleton copied to clipboard
Mailbox / Email refresh not working
When running php bin/console uvdesk:refresh-mailbox [email protected]
I get the following error:
1. Processing uvdesk mailbox configuration.
Mailbox for email [email protected] not found.
However I have already setup that email.
I don't think I've done anything wrong my env is set to production.
Try once with a clear cache of your project.
Run this command for the clear cache of the project: php bin/console c:c
If you still have the same issue let us know.
I have cleared the cache and now the error that it is spitting out is
1. Processing uvdesk mailbox configuration.
2. Opening imap stream...
10:47:01 WARNING [php] Warning: imap_open(): Couldn't open stream mail.darkblue.co.za ["exception" => ErrorException { …}]
3. IMAP stream opened.
Try once with you delete all set up of your swift mailer, and mailbox settings, and change the .env file in dev mode then the clear cache of your project.
Now again set up the swift mailer and mailbox settings in the dev mode. Again run the refresh command for tickets fetch and once these settings work fine then again change the env file in prod mode.
So I'm getting a new error after doing that
2. Opening imap stream...
In RefreshMailboxCommand.php line 93:
Warning: imap_open(): Couldn't open stream mail.darkblue.co.za
uvdesk:refresh-mailbox [-t|--timestamp TIMESTAMP] [--] [<emails>...]
PHP Fatal error: Uncaught ErrorException: Notice: Unknown: Can't open mailbox mail.darkblue.co.za: no such mailbox (errflg=2) in Unknown:0
Stack trace:
#0 [internal function]: Symfony\Component\ErrorHandler\ErrorHandler->handleError()
#1 {main}
thrown in Unknown on line 0
@codefreak558
your imap configuration is not correct that's why you are getting the above error. Check your imap configuration & try again.
If you still facing the same issue then mail us at [email protected] with your query. Our team will help you.
I have checked my imap and the smtp settings and they are correct for what my email provider says it should be.
So in the error you see the imap host is mail.darkblue.co.za
however it can also be dedi12.cpt2.host-h.net
and it will work fine. I have tried with that host and it gave the same error.
@codefreak558
your host in imap should be like this {mail.darkblue.co.za:993/imap/ssl}INBOX
@vipin-shrivastava
Okay thanks it is working now
@vipin-shrivastava
Okay so I changed it to prod and its now giving a new error:
1. Processing uvdesk mailbox configuration.
2. Opening imap stream...
3. IMAP stream opened.
4. Fetching Email collection since 03 August 2022.
5. Total fetched email -> 1
6. Starting to convert Emails into Tickets ->
=============================================
=============================================
Converting email 1 out of 1.
Error -> 403 Forbidden
@codefreak558
Is this only giving error on prod mode?
I will check now I'll change it to dev mode now and test and see
No it does the same error in dev mode as well
@codefreak558
Request not able to hit the end point, you can try by whitelist URL on your server. URL: https://domain.com/your_project_name/public/mailbox/listener
I am not too sure what url you are trying to point to.
The mail server and the hosting server are on the same server, whenever I want to open up webmail for the emails I get a final url of: https://webmail7.konsoleh.co.za/?_task=mail&_mbox=INBOX
@codefreak558
Follow the below steps then you can understand what i am taking about:
- Open RefreshMailboxCommand.php in your project from path: your_project_name/vendor/uvdesk/mailbox-component/Console/RefreshMailboxCommand.php
- Now, put dump($requestUrl); die; on line no. 138
- Save the file & run the refershMailbox command in your project root directory.
- After run the command you can see a url. (eg. https://domain.com/your_project_name/public/mailbox/listener)
- Now you have to whitelist this url on your server.
@vipin-shrivastava
Okay so I've put dump($requestUrl); die;
on line 138 and when doing a mailbox refresh the url I get it: https://support.darkblue.co.za/public//mailbox/listener
and if you go to that specific page it doesnt work however when getting rid of the extra / it gives out a page that just says 200
@vipin-shrivastava
I am currently looking around in the folders to try and see if there is somewhere in the code where it is making it so that there is the extra slash in the url is there anyway I'd fix this as it looks like if it is able to get to that page properly it should work
Your issue is resolved now or not? If the issue is still let us know.
Hi, no it is still not working.
If you still facing the same issue then mail us at [email protected] with your query and screenshot of the errors. Our team will help you.
We are not getting any reply or ticket from your side so we are closing this issue. If you have any queries so reply in the same thread or mail us at [email protected].