Closed Bug 195109 Opened 22 years ago Closed 22 years ago

XPInstall Pre-Checkin Trigger smoketest fails

Categories

(Core Graveyard :: Installer: XPInstall Engine, defect)

PowerPC
macOS
defect
Not set
critical

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: tracy, Assigned: ccarlen)

References

()

Details

(Whiteboard: [adt2] 1.3.1)

Attachments

(2 files)

seen on mac mozilla trunk build 2003-02-26-03-trunk -go to the test URL above -click on the link to run the Xpinstall test -click Install in the pop up dialog expected result: test pops a a confirm dialog with PASS tested results: the pop up says XPinstall test -202: Failed from the javascript console: Error: [Exception... "Component returned failure code: 0x80004005 (NS_ERROR_FAILURE) [nsIURI.hostPort]" nsresult: "0x80004005 (NS_ERROR_FAILURE)" location: "JS frame :: chrome://navigator/content/nsBrowserStatusHandler.js :: anonymous :: line 350" data: no] Source File: chrome://navigator/content/nsBrowserStatusHandler.js Line: 350
Sean and I are looking at this now.
Status: NEW → ASSIGNED
Summary: XPInstall Pre-Checkin Trigger smoketest fails → XPInstall Pre-Checkin Trigger smoketest fails
Works on a 2003-02-25-03-trunk Mac OS X build for us. Tracy reports now all builds as far back as 2003-02-10 are failing for him. Proceeding to his machine to investigate.
This only affects replace, not adding of files. While this is a severe regression we don't believe it should the tree should remain closed for this bug. Downgrading severity from smoketest blocker to critical.
Severity: blocker → critical
Keywords: smoketest
reduced to critical per samir
nominating
Keywords: nsbeta1
installer triage: nsbeta1+ adt2
Keywords: nsbeta1nsbeta1+
Whiteboard: [adt2]
I am no longer seeing this as of commercial trunk build 2003-03-05-07-trunk marking wfm
Status: ASSIGNED → RESOLVED
Closed: 22 years ago
Resolution: --- → WORKSFORME
for me too
Status: RESOLVED → VERIFIED
reopening bug because I'm still seeing it.
Status: VERIFIED → REOPENED
Resolution: WORKSFORME → ---
Here's the test that will cause xpinstall to either return ACCESS_DENIED (-202) or REBOOT_NEEDED (999). I'm not sure why it returns one vs. the other depending on which machine it is run on. I just know that it should not be returning either of these errors. You have to run the test at least twice (2x). The first time should run fine because there's no test file installed in the temp dir by the test. The 2nd time is when it fails under OSX. Windows runs fine: http://slip.mcom.com/projects/seamonkey/smoketests/pre_checkin_trigger.html The xpinstall code in question is: http://lxr.mozilla.org/seamonkey/source/xpinstall/src/ScheduledTasks.cpp#277 However, it is this function here that is the cause of the problem: http://lxr.mozilla.org/seamonkey/source/xpcom/io/nsLocalFileOSX.cpp#593 This is because OSX's implementation of MoveToNative() does not delete the file out of the way first before performing a raname. This is actually correct given the following declaration: http://lxr.mozilla.org/seamonkey/source/xpcom/io/nsIFile.idl#156 This will fix part of the problem to bug 195788 (see comment #4 in that bug). Not exactly sure who to give this bug to.
the bug is in conrad's code. if he can't fix it due to time, send it to me.
> the bug is in conrad's code. This bit: http://lxr.mozilla.org/seamonkey/source/xpcom/io/nsIFile.idl#156 was added after the implementation of nsLocalFileOSX's MoveToNative was written. The semantics of the iface changed but the implementation wasn't.
OK - maybe the semantics weren't changed, they just didn't specify that behavior. Now that they do, I'll change make the OSX impl match.
Assignee: ssu → ccarlen
Status: REOPENED → NEW
OK - now it behaves according to the (relatively new) API comment. I combined both the simple rename case with the general move/rename case in order to do the check for an existing file once.
Attachment #116970 - Flags: superreview?(sfraser)
Attachment #116970 - Flags: review?(sdagley)
2 things I noticed about ReplaceFileNow(): (1) After "result" is inited to nsInstall::ACCESS_DENIED, and everything in this function succeeds, it's never to set indicate success. (2) The comment here: http://lxr.mozilla.org/seamonkey/source/xpinstall/src/ScheduledTasks.cpp#281 has never been true for the nsLocalFileOSX impl. Now that the old impl is dead, maybe this code could be simplified?
Attachment #116970 - Flags: superreview?(sfraser) → superreview+
Attachment #116970 - Flags: review?(sdagley) → review+
On further testing, this patch doesn't not fix the problem for xpinstall. MoveToNative() did what it should, but a following call to Exists() returned TRUE when it should not. Looking at that now...
The problem is explained in the comment. The removed chunk of code was there only for the sake of the old Mac file impl. The new one doesn't have that problem - quite the opposite one :-/
Blocks: 197105
So if I understand this patch you've explicitly broken Classic Mac -- is it really and truly dead? I thought is was simply demoted to "ports" status. Could you add back the hack for classic inside #ifdef XP_MAC ?
Dan, the classic Mac builds are really and truly dead. They're no longer on the ports page.
Comment on attachment 117013 [details] [diff] [review] XP_MACOSX workaround patch for xpinstall in that case r/sr=dveditz
Attachment #117013 - Flags: superreview+
Attachment #117013 - Flags: review?(ssu)
Comment on attachment 117013 [details] [diff] [review] XP_MACOSX workaround patch for xpinstall r=ssu
Attachment #117013 - Flags: review?(ssu) → review+
Both patches checked in.
Status: NEW → RESOLVED
Closed: 22 years ago22 years ago
Resolution: --- → FIXED
Whiteboard: [adt2] → [adt2] 1.3.1
verified Mac build 2003032403
Status: RESOLVED → VERIFIED
both patches merged to 1.3 branch.
Product: Core → Core Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: