Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

7.11.2 - Cases not being created from emails #7096

Closed
cartbar opened this issue Mar 25, 2019 · 9 comments
Closed

7.11.2 - Cases not being created from emails #7096

cartbar opened this issue Mar 25, 2019 · 9 comments
Labels
Priority:Critical Issues & PRs that are critical; broken core functionality, fatal errors - there are no workarounds Type: Bug Bugs within the core SuiteCRM codebase

Comments

@cartbar
Copy link

cartbar commented Mar 25, 2019

Issue

I have updated from SuiteCRM version 7.10.9 to 7.11.2 and now inbound emails are not being converted to Cases

Expected Behavior

When an email is sent to an inbound email account monitored by SuiteCRM, it should create a case

Actual Behavior

No case is created

Possible Fix

In version 7.10.9, the check for inbound emails is done in modules/InboundEmail/InboundEmail.php, method getNewMessageIds(), line 6081:

$ret = imap_search($this->conn, 'UNDELETED UNSEEN');

In version 7.11.2, this is done in include/Imap/ImapHandler.php, method search(), line 724:

$ret = imap_search($this->getStream(), $criteria, $options, $emailCharset);
The value of $options is 2 (SE_FREE) and $emailCharset is UTF-8. For some reason, this always returns FALSE, even if there are unread emails. However, removing the $emailCharset parameter allows it to work

Steps to Reproduce

Context

Your Environment

  • SuiteCRM Version used:
  • Browser name and version (e.g. Chrome Version 51.0.2704.63 (64-bit)):
  • Environment name and version (e.g. MySQL, PHP 7):
  • Operating System and version (e.g Ubuntu 16.04):

Version 7.11.2
Sugar Version 6.5.25 (Build 344)
PHP 7.1.6

@samus-aran
Copy link
Contributor

Ummm... Can you clarify this issue as you raised a issue stating that it does create a case if sending an email to SuiteCRM.
#7097

So you either need to close this one as a non issue or provide more information.

You should include Steps to Reproduce because you could be doing slightly differently that others.

@samus-aran samus-aran added the Status: Requires Updates Issues & PRs which requires input or update from the author label Mar 25, 2019
@cartbar
Copy link
Author

cartbar commented Mar 25, 2019

I put in a fix (getting rid of the last parameter) to allow me to continue working, at which point I came across bug 7097. All in all, not having a very productive day with SuiteCRM.

Steps to reproduce:

  1. Install SuiteCRM 7.10.9
  2. Set up an inbound email account, configured to create a case on receiving an email
  3. Check that it works as expected (i.e. send an email to that address and see that a case is created)
  4. Upgrade to version 7.11.2
  5. Send an email to the same email address and notice that no case is being created
  6. Spend half a day debugging SuiteCRM code to figure out what change has cause this to stop working
  7. Raise a case in the hope that someone will look at the problem

@samus-aran
Copy link
Contributor

Thanks for clarifying that.

  1. We'll look at this and verify it on our end.
  2. May ask for more information
  3. Assign developer if required
  4. Raise a PR and ask the community to help test
  5. Merge and include it in next schedule release

👍
What imap client are you using? e.g. Gmail or something else? Its to see if therte is anything obviously different with the formats if you are indicating that removing that parameter help plug this issue for the time being.

@samus-aran samus-aran removed the Status: Requires Updates Issues & PRs which requires input or update from the author label Mar 25, 2019
@cartbar
Copy link
Author

cartbar commented Mar 25, 2019

I'm not sure I understand the question. The IMAP client, as far as I understand it, is the PHP code within SuiteCRM. The IMAP server is my company's Window mail server

@cartbar
Copy link
Author

cartbar commented Mar 25, 2019

Looks like this is an issue that other people are having with Microsoft Exchange - barbushin/php-imap#128, Webklex/laravel-imap#100

@willrennie
Copy link
Contributor

I've tested this functionality in 7.10.14(latest 7.10 release), 7.11.2(latest 7.11 release) and also specifically testing the 7.10.9->7.11.2 upgrade process and then tested the functionality post upgrade. I see from your latest update regarding Microsoft exchange and the encoding. It also appears there is another related issue with auto importing also not working, related to Microsoft Exchange and the UTF-8 character set: #6866 I'll mark this as a bug for now and work on assessing further.

@willrennie willrennie added Type: Bug Bugs within the core SuiteCRM codebase Priority:Critical Issues & PRs that are critical; broken core functionality, fatal errors - there are no workarounds labels Mar 26, 2019
@Dillon-Brown
Copy link
Contributor

Should be resolved by #7459. Let me know if this is still an issue you can replicate and we'll re-investigate. Thanks.

@fcorluka
Copy link

fcorluka commented Sep 3, 2019

For my version (upgrade from 7.8.27. -> 7.10.19) this is not working.
To be precise, if I use GMAIL account it works when it is Microsoft 365 then not.

Logs are of no help.

@fcorluka
Copy link

fcorluka commented Sep 4, 2019

Can anyone confirm that this functionality is working with Microsoft Office 365?
Thank you, Filip

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Priority:Critical Issues & PRs that are critical; broken core functionality, fatal errors - there are no workarounds Type: Bug Bugs within the core SuiteCRM codebase
Projects
None yet
Development

No branches or pull requests

5 participants