Problems with Postmark in Pharo 2.0 with and without Seaside

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

Problems with Postmark in Pharo 2.0 with and without Seaside

Dave
Hi guys,

I'm going to crosspost to the seaside and pharo lists, so please forgive me

First:
I'm stuck in installing Postmark, I think is something wrong with seaside, because on a Pharo 2.0 clean image everything is fine

So the scenario is:

On Pharo 2.0 and clean image, cmd-p on:
Gofer new
        url: 'http://smalltalkhub.com/mc/PharoExtras/Postmark/main' ;
        package: 'ConfigurationOfPostMark';
        load.
(Smalltalk at: #ConfigurationOfPostMark) project stableVersion load.

returns:
a MetacelloFetchingMCSpecLoader(linear load :
        explicit load : 1.0 [ConfigurationOfPostMark]
                load : ConfigurationOfGrease-JohanBrichau.236
        explicit load : 1.0 [ConfigurationOfPostMark]
                load : ConfigurationOfJSON-PaulDeBruicker.3
        linear load : 1.0 [ConfigurationOfPostMark]
                linear load : 1.0.8 [ConfigurationOfGrease]
                        load : Grease-Core-pmm.72
                        load : Grease-Pharo20-Core-pmm.1
                linear load : 1.0 [ConfigurationOfJSON]
                        load : JSON-ul.35
                load : PostMark-Core-PaulDeBruicker.15)
               



               
On Pharo 2.0 and clean image, cmd-p on:
Gofer new
        url: 'http://smalltalkhub.com/mc/PharoExtras/Postmark/main' ;
        package: 'ConfigurationOfPostMark';
        load.
(Smalltalk at: #ConfigurationOfPostMark) project stableVersion load.

gives me:
- a DNU GRPackage(Object)>>doesNotUnderstand: #includesSelector:ofClassName:
- then an alert: "You are about to load new versions of the following packages that have unsaved changes in the images: Zinc-FileSystem"
I press merge
- then another alert: "You are about to load new versions of the following packages that have unsaved changes in the images: Zinc-HTTP"
I press merge

so finally the result of cmd-p is:

a MetacelloFetchingMCSpecLoader(linear load :
        explicit load : 1.0 [ConfigurationOfPostMark]
                load : ConfigurationOfGrease-JohanBrichau.236
        explicit load : 1.0 [ConfigurationOfPostMark]
                load : ConfigurationOfJSON-PaulDeBruicker.3
        explicit load : 1.0 [ConfigurationOfPostMark]
                load : ConfigurationOfSeaside3-JohanBrichau.71
        linear load : 1.0 [ConfigurationOfPostMark]
                explicit load : 1.0.8 [ConfigurationOfGrease]
                linear load : 1.0.8 [ConfigurationOfGrease]
                        load : Grease-Core-pmm.72
                        load : Grease-Pharo20-Core-pmm.1
                        load : Grease-Tests-Core-DamienCassou.81
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                        load : ConfigurationOfSPort2-JohanBrichau.12
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                explicit load : 3.0.9 [ConfigurationOfSeaside3]
                        load : ConfigurationOfZincHTTPComponents-SvenVanCaekenberghe.59
                linear load : 3.0.9 [ConfigurationOfSeaside3]
                        linear load : 1.0.8 [ConfigurationOfGrease]
                        linear load : 1.0.8 [ConfigurationOfGrease]
                        linear load : 2.4.6 [ConfigurationOfZincHTTPComponents]
                                load : Zinc-Character-Encoding-Core-SvenVanCaekenberghe.28
                                load : Zinc-Character-Encoding-Tests-SvenVanCaekenberghe.15
                                load : Zinc-Resource-Meta-Core-SvenVanCaekenberghe.28
                                load : Zinc-Resource-Meta-Tests-SvenVanCaekenberghe.16
                                load : Zinc-FileSystem-SvenVanCaekenberghe.10
                                load : Zinc-HTTP-SvenVanCaekenberghe.383
                                load : Zinc-Tests-SvenVanCaekenberghe.199
                        load : Seaside-Core-pmm.771
                        postload : Seaside-Core >> seaside304DoIts
                        load : Javascript-Core-pmm.94
                        load : Seaside-Tests-Core-pmm.258
                        load : Seaside-Tests-Canvas-pmm.59
                        load : Javascript-Tests-Core-pmm.68
                        linear load : 2.33 [ConfigurationOfSPort2]
                                load : FileSystem-Legacy-JohanBrichau.2
                        linear load : 1.0.8 [ConfigurationOfGrease]
                        linear load : 1.0.8 [ConfigurationOfGrease]
                linear load : 1.0 [ConfigurationOfJSON]
                        load : JSON-ul.35
                load : PostMark-Core-PaulDeBruicker.15)

Wow, so many more packages than the clean image!



               
Second:
That's not the end of the story, both in Pharo 2 clean image then the image with Seaside, if I evaulate:

email := PMEmail new
  from: 'me@me.com';
  to: 'you@you.com';
  subject: 'whatever';
  textBody: 'test';
  yourself.

interface := PMInterface new.
interface apiKey: 'my key'.
interface send: email.



I discover
1) textBody is no more a valid selector (so PMInterface comment is obsolete), I got rid of it and I tried again, but 2) I get an alert:
NameLookupFailure: cannot resolve 'api.postmark.com'

Gosh! Hints?
TIA
 Dave
Reply | Threaded
Open this post in threaded view
|

Re: Problems with Postmark in Pharo 2.0 with and without Seaside

Dave
Hi,
 I solved a couple of issues:
1) I didn't see PMEmail is a JsonObject. Now I understand why selector textBody: is not known by the system but it's valid.
2) The "NameLookupFailure: cannot resolve 'api.postmark.com'" is because  
PMInterface class>>
defaultApiUrl
        ^ 'http://api.postmark.com/'
       
instead of:

PMInterface class>>
defaultApiUrl
        ^ 'http://api.postmarkapp.com/'
       
** Can anyone who has access to the project change it? **

With that change it works
Dave