Fwd: problem with unicode 10262

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Fwd: problem with unicode 10262

Stéphane Ducasse



With a VM 40 and a VM 3.8.21 :(
Help!
I put the plgin ClipboardExtended....


DNU charCode

nextFromStream: aStream

| char resultChar |
char := super nextFromStream: aStream.
(CombinedChar isCompositionCharacter: char charCode)
ifFalse: [^char].
combinedChar
ifNil: [
combinedChar := CombinedChar new.
combinedChar simpleAdd: char]
ifNotNil: [
[combinedChar simpleAdd: char]
whileFalse: [char := super nextFromStream: aStream].
resultChar := combinedChar combined.
combinedChar := CombinedChar new.
combinedChar simpleAdd: char.
^resultChar]


From: zork
To: [hidden email]
Subject: [BUG]UndefinedObject(Object)>>doesNotUnderstand: #charCode

here insert explanation of what you were doing, suspect changes you've made and so forth.

31 March 2009 4:11:46 pm

VM: Mac OS - a SmalltalkImage
Image: Pharo0.1 [Latest update: #10262]

SecurityManager state:
Restricted: false
FileAccess: true
SocketAccess: true
Working Dir /Users/ducasse/Workspace/FirstCircle/ActiveResearch/Pharo/Pharo
Trusted Dir /foobar/tooBar/forSqueak/bogus
Untrusted Dir /Users/ducasse/Library/Preferences/Squeak/Internet/My Squeak

UndefinedObject(Object)>>doesNotUnderstand: #charCode
Receiver: nil
Arguments and temporary variables:
aMessage: charCode
exception: MessageNotUnderstood: UndefinedObject>>charCode
resumeValue: nil
Receiver's instance variables:
nil

UTF8DecomposedTextConverter>>nextFromStream:
Receiver: an UTF8DecomposedTextConverter
Arguments and temporary variables:
<<error during printing>
Receiver's instance variables:
combinedChar: nil

MultiByteBinaryOrTextStream>>next
Receiver: <<error during printing>>
Arguments and temporary variables:
n: nil
Receiver's instance variables:
collection: '~'
position: 1
readLimit: 1
writeLimit: 6
isBinary: true
converter: an UTF8DecomposedTextConverter

MultiByteBinaryOrTextStream>>upToEnd
Receiver: <<error during printing>>
Arguments and temporary variables:
newStream: a WriteStream #[126]
element: 126
newCollection: #[126 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 ...etc...
Receiver's instance variables:
collection: '~'
position: 1
readLimit: 1
writeLimit: 6
isBinary: true
converter: an UTF8DecomposedTextConverter


--- The full stack ---
UndefinedObject(Object)>>doesNotUnderstand: #charCode
UTF8DecomposedTextConverter>>nextFromStream:
MultiByteBinaryOrTextStream>>next
MultiByteBinaryOrTextStream>>upToEnd
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
MultiByteBinaryOrTextStream>>contents
[] in ByteString(String)>>encodeForHTTPWithTextEncoding:conditionBlock: {[:c | (conditionBlock value: c)   ifTrue: [httpSafeStream     nextPut: (Char...]}
ByteString(SequenceableCollection)>>do:
ByteString(String)>>encodeForHTTPWithTextEncoding:conditionBlock:
ByteString(String)>>encodeForHTTP
[] in HttpUrl(HierarchicalUrl)>>printOn: {[:pathElem |  aStream nextPut: $/.  aStream nextPutAll: pathElem encodeForHT...]}
OrderedCollection>>do:
HttpUrl(HierarchicalUrl)>>printOn:
[] in HttpUrl(Object)>>printStringLimitedTo: {[:s | self printOn: s]}
String class(SequenceableCollection class)>>streamContents:limitedTo:
HttpUrl(Object)>>printStringLimitedTo:
HttpUrl(Object)>>printString
HttpUrl(Object)>>asString
HttpUrl>>retrieveContentsArgs:accept:
HttpUrl>>retrieveContentsArgs:
HttpUrl>>retrieveContents
UStandardUniverse>>updatePackagesViaWWW
[] in UGlobalInstaller>>requestPackageList {[universe updatePackagesViaWWW]}
[] in PSUIManager(UIManager)>>informUser:during: {[:bar |  bar value: aString.  aBlock value]}
[] in PSUIManager>>informUserDuring: {[:bar | aBlock value: bar]}
[] in ProgressInitiationException>>defaultAction {[result := workBlock value: progress]}
BlockContext>>ensure:
ProgressInitiationException>>defaultAction
UndefinedObject>>handleSignal:
MethodContext(ContextPart)>>handleSignal:
MethodContext(ContextPart)>>handleSignal:
ProgressInitiationException(Exception)>>signal
ProgressInitiationException>>display:at:from:to:during:
ProgressInitiationException class>>display:at:from:to:during:
PSUIManager(MorphicUIManager)>>displayProgress:at:from:to:during:
PSUIManager>>informUserDuring:
PSUIManager(UIManager)>>informUser:during:
UGlobalInstaller>>requestPackageList
InstallerUniverse>>update
InstallerUniverse>>universe:
InstallerUniverse class>>universe:
InstallerUniverse class>>default
Installer class>>universe
MooseLoader class>>loadSmacc
MooseLoader class>>load
MooseLoader class>>DoIt
Compiler>>evaluate:in:to:notifying:ifFail:logged:
[] in TextMorphEditor(ParagraphEditor)>>evaluateSelection {[rcvr class evaluatorClass new   evaluate: self selectionAsStream   in: ctxt...]}
BlockContext>>on:do:
TextMorphEditor(ParagraphEditor)>>evaluateSelection
TextMorphEditor(ParagraphEditor)>>doIt
[] in TextMorphEditor(ParagraphEditor)>>doIt: {[self doIt]}
TextMorphEditor(ParagraphEditor)>>terminateAndInitializeAround:
TextMorphEditor(ParagraphEditor)>>doIt:
TextMorphEditor(ParagraphEditor)>>dispatchOnKeyEvent:with:
TextMorphEditor>>dispatchOnKeyEvent:with:
TextMorphEditor(ParagraphEditor)>>keystroke:
TextMorphEditor>>keystroke:
...etc...






_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: problem with unicode 10262

Michael Rueger-6
Stéphane Ducasse wrote:
>>

>> converter: an UTF8DecomposedTextConverter

Why is this set as the converter on the stream?

collection:  '~'
position: 1
readLimit: 1

is not a valid decomposed utf-8 sequence AFAIK.

But the converter should still be fixed to handle EOS correctly.

Michael

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: problem with unicode 10262

Michael Rueger-6
Michael Rueger wrote:
> Stéphane Ducasse wrote:
>
>>> converter: an UTF8DecomposedTextConverter
>
> Why is this set as the converter on the stream?

Ah, due to the concrete class detection by enumerating subclasses. There
really needs to be a better pattern, too much magic...

Michael

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: problem with unicode 10262

Michael Rueger-6
In reply to this post by Michael Rueger-6

fix attached

Michael

_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project

UTF8DecomposedTextConverter class-encodingNames.st.gz (282 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Fwd: problem with unicode 10262

Stéphane Ducasse
I'm running to catch my train and will have internet only late tomorrow.

Stef

On Mar 31, 2009, at 4:39 PM, Michael Rueger wrote:

>
> fix attached
>
> Michael
> <UTF8DecomposedTextConverter class-
> encodingNames.st.gz>_______________________________________________
> Pharo-project mailing list
> [hidden email]
> http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project


_______________________________________________
Pharo-project mailing list
[hidden email]
http://lists.gforge.inria.fr/cgi-bin/mailman/listinfo/pharo-project