[GemStone-Smalltalk] Bug?
David Shaffer
shaffer at shaffer-consulting.com
Sat Mar 20 14:04:50 PDT 2021
Here are some things I’ve tried:
1) Using the “base” VW class name but also setting the environment:
(#{GbsClassConnector} value
stName: ’ConflictingName'
gsName: #ConflictingName
dictionaryName: #GcbNSA) environment: GcbNSA
But then adding the second connector with the same stName removes the first (since GbsNameConnector>>= relies on #clientObjString which only references stName).
2) Using both the full class name and specifying the environment:
(#{GbsClassConnector} value
stName: ’GcbNSA.ConflictingName'
gsName: #ConflictingName
dictionaryName: #GcbNSA) environment: GcbNSA
This /kind-of/ works. That is, both connectors stay around as long as I disable connector verification but…when I store instances of the two VW classes in GS, commit, log out then back in, they appear to be instances of the same type. I think this is a bug in GbsSession>>fetchBehaviorDelegatesForClassConnectors: which seems to ignore the #dictionaryName attribute of the connectors.
I’m dead in the water. Hacking GbsSession>>fetchBehaviorDelegatesForClassConnectors: is next but I feel like that’s a bad path to go down since there is likely other broken code related to this problem.
-D
> On Mar 20, 2021, at 3:13 PM, David Shaffer <shaffer at SHAFFER-CONSULTING.COM> wrote:
>
> Hey folks,
>
> I’m a bit stuck on this one…I’m using VW9, GS3.5.4, Gbs8.5, in case it matters. For testing purposes I have two Dictionaries in my symbol list: #GcbNSA and #GcbNSB each with a class called ConflictingName. On the VW side I have the same setup but with Namespaces. I create two class connectors:
>
> #{GbsClassConnector} value
> stName: ’GcbNSA.ConflictingName'
> gsName: #ConflictingName
> dictionaryName: #GcbNSA
>
> #{GbsClassConnector} value
> stName: ’GcbNSB.ConflictingName'
> gsName: #ConflictingName
> dictionaryName: #GcbNSB
>
> But GemStone discards one of them with this error:
>
> GbsClassConnector stName: #'GcbNSA.ConflictingName' gsName: #ConflictingName
> - GbsClassConnector stName: #'GcbNSA.ConflictingName' gsName: #ConflictingName
> is overriding an existing connection.
> GbsClassConnector stName: 'ConflictingName' gsName: #ConflictingName - GbsClassConnector
> stName: 'ConflictingName' gsName: #ConflictingName is overriding an existing
> connection.
>
> I don’t understand this at all. While the “gsName” of the two connectors is the same, the dictionaryName is different so they shouldn’t conflict. Has anyone encountered this? Or have any suggestions?
>
> Basically this makes it impossible to map VW Namespaces to GS Dictionaries…which I was hoping to do as I make extensive use of “conflicting" class names in VW. I’m left with creating GS class names by mangling all of the VW class names to include namespace info. Not a path I hopped to go down...
>
> -D
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gemtalksystems.com/mailman/private/gemstone-smalltalk/attachments/20210320/b15f444d/attachment.htm>
More information about the GemStone-Smalltalk
mailing list