-
Notifications
You must be signed in to change notification settings - Fork 85
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
DNU when trying to unload an Iceberg pkg where underlying Pharo pkg has been removed #931
Comments
I think something is needed in this area as you do need to be able to unload now missing packages in order to commit a package deletion. I did a quick fix as follows which sorted things out for my usecase: IceWorkingCopy>>unloadPackage: aPackage
|
That's strange. I've checked it in Pharo 7 like this:
'NewPackage' asPackage removeFromSystem And Iceberg got automatically updated and marked it as "Not loaded".
I'll close it by now, feel free to reopen it if you have more info. |
This was on Pharo 6.1 with the latest Iceberg installed (from the script). I had a package Exercism-HelloWorld that was appearing top level instead of a sub package of Exercism. Renaming it, made it into a proper sub package, and then renaming it again got back the original name. But this left me with the phantom one I couldn’t delete. Not sure why you sometimes get those top-level glitches (I’ve seen it a few times). I will see if I can recreate in 7, or |
Can you give me the EXACT names you used?
I'm working on the hypothesis that Announcements changed between Pharo 6.1 and Pharo7, and thus Iceberg's code that listens to system events may be not 100% compatible with Pharo6.1? |
We might possibly have the exact sequence in the exercism/Pharo.git repo Master had: Exercism Sam checked in a branch with all top level packages Exercism I had to delete the master HelloWorld to then merge his branch. I then did the renaming to sort out the sub packaging issue and now I think about it, I moved some classes from a package called XercismDev to a new one called ExercismDev. I then removed in Pharo the now empty package XercismDev and then it was in the new Iceberg browser where I hit the issue about deleting the XertcismDev package as well as the HelloWorld one I recall. Anyway it was something like that and it does sound like some announcements failure. |
I've retried to follow your scenario but still, I cannot reproduce THAT issue.
See screenshot: I'm probably doing something differently than you. |
In the Working Copy Of window (which shows you packages you have loaded) if you remove a package in pharo becuase you've refactored - you can still see the package that you loaded.
If you you try to unload it - you get a DNU (its trying to #unload nil) Not sure if the Working Copy window should update when the package is removed, or if we should handle the nil?
UndefinedObject(Object)>>doesNotUnderstand: #unload
IceWorkingCopy>>unloadPackage:
IcePackage>>unload
[ self entity unload ] in [ Iceberg announcer
suspendAllForRepository: self entity repository
while: [ self entity unload ] ] in IceTipPackageModel>>unload in Block: [ self entity unload ]
BlockClosure>>ensure:
IceAnnouncer>>suspendAllMatching:while:
IceAnnouncer>>suspendAllForRepository:while:
[ Iceberg announcer
suspendAllForRepository: self entity repository
while: [ self entity unload ] ] in IceTipPackageModel>>unload in Block: [ Iceberg announcer...
[ :bar |
bar label: aString.
aBlock value ] in MorphicUIManager(UIManager)>>informUser:during: in Block: [ :bar | ...
[ :bar | aBlock value: bar ] in MorphicUIManager>>informUserDuring: in Block: [ :bar | aBlock value: bar ]
BlockClosure>>cull:
[ ^ block cull: self ] in [ self prepareForRunning.
CurrentJob value: self during: [ ^ block cull: self ] ] in Job>>run in Block: [ ^ block cull: self ]
[ activeProcess psValueAt: index put: anObject.
aBlock value ] in CurrentJob(DynamicVariable)>>value:during: in Block: [ activeProcess psValueAt: index put: anObject....
BlockClosure>>ensure:
CurrentJob(DynamicVariable)>>value:during:
CurrentJob class(DynamicVariable class)>>value:during:
[ self prepareForRunning.
CurrentJob value: self during: [ ^ block cull: self ] ] in Job>>run in Block: [ self prepareForRunning....
BlockClosure>>ensure:
Job>>run
MorphicUIManager(UIManager)>>displayProgress:from:to:during:
MorphicUIManager>>informUserDuring:
MorphicUIManager(UIManager)>>informUser:during:
IceTipStandardAction>>basicExecute
[ self basicExecute.
self finishSuccess ] in IceTipStandardAction(IceTipAction)>>execute in Block: [ self basicExecute....
BlockClosure>>on:do:
IceTipStandardAction(IceTipAction)>>withErrorHandlingDo:
IceTipStandardAction(IceTipAction)>>execute
IceTipStandardAction>>execute:
IceTipPackageModel>>unload
IceTipCachedModel>>forwardMessage:
The text was updated successfully, but these errors were encountered: