The error I am getting is "User cannot be resolved to a type."  It is occurring 
in Main.WO, and also shows up multiple times when the app is run. "User" is the 
name of the eomodel, and the User and _User  files are in the package in 
Sources.  The app launches, but when I click on the submit button (it's a login 
page), the app crashes with:

Original Exception:
java.lang.reflect.InvocationTargetException
at 
com.webobjects.appserver._private.WOActionRequestHandler._handleRequest(WOActionRequestHandler.java:269)
at 
com.webobjects.appserver._private.WOActionRequestHandler.handleRequest(WOActionRequestHandler.java:158)
at 
er.extensions.appserver.ERXDirectActionRequestHandler.handleRequest(ERXDirectActionRequestHandler.java:126)
at 
com.webobjects.appserver.WOApplication.dispatchRequest(WOApplication.java:1687)
at 
er.extensions.appserver.ERXApplication.dispatchRequestImmediately(ERXApplication.java:2021)
at 
er.extensions.appserver.ERXApplication.dispatchRequest(ERXApplication.java:1986)
at 
com.webobjects.appserver._private.WOWorkerThread.runOnce(WOWorkerThread.java:144)
at com.webobjects.appserver._private.WOWorkerThread.run(WOWorkerThread.java:226)
at java.lang.Thread.run(Thread.java:680)
Caused by: java.lang.Error: Unresolved compilation problem: 
The method set_currentUser(User) from the type Session refers to the missing 
type User

at com.sooperseekrit.app.DirectAction.loginAction(DirectAction.java:39)

The only place where WORequestHandler is called is in Application.java:

String directActionRequestHandlerKey = this.directActionRequestHandlerKey();
WORequestHandler directActionRequestHandler = 
this.requestHandlerForKey(directActionRequestHandlerKey);
this.setDefaultRequestHandler(directActionRequestHandler);

Funny thing, if I put an import statement in Session.java: "import 
com.sooperseekrit.model.User;" the errors disappear and the app runs fine. Why 
do I need to import the class from the eomodel?  BTW, the tutorial goes through 
a process of moving code around and basically implementing the same 
functionality in different ways. I think this error popped up when the login 
logic was moved into directAction to make the login sessionless. 

Thanks.


On Dec 1, 2011, at 12:02 PM, Chuck Hill wrote:

> 
> On 2011-12-01, at 11:06 AM, Kevin Spake wrote:
> 
>> 
>> On Dec 1, 2011, at 8:36 AM, Jérémy DE ROYER [INGENCYS] wrote:
>> 
>>> For me, these are the two worst bugs wolips :
>>> - erros that do not exist
>>> - validation that freeze wolips
>>> 
>>> For the first one, either I don't care or I restart and clean my project
>> Unfortunately, that did not work for me.  So far, eclipse has been a bit of 
>> a nightmare for me.
> 
> Yes, it has.
> 
> 
>> I can only assume it's not this bad for most users (or maybe I'm doing/not 
>> doing something to aggravate it.  
> 
> I use it daily and the aggravations are not a daily occurrence.  I tend to 
> leave it running and rarely restart it unless I restart my machine.  That may 
> help.
> 
> 
>> A new error popped up, and eclipse is complaining about my "User" object but 
>> the User class is in the right place, and was EOGenerated by eclipse, so 
>> we'll try to figure what's going on there tonight. 
> 
> Let us know the full error message.
> 
> 
> 
>> 
>> 
>>> 
>>> For the second one, either I disable validation or I kill wolips and 
>>> restart...
>>> 
>>> Jérémy
>>> 
>>> Le 1 déc. 2011 à 17:23, Ramsey Gurley a écrit :
>>> 
>>>> Or just select the error in your Problems view and right click to delete 
>>>> it.
>>>> 
>>>> Ramsey
>>>> 
>>>> On Dec 1, 2011, at 12:29 AM, Stefan Klein wrote:
>>>> 
>>>>> In some tough cases following steps will do it:
>>>>> 
>>>>> 1) close the project in eclipse
>>>>> 2) close eclipse
>>>>> 3) delete bin and build directories
>>>>> 4) open eclipse
>>>>> 5) open the project
>>>>> 6) run clean
>>>>> 
>>>>> Stefan
>>>>> 
>>>>> Am 01.12.11 07:35, schrieb Kevin Spake:
>>>>>> Thanks. I had tried Cleaning but it did not help.
>>>>>> 
>>>>>> 
>>>>>> On Nov 30, 2011, at 10:04 PM, Chuck Hill wrote:
>>>>>> 
>>>>>>> This is just Eclipse gone insane again.  You can open the Problems 
>>>>>>> View, select and delete these errors.  Sometimes Cleaning and Building 
>>>>>>> works too.
>>>>>>> 
>>>>>>> Chuck
>>>>>>> 
>>>>>>> 
>>>>>>> On 2011-11-30, at 9:17 PM, Kevin Spake wrote:
>>>>>>> 
>>>>>>>> I've been working on the introductory material that was suggested. 
>>>>>>>> Now, I'm on part 2 of the Webobjects, wolips and wonder tutorial. 
>>>>>>>> There is an error in Main.wo.  At<wo:PageWrapper>  the error is: "The 
>>>>>>>> class for 'PageWrapper' is either missing or does not extend 
>>>>>>>> WOElement."   The PageWrapper.wo is in components, PageWrapper. java 
>>>>>>>> is in com.sooperseekrit.components, so the class is not missing. 
>>>>>>>> According to the javadoc, 
>>>>>>>> er.extensions.components.ERXStatelessComponent (which is the super for 
>>>>>>>> PageWrapper) inherits from com.webobjects.appserver.WOElement.   
>>>>>>>> ERExtensions is in the build path.
>>>>>>>> 
>>>>>>>> What am I doing wrong?
>>>>>>>> 
>>>>>>>> This is Main.wo
>>>>>>>> <wo:PageWrapper>
>>>>>>>>        <wo:form>
>>>>>>>>        <fieldset>
>>>>>>>>        <legend>User Login</legend>
>>>>>>>>        <p><label>Username:</label>  <wo:textfield 
>>>>>>>> value="$username"/></p>
>>>>>>>>        <p><label>Password:</label>  <wo:password 
>>>>>>>> value="$password"/></p>
>>>>>>>>        <p class="button-bar"><wo:submit action="$loginAction" 
>>>>>>>> value="Login"/></p>
>>>>>>>>        <wo:if condition = "$errorMessage"><div class="error"><wo:str 
>>>>>>>> value="$errorMessage"/></div></wo:if>
>>>>>>>>        </fieldset>
>>>>>>>>        </wo:form>
>>>>>>>> </wo:PageWrapper>
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> 
>>>>>>>> _______________________________________________
>>>>>>>> Do not post admin requests to the list. They will be ignored.
>>>>>>>> Webobjects-dev mailing list      ([email protected])
>>>>>>>> Help/Unsubscribe/Update your Subscription:
>>>>>>>> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
>>>>>>>> 
>>>>>>>> This email sent to [email protected]
>>>>>>> -- 
>>>>>>> Chuck Hill             Senior Consultant / VP Development
>>>>>>> 
>>>>>>> Practical WebObjects - for developers who want to increase their 
>>>>>>> overall knowledge of WebObjects or who are trying to solve specific 
>>>>>>> problems.
>>>>>>> http://www.global-village.net/products/practical_webobjects
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>>> 
>>>>>> _______________________________________________
>>>>>> Do not post admin requests to the list. They will be ignored.
>>>>>> Webobjects-dev mailing list      ([email protected])
>>>>>> Help/Unsubscribe/Update your Subscription:
>>>>>> http://lists.apple.com/mailman/options/webobjects-dev/stefan.klein%40buero-sde.de
>>>>>> 
>>>>>> This email sent to [email protected]
>>>>>> 
>>>>> _______________________________________________
>>>>> Do not post admin requests to the list. They will be ignored.
>>>>> Webobjects-dev mailing list      ([email protected])
>>>>> Help/Unsubscribe/Update your Subscription:
>>>>> http://lists.apple.com/mailman/options/webobjects-dev/rgurley%40smarthealth.com
>>>>> 
>>>>> This email sent to [email protected]
>>>> 
>>>> _______________________________________________
>>>> Do not post admin requests to the list. They will be ignored.
>>>> Webobjects-dev mailing list      ([email protected])
>>>> Help/Unsubscribe/Update your Subscription:
>>>> http://lists.apple.com/mailman/options/webobjects-dev/jeremy.deroyer%40ingencys.net
>>>> 
>>>> This email sent to [email protected]
>>> 
>>> _______________________________________________
>>> Do not post admin requests to the list. They will be ignored.
>>> Webobjects-dev mailing list      ([email protected])
>>> Help/Unsubscribe/Update your Subscription:
>>> http://lists.apple.com/mailman/options/webobjects-dev/sparky005s%40yahoo.com
>>> 
>>> This email sent to [email protected]
>> 
>> _______________________________________________
>> Do not post admin requests to the list. They will be ignored.
>> Webobjects-dev mailing list      ([email protected])
>> Help/Unsubscribe/Update your Subscription:
>> http://lists.apple.com/mailman/options/webobjects-dev/chill%40global-village.net
>> 
>> This email sent to [email protected]
> 
> -- 
> Chuck Hill             Senior Consultant / VP Development
> 
> Practical WebObjects - for developers who want to increase their overall 
> knowledge of WebObjects or who are trying to solve specific problems.    
> http://www.global-village.net/products/practical_webobjects
> 
> 
> 
> 
> 
> 
> 

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to