Bug 748711

Summary: DRL parser expects a newline at the end of the file
Product: [JBoss] JBoss Enterprise BRMS Platform 5 Reporter: Tomas Schlosser <tschloss>
Component: BRE (Expert, Fusion)Assignee: Nobody <nobody>
Status: VERIFIED --- QA Contact: Lukáš Petrovický <lpetrovi>
Severity: low Docs Contact:
Priority: unspecified    
Version: BRMS 5.3.0.GACC: atangrin, kverlaen, lpetrovi, mproctor
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Including a comment on the last line of a DRL file, caused a no viable alternative error to occur and the parser to return a null package. This has been resolved and the no viable alternative error no longer occurs.
Story Points: ---
Clone Of: Environment:
Last Closed: Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Attachments:
Description Flags
Simple reproducer none

Description Tomas Schlosser 2011-10-25 05:53:12 UTC
Created attachment 530001 [details]
Simple reproducer

Description of problem:
If you put a comment on the last line of the DRL file you end up with no viable alternative error and no packages.

Version-Release number of selected component (if applicable):
BRMS-5.2.0.GA

How reproducible:
Every time.

Steps to Reproduce:
1. Run the included class
  
Actual results:
[7,19]: [ERR 101] Line 7:19 no viable alternative at input ''
[0,0]: Parser returned a null Package

Expected results:
Hello world!
Finished...

Additional info:

Comment 3 Iva Zakova 2012-07-23 14:18:19 UTC
A pull request for this issue was created: https://github.com/droolsjbpm/drools/pull/130

Comment 4 Edson Tirelli 2012-08-16 22:28:17 UTC
Porcelli,

Can you please take a look at this. Lets talk on IRC and I can tell you why this is happening.

Thanks

Comment 5 Alexandre Porcelli 2012-08-20 17:42:01 UTC
Fix already available on master, 5.4.x and 5.3.x branches of Drools project.

Comment 6 Iva Zakova 2012-09-17 07:33:44 UTC
Verified in 5.3.1.ER1.