What are you using to read email? Only Mail on the Mac where OmniFocus is running, or with multiple devices and/or programs? If the message has been incorporated into your mail file and is no longer "new" when Mail gets it, the processing will not be done. You can protect yourself from this problem by setting up a separate gmail account for actions you are sending yourself, and never check the email in that account anywhere except from Mail on the machine where you have OmniFocus.
An easy way to test if this is what is affecting you is to edit the rule created in Mail by OmniFocus to do something like first flagging the message before doing the rest of the processing. If the message gets flagged, that means the rule was run and your problem is elsewhere (if it didn't appear in OmniFocus). If the message doesn't get flagged, the rule was not run and the likely reason for that is that Mail didn't regard it as a new message.
If the messages always get flagged, I would then verify that you are always sending plain text messages, not HTML or RTF formatted messages. The gmail web interface has a setting for message composition which can produce formatted messages which the Applescript internals of the Mail processing code will not handle. If you are sending from multiple clients, and there is a pattern in which messages do not appear, that may be your answer.
Finally, make sure that all the email addresses from which you are sending messages to OmniFocus are listed in the "Allowed From addresses" section of the OmniFocus Mail preferences.
In sum, there are 3 main ways in which you can have problems:
- OmniFocus doesn't get the message because the rule was never run
- OmniFocus doesn't get the message because the sender isn't authorized
- OmniFocus gets the message, but can't understand it because of improper formatting or structure