Re: [Pharo-users] Porting Transducers to Pharo

2017-06-06 Thread p...@highoctane.be
Hi Steffen,

I am willing to help you create the package in SmalltalkHub or Github based
on your files/changeset.

Do you have a github and/or SmalltalkHub account?

Best,
Phil


On Tue, Jun 6, 2017 at 1:08 PM, Steffen Märcker  wrote:

> Hi!
>
> If the need arises, we could of course factor the compact notation out into
>>> a separate package.
>>>
>> Good idea
>> [...] I do not want to help promoting a syntax that alienates me (and
>> others because other people reported the saem to me).
>>
>
> I understand. Btw, I'd really, really appreciate if others post their
> thoughts and feedback here as well. Discussion helps moving things forward.
> =)
>
>
>   (collection transduce map: #squared) take: 1000.
>>>
>>
>> To me this is much more readable.
>>
>
> Well, I'll provide that extension once it is finished.
>
> I cannot and do not want to use the other forms.
>>
>
>
>   collection transduce
>>>map: #squared;
>>>take: 1000.
>>>
>>> But as the message chain has to modify the underlying object
>>> (an eduction), very snaky side effects my occur. E.g., consider
>>>
>>>   eduction := collection transduce.
>>>   squared  := eduction map: #squared.
>>>   take := squared take: 1000.
>>>
>>> Now, all three variables hold onto the same object, which first squares
>>> all elements and than takes the first 1000.
>>>
>>
>> This is because the programmer did not understand what he did. No?
>>
>
> Sure. ;-) Nevertheless, it would be very hard to debug. All of which are
> the reasons I wouldn't implement that variant. ;-)
>
>
> PS: I played with infinite stream and iteration back in 1993 in CLOS.
>> Now I do not like to mix things because it breaks my flow of thinking.
>>
>
>
> I am not sure whether I understand what your mean by mixing. Concerning
> transducers, the ability to handle infinite sources in only a (natural)
> side-effect of the ability to finish reductions before all elements are
> processed, e.g., like #detect: and such.
>
> Best, Steffen
>
>
>
>
>
>


Re: [Pharo-users] Porting Transducers to Pharo

2017-06-06 Thread p...@highoctane.be
Check

https://medium.com/@i.oleks/interface-for-selecting-data-from-a-dataset-d7c6b5fb378f

https://medium.com/@i.oleks/an-example-of-test-driven-development-c9ce033f05ef

Loading a dataframe from a dataset and then using transducers for a
transformation pipeline would be great.

DataFrame is part of Polymath.

https://github.com/PolyMathOrg/PolyMath
http://www.smalltalkhub.com/#!/~PolyMath/PolyMath


Phil

On Tue, Jun 6, 2017 at 1:09 PM, Steffen Märcker  wrote:

> Hi Phil,
>
> Coupling this with Olek's work on the DataFrame could really come handy.
>>
>
> I am new to this list. Could you please elaborate?
>
> Cheers!
> Steffen
>
>
>
> On Mon, Jun 5, 2017 at 9:14 AM, Stephane Ducasse 
>> wrote:
>>
>> Hi Steffen
>>>
>>>
>>> > The short answer is that the compact notation turned out to work much
>>> better
>>> > for me in my code, especially, if multiple transducers are involved.
>>> But
>>> > that's my personal taste. You can choose which suits you better. In
>>> fact,
>>> >
>>> >   1000 take.
>>> >
>>> > just sits on top and simply calls
>>> >
>>> >   Take number: 1000.
>>>
>>> To me this is much much better.
>>>
>>>
>>> > If the need arises, we could of course factor the compact notation out
>>> into
>>> > a separate package.
>>> Good idea
>>>
>>>  Btw, would you prefer (Take n: 1000) over (Take number:
>>> > 1000)?
>>>
>>> I tend to prefer explicit selector :)
>>>
>>>
>>> > Damien, you're right, I experimented with additional styles. Right now,
>>> we
>>> > already have in the basic Transducer package:
>>> >
>>> >   (collection transduce: #squared map * 1000 take. "which is equal to"
>>> >   (collection transduce: #squared map) transduce: 1000 take.
>>> >
>>> > Basically, one can split #transduce:reduce:init: into single calls of
>>> > #transduce:, #reduce:, and #init:, depending on the needs.
>>> > I also have an (unfinished) extension, that allows to write:
>>> >
>>> >   (collection transduce map: #squared) take: 1000.
>>>
>>> To me this is much mre readable.
>>> I cannot and do not want to use the other forms.
>>>
>>>
>>> > This feels familiar, but becomes a bit hard to read if more than two
>>> steps
>>> > are needed.
>>> >
>>> >   collection transduce
>>> >map: #squared;
>>> >take: 1000.
>>>
>>> Why this is would hard to read. We do that all the time everywhere.
>>>
>>>
>>> > I think, this alternative would reads nicely. But as the message chain
>>> has
>>> > to modify the underlying object (an eduction), very snaky side effects
>>> may
>>> > occur. E.g., consider
>>> >
>>> >   eduction := collection transduce.
>>> >   squared  := eduction map: #squared.
>>> >   take := squared take: 1000.
>>> >
>>> > Now, all three variables hold onto the same object, which first squares
>>> all
>>> > elements and than takes the first 1000.
>>>
>>> This is because the programmer did not understand what he did. No?
>>>
>>>
>>>
>>> Stef
>>>
>>> PS: I played with infinite stream and iteration back in 1993 in CLOS.
>>> Now I do not like to mix things because it breaks my flow of thinking.
>>>
>>>
>>> >
>>> > Best,
>>> > Steffen
>>> >
>>> >
>>> >
>>> >
>>> >
>>> > Am .06.2017, 21:28 Uhr, schrieb Damien Pollet
>>> > :
>>> >
>>> >> If I recall correctly, there is an alternate protocol that looks more
>>> like
>>> >> xtreams or the traditional select/collect iterations.
>>> >>
>>> >> On 2 June 2017 at 21:12, Stephane Ducasse 
>>> wrote:
>>> >>
>>> >>> I have a design question
>>> >>>
>>> >>> why the library is implemented in functional style vs messages?
>>> >>> I do not see why this is needed. To my eyes the compact notation
>>> >>> goes against readibility of code and it feels ad-hoc in Smalltalk.
>>> >>>
>>> >>>
>>> >>> I really prefer
>>> >>>
>>> >>> square := Map function: #squared.
>>> >>> take := Take number: 1000.
>>> >>>
>>> >>> Because I know that I can read it and understand it.
>>> >>> From that perspective I prefer Xtreams.
>>> >>>
>>> >>> Stef
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>>
>>> >>> On Wed, May 31, 2017 at 2:23 PM, Steffen Märcker 
>>> wrote:
>>> >>>
>>>  Hi,
>>> 
>>>  I am the developer of the library 'Transducers' for VisualWorks. It
>>> was
>>>  formerly known as 'Reducers', but this name was a poor choice. I'd
>>> like
>>>  to
>>>  port it to Pharo, if there is any interest on your side. I hope to
>>> learn
>>>  more about Pharo in this process, since I am mainly a VW guy. And
>>> most
>>>  likely, I will come up with a bunch of questions. :-)
>>> 
>>>  Meanwhile, I'll cross-post the introduction from VWnc below. I'd be
>>> very
>>>  happy to hear your optinions, questions and I hope we can start a
>>>  fruitful
>>>  discussion - even if there is not Pharo port yet.
>>> 
>>>  Best, Steffen
>>> 
>>> 
>>> 
>>>  Transducers are building blocks that encapsulate how to process
>>> elements
>>>  of a data sequence independently of the underlying input and o

Re: [Pharo-users] Porting Transducers to Pharo

2017-06-07 Thread p...@highoctane.be
Use Iceberg with Pharo6.0

There are techtalks videos about it.

https://www.youtube.com/watch?v=AuZAFfWS34w&t=29s

Phil


On Wed, Jun 7, 2017 at 11:29 AM, Steffen Märcker  wrote:

> Hi Phil,
>
> that's great. I do have a GitHub account (merkste) but none at
> SmalltalkHub. Is there a recommendable doc on how to use Git from Pharo?
>
> Best, Steffen
>
>
>
> Am .06.2017, 14:09 Uhr, schrieb p...@highoctane.be :
>
> Hi Steffen,
>>
>> I am willing to help you create the package in SmalltalkHub or Github
>> based
>> on your files/changeset.
>>
>> Do you have a github and/or SmalltalkHub account?
>>
>> Best,
>> Phil
>>
>>
>> On Tue, Jun 6, 2017 at 1:08 PM, Steffen Märcker  wrote:
>>
>> Hi!
>>>
>>> If the need arises, we could of course factor the compact notation out
>>> into
>>>
>>>> a separate package.
>>>>>
>>>>> Good idea
>>>> [...] I do not want to help promoting a syntax that alienates me (and
>>>> others because other people reported the saem to me).
>>>>
>>>>
>>> I understand. Btw, I'd really, really appreciate if others post their
>>> thoughts and feedback here as well. Discussion helps moving things
>>> forward.
>>> =)
>>>
>>>
>>>   (collection transduce map: #squared) take: 1000.
>>>
>>>>
>>>>>
>>>> To me this is much more readable.
>>>>
>>>>
>>> Well, I'll provide that extension once it is finished.
>>>
>>> I cannot and do not want to use the other forms.
>>>
>>>>
>>>>
>>>
>>>   collection transduce
>>>
>>>>map: #squared;
>>>>>take: 1000.
>>>>>
>>>>> But as the message chain has to modify the underlying object
>>>>> (an eduction), very snaky side effects my occur. E.g., consider
>>>>>
>>>>>   eduction := collection transduce.
>>>>>   squared  := eduction map: #squared.
>>>>>   take := squared take: 1000.
>>>>>
>>>>> Now, all three variables hold onto the same object, which first squares
>>>>> all elements and than takes the first 1000.
>>>>>
>>>>>
>>>> This is because the programmer did not understand what he did. No?
>>>>
>>>>
>>> Sure. ;-) Nevertheless, it would be very hard to debug. All of which are
>>> the reasons I wouldn't implement that variant. ;-)
>>>
>>>
>>> PS: I played with infinite stream and iteration back in 1993 in CLOS.
>>>
>>>> Now I do not like to mix things because it breaks my flow of thinking.
>>>>
>>>>
>>>
>>> I am not sure whether I understand what your mean by mixing. Concerning
>>> transducers, the ability to handle infinite sources in only a (natural)
>>> side-effect of the ability to finish reductions before all elements are
>>> processed, e.g., like #detect: and such.
>>>
>>> Best, Steffen
>>>
>>>
>>>
>>>
>>>
>>>
>
>


Re: [Pharo-users] Wiring objects, IoC and Service Locator

2017-06-08 Thread p...@highoctane.be
Also realize the Smalltalk image is a container...

No need for fancy XML externalization because you can do that with code.

I have an app where I wire all kinds of things together in a configuration
file which is Smalltalk code and I just compile a method like
"wireEverything" that as source has that configuration file. Or just do a
Compiler evaluate: aLongConfigurationStringInSmalltalk

Any Dictionary can be a "SpringContext" thing.

Now decorators with specific features like transaction support etc is not
something we have and things like Spring do have.

We could take inspiration from Spring Boot.

https://projects.spring.io/spring-boot/

Best Regards,
Phil







On Thu, Jun 8, 2017 at 1:46 PM, Vitor Medina Cruz 
wrote:

> Thanks for the links Attila, do you have an alternative one to the
> http://higherorderlogic.com/2011/07/is-dependency-injection-like-facebook?
> It seems to be broken.
>
> I also started to also think containers don't worth the effort, but I am
> still concerned with problems faced with hand wiring everything as Peter
> clearly exemplified, thanks for the excellent summary and exemplification
> Peter!
>
> And this is just a basic example. Imagine that the PeopleService also
>> needs other services for it's use, and those services need more services,
>> and you want to keep everything separated as much as possible...
>> instantiation by hand will simply not cut it
>
>
> This is exactly my concern! Sure, for small stuff that is not a problem,
> but what if you have a big app? Now, my experience with containers and Java
> may be shadowing my vision: people in Java community tend to use anemic
> model and to create gazzilions layers for even simple stuff, which make the
> wiring problem even worse. My experiments with a more OO approach and
> Smalltalk tells me one would need much less need of containers by using
> proper OO and a less verbose language, but I am not sure.
>
> Keep in mind however that relates primarily to using application
>> frameworks, where the framework mandates the control, and the framework is
>> the one calling you, and therefore it will also provide you with necessary
>> parts. After all you are not even creating PeopleService class, the
>> framework instantiates it for you and gives it to another services/classes
>> that needed it.
>
>
> This is true for IoC DI containers, but I don't think it applies for
> service locator, which, I think, could not be considered a framework
> approach. Actually, I think being a framework is the big problem of the of
> the former, since when I start to use an IoC container to create objects I
> got tied to it in a very basic and pervasive operation of an OO system:
> object creation. Suddenly everything must be created through the DI
> container, but that is not true for Service Locator.
>
> However I wouldn't be surprised if the liveness of Smalltalk/Pharo
>> environment eliminated some of the problems that DI is trying to solve.
>
>
> That is precisely what I wanted to know. It seems there are no DI
> counterpart in the Pharo/Smalltalk environment, ok, so what people do to to
> deal with the above mentioned problem? Hand wiring is suffice? Is there
> anything in the liveness of Smalltalk/Pharo that eliminates the need for
> it? People use simple Service Locator, or variations of it?
>
>
> cheers!
> Vitor
>
> On Wed, Jun 7, 2017 at 9:32 PM, Ben Coman  wrote:
>
>>
>>
>> On Tue, Jun 6, 2017 at 11:48 PM, Attila Magyar 
>> wrote:
>>
>>> I don't think using a DI container worth the effort. They add lots of
>>> complexities and solve very little. For some reason DI containers became
>>> very popular in the Java world, but if you take a look at other
>>> programming
>>> communities you'll realize that many people are perfectly happy without
>>> using these containers. Using DI and using a DI container is orthogonal.
>>> As
>>> you also said you can just pass dependencies to objects to achieve loose
>>> coupling. Yes, you have to do this manually but what's the big deal?
>>> We're
>>> talking about code with cyclomatic complexity of 1. Calling a
>>> constructor is
>>> not a problem that need to be solved. Using an external XML
>>> configuration to
>>> describe object wiring is the worst idea ever.
>>>
>>> Here is an article about using plain old object composition to do DI
>>>
>>> http://blog.davidpeterson.co.uk/2011/01/object-oriented-example.html
>>>
>>> Some more thoughts about the problems associated with DI containers:
>>>
>>> http://www.natpryce.com/articles/000783.html
>>
>>
>> I liked this...  "the [Dependency Injection] pattern also used to be
>> called "third-party binding" or "third-party connect": some third party is
>> responsible for connecting an object satisfying the service requirements of
>> a component"
>> This makes the subject seem less esoteric.  It reminds me of hearing that
>> the first (secret) task when doing a PhD is to invent new terms for common
>> ones, and base your writings on that. Perhaps its the sa

Re: [Pharo-users] Help in thinking about how to save a "program"

2017-06-11 Thread p...@highoctane.be
If you have a playground script maybe just having it as a .st file and
running it with Pharo is good enough.


Like
pharo Pharo60.image myscript.st

Check
https://github.com/guillep/Scale

Or get into Iceberg (Git) or Monticello to save your code as a package.

Check deep into pharo, there is a chapter on these things.

Gofer may also be a solution.

Are you on Discord?

Phil

Le 12 juin 2017 01:22, "Glenn Hoetker"  a écrit :

> Hi all.  I’m new to Pharo and loving it.  As I transition from a text-file
> based mindset, I’m a little stuck and would appreciate help in how to think
> about a situation in a Pharonic (Pharo-ish, Pharoc?) way.
>
> I”m crafting a short program to help me process a large text file
> (specifically: extract, sorting, and regularizing the “keyword” fields of a
> large BibTex file). Especially since I don’t really know what I’m doing,
> working in a Playground has been a great development environment.  Now that
> the program is complete (under 30 lines, wonderful), I want to be able to
> save it for future reference (and perhaps for future use).  If I’d written
> a shell script, I’d just save “fixBibDeskKeyWords.sh” to a directory. I’m
> not sure what to do in the Pharo environment, thought.
>
> At the moment, it just lives in the Playground I’ve developed it on.  I
> could save the image and leave that Playground open, but I’m just positive
> that’s not a best practice. I also worry about what happens if I
> closed/cleared that Playground by accident.
>
> I think I understand that, if I created a new package, I could use
> Monticello to save it to a local cache and load it into a new image
> whenever I needed it.  But, given that it’s short, highly specialized and
> fairly linear, the idea of creating a “GHBibDeskStuff” package with one
> class (“GBibDeskKeywordFixer” containing a single “FixFile” method seems
> really heavy and awkward.
>
> Can one save the contents of a Playground in a Pharonic way?  Is there a
> better approach?
>
> Thank you to all involved in this wonderful programming ecosystem. I
> appreciate any advice.
>
> Glenn
>
> Glenn Hoetker
> ghoet...@me.com
> http://hoetker.faculty.asu.edu
>
>
>
>


Re: [Pharo-users] A question of style - pass a context or embed one?

2017-06-12 Thread p...@highoctane.be
A dynamic variable could work too.

But domain objects are somewhat hard to do in my view because we are
dealing with an API that has tons of options and customizability in its
results + people can define their own types and fields.

That's why I went for a JiraBuilder thing that has a reference to a Jira
instance.
That builder is allowing one to make higher level queries for the users
(like doing Epics, Stories, links, custom fields resolution, meta data
grabbing, prototype creation etc).

I didn't want to have an Epic class, a Story class, etc. Because my idea of
an Epic may not be your idea, so we may end up with a PluggableEpic etc and
it will never end.

My take is that it is better to use the vocabulary of the domain in the
method names but still work with dynamic structures like dictionaries and
some helpers.

I am still curious to see those domain objects because I understand that
they would ease inspection etc.

Maybe we should have a generator for these so that we can regenerate the
classes based on the metadata provided by Jira.

Phil

On Mon, Jun 12, 2017 at 9:28 PM, Esteban A. Maringolo 
wrote:

> Hello Tim,
>
> 2017-06-12 16:15 GMT-03:00 Tim Mackinnon :
> > Hi - I’m after some ideas or maybe previous examples that might guide me
> in the best approach of wrapping a low level library (essentially the Jira
> connector that Phil demo’d at Pharo days this year).
> >
> > There are some low level commands that will fetch json arrays for you
> given a “lira” instance- e.g:
> >
> > board := JiraBoard fromJira: jira named: ‘Project'.
> > sprints := board sprintsFrom: jira.
> >
> > My question is related to building on top of this - and its a style
> question.
> >
> > I want model objects that wrap the json arrays and let me navigate
> things a bit more simply, and query details more naturally - however I
> can’t decide whether my model objects should “contain” a jira when you
> instantiate them - which can be re-used for subsequent queries - OR -
> whether I should view jira as a from of context, and keep passing it to
> methods when I need to retrieve more details, or child objects?
> >
> > e.g.
> > myBoard := ModelBoard fromJira: jira named: ‘Project’.
> > mySprints := myBoard sprints. “No need to pass the jira again”.
> >
> > vs.
> >
> > mySprints :- myBoard sprintsIn: jira.
> >
> >
> > I’m wondering if anything might guide me one way or the other? Is one
> more tasteful/elegant than the other?
>
>
> I'd go for the first option. It is, every JIRA object knows the "jira"
> it belongs to.
>
> Although the second option is better for decoupling, not having to
> pass objects around to obtain properties allows you to better
> integrate with the tools (think GTInspector with specific inspector
> for cards).
>
> I don't understand what the "jira" is exactly, if a whole JSON object
> (a Dictionary) containing everything, a connection to JIRA API, or
> just the JSON object/Dictionary branch containing the attributes
> specific of the "wraping" object (the board, in this case).
>
> Regards!
>
> Esteban A. Maringolo
>
>
>


Re: [Pharo-users] Pharo 6 snap package

2017-06-13 Thread p...@highoctane.be
I need to upgrade to 16.04 now :-)

Phil

On Tue, Jun 13, 2017 at 11:04 AM, Stephane Ducasse 
wrote:

> THANKS A LOT ALISTAIR.
> I mean it :)
>
> On Tue, Jun 13, 2017 at 10:58 AM, Alistair Grant 
> wrote:
> > Hi Everyone,
> >
> > I've updated the Pharo 6 snap package for Ubuntu.
> >
> > The major advantages of using the snap package are:
> >
> > - No need to install all the 32 bit dependencies on a 64 bit system,
> >   they're all contained and isolated within the snap package.
> > - Automagically distinguish between 32 bit and 64 bit images and run the
> >   appropriate VM (as with the ZeroConf package, the 64 bit VM still
> >   needs more testing).
> >
> >
> >
> > To get Pharo up and running on Ubuntu 16.04 or later:
> >
> > # Install Pharo
> > $ sudo snap install --candidate pharo --classic
> > # If your system isn't configured for threaded heartbeat:
> > $ sudo pharo.config
> > # Download the latest Pharo 6 image
> > $ pharo.getimage
> > # Go...
> > $ pharo.ui Pharo.image
> > # or:
> > $ pharo Pharo.image eval 4+3
> >
> > To get a list of available commands:
> >
> > $ snap info pharo
> >
> >
> > If you're on Debian or Ubuntu 14.04 you'll need to install snapd, see
> > https://snapcraft.io/docs/core/install
> >
> >
> > The VM is the threaded heartbeat, dated 201705310241.
> >
> > The installation flags are:
> >
> > --candidate - The edge and beta channels are for development versions.
> >   It progresses to candidate and then stable.
> > --classic - Snap packages are normally sandboxed for security
> >   reasons.  Since Pharo is a development environment
> >   in which we want to be able to run any executable,
> >   or load any library, it is installed with access to
> >   the entire system (as the running user).
> >
> > Why use snap packages?
> >
> > - They include all dependencies.  In particular, for the 32 bit
> >   versions, this means that it isn't necessary to install all the 32 bit
> >   architecture and associated dependencies.
> > - Including dependencies means that there shouldn't be any problems with
> >   incompatible library versions when upgrading.
> >
> > Why not use snap packages?
> >
> > - It's a relatively new technology, with a number of rough edges.
> > - There may still be issues with its sandboxing that I haven't
> >   discovered yet.
> > - Because the package uses classic confinement, it isn't
> >   cross-distribution in practice (unfortunately).
> >
> > Please let me know of any other advantages or disadvantages you think
> > should be listed here.
> >
> > If you don't trust me to configure your system correctly (which requires
> > sudo):
> >
> > - All the scripts that make up the sub-commands are visible, e.g.
> > pharo.config can be viewed at /snap/pharo/current/usr/bin/CONFIG
> >
> >
> > The packaging code is at: https://github.com/akgrant43/pharo-snap
> >
> >
> > Cheers,
> > Alistair
> >
>
>
>


Re: [Pharo-users] Pharo 6 snap package

2017-06-13 Thread p...@highoctane.be
On Tue, Jun 13, 2017 at 11:34 AM, Alistair Grant 
wrote:

> On Tue, Jun 13, 2017 at 11:25:15AM +0200, p...@highoctane.be wrote:
> > I need to upgrade to 16.04 now :-)
>
> :-)
>
> Don't forget you can install snapd on Ubuntu 14.04:
>
> https://snapcraft.io/docs/core/install-ubuntu
>
>
Ah, wasn't aware of that. Thx Alistair!

Phil


> Cheers,
> Alistair
>
>
> > Phil
> >
> > On Tue, Jun 13, 2017 at 11:04 AM, Stephane Ducasse <
> stepharo.s...@gmail.com>
> > wrote:
> >
> > THANKS A LOT ALISTAIR.
> > I mean it :)
> >
> > On Tue, Jun 13, 2017 at 10:58 AM, Alistair Grant <
> akgrant0...@gmail.com>
> > wrote:
> > > Hi Everyone,
> > >
> > > I've updated the Pharo 6 snap package for Ubuntu.
> > >
> > > The major advantages of using the snap package are:
> > >
> > > - No need to install all the 32 bit dependencies on a 64 bit
> system,
> > >   they're all contained and isolated within the snap package.
> > > - Automagically distinguish between 32 bit and 64 bit images and
> run the
> > >   appropriate VM (as with the ZeroConf package, the 64 bit VM still
> > >   needs more testing).
> > >
> > >
> > >
> > > To get Pharo up and running on Ubuntu 16.04 or later:
> > >
> > > # Install Pharo
> > > $ sudo snap install --candidate pharo --classic
> > > # If your system isn't configured for threaded heartbeat:
> > > $ sudo pharo.config
> > > # Download the latest Pharo 6 image
> > > $ pharo.getimage
> > > # Go...
> > > $ pharo.ui Pharo.image
> > > # or:
> > > $ pharo Pharo.image eval 4+3
> > >
> > > To get a list of available commands:
> > >
> > > $ snap info pharo
> > >
> > >
> > > If you're on Debian or Ubuntu 14.04 you'll need to install snapd,
> see
> > > https://snapcraft.io/docs/core/install
> > >
> > >
> > > The VM is the threaded heartbeat, dated 201705310241.
> > >
> > > The installation flags are:
> > >
> > > --candidate - The edge and beta channels are for development
> versions.
> > >   It progresses to candidate and then stable.
> > > --classic - Snap packages are normally sandboxed for security
> > >   reasons.  Since Pharo is a development environment
> > >   in which we want to be able to run any executable,
> > >   or load any library, it is installed with access to
> > >   the entire system (as the running user).
> > >
> > > Why use snap packages?
> > >
> > > - They include all dependencies.  In particular, for the 32 bit
> > >   versions, this means that it isn't necessary to install all the
> 32 bit
> > >   architecture and associated dependencies.
> > > - Including dependencies means that there shouldn't be any
> problems with
> > >   incompatible library versions when upgrading.
> > >
> > > Why not use snap packages?
> > >
> > > - It's a relatively new technology, with a number of rough edges.
> > > - There may still be issues with its sandboxing that I haven't
> > >   discovered yet.
> > > - Because the package uses classic confinement, it isn't
> > >   cross-distribution in practice (unfortunately).
> > >
> > > Please let me know of any other advantages or disadvantages you
> think
> > > should be listed here.
> > >
> > > If you don't trust me to configure your system correctly (which
> requires
> > > sudo):
> > >
> > > - All the scripts that make up the sub-commands are visible, e.g.
> > > pharo.config can be viewed at /snap/pharo/current/usr/bin/CONFIG
> > >
> > >
> > > The packaging code is at: https://github.com/akgrant43/pharo-snap
> > >
> > >
> > > Cheers,
> > > Alistair
>
>
>


Re: [Pharo-users] How to use frameworks like SDL2, GTK+ with Pharo?

2017-06-13 Thread p...@highoctane.be
SDL2 is built in.

GTK+ is another story.

Phil

On Tue, Jun 13, 2017 at 6:38 PM, Daniel Passaro 
wrote:

> I'm a Pharo newbie. How can I use libraries like SDL2 or GTK+ from Pharo?
> Should this be done through FFI or a VM plugin?  And in either case is
> there a guide to how to implement things using that technique?
>


Re: [Pharo-users] How to use frameworks like SDL2, GTK+ with Pharo?

2017-06-13 Thread p...@highoctane.be
Image environment is not running on SDL2. SDL2 is a binding that is in
image.

An SFML binding is cool to do, especially CSFML.

https://www.sfml-dev.org/download/csfml/

I want to do these in Bloc
https://www.youtube.com/playlist?list=PLB_ibvUSN7mzUffhiay5g5GUHyJRO4DYr

But CSFML is cool to do too.

And I also want a binding to https://github.com/cmatsuoka/libxmp


Phil

On Tue, Jun 13, 2017 at 6:55 PM, Daniel Passaro 
wrote:

> Even if the image environment runs on SDL2, I want an SDL2 window I have
> free reign to draw on. I don't want to destroy the usability of the Pharo
> workspace when programming an application. If that is still too
> contentious, then I want SFML instead.
>
> The story of GTK+ is what I'm interested in.
>
> On Tue, Jun 13, 2017 at 12:48 PM, p...@highoctane.be 
> wrote:
>
>> SDL2 is built in.
>>
>> GTK+ is another story.
>>
>> Phil
>>
>> On Tue, Jun 13, 2017 at 6:38 PM, Daniel Passaro 
>> wrote:
>>
>>> I'm a Pharo newbie. How can I use libraries like SDL2 or GTK+ from
>>> Pharo? Should this be done through FFI or a VM plugin?  And in either case
>>> is there a guide to how to implement things using that technique?
>>>
>>
>>
>


Re: [Pharo-users] UUIDGenerator

2017-06-18 Thread p...@highoctane.be
Spotting for hex is hardly complex.

Shift-Enter hex #im

--> implementors of hex, first one I see is in ByteArray.

Shit-Enter hex #se

--> senders of hex. First one is a test in ByteArray

testHex
"self debug: #testHex"
self assert: #[122 43 213 7] hex = '7a2bd507'.
self assert: #[151 193 242 221 249 32 153 72 179 41 49 154 48 193 99 134]
hex = '97c1f2ddf9209948b329319a30c16386'.
self assert: (ByteArray readHexFrom: '7A2BD507') = #[122 43 213 7].
self assert: (ByteArray readHexFrom: '7a2bd507') = #[122 43 213 7].

>From this test, one can spot readHexFrom: which uses lowercase or uppercase
for reading.

And asUppercase, Shift-Enter upper, scrolll down as bit, find
String>>#asUppercase

Spotter is really great at finding stuff, and coupled with tests and
examples it helps in building understanding.

Agreed, this is not the same as looking for stuff as in, say, Java or
Python. I find it better in the long run still.

Phil

On Sat, Jun 17, 2017 at 9:23 PM, horrido  wrote:

> Message 'next' is not understood.
>
> But yes,
>
> UUID new hex asUppercase
>
> works fine.
>
> This is what happens when there is inadequate documentation: you end up
> doing things the *hard* way.
>
> Thanks.
>
>
>
> Sven Van Caekenberghe-2 wrote
> > Why not just
> >
> >   UUIDGenerator default next hex asUppercase.
> >
> > Or even
> >
> >   UUID new hex asUppercase.
> >
> > ?
> >
> > Since you are using #generateBytes:forVersion: (which is an internal
> > method BTW), you must be working in an older Pharo image (older than 6).
> > We replaced the UUIDGenerator class, the class comment in from the newer
> > version.
> >
> >> On 17 Jun 2017, at 16:27, horrido <
>
> > horrido.hobbies@
>
> > > wrote:
> >>
> >> Okay, I figured it out. Here's my method:
> >>
> >> generateUUID
> >>| aStream hex s x |
> >>hex := '0123456789ABCDEF'.
> >>x := ByteArray new: 16.
> >>UUIDGenerator default generateBytes: x forVersion: 4.
> >>s := String new: 32.
> >>aStream := WriteStream on: s.
> >>x do: [ :each | aStream nextPut: (hex at: each // 16 + 1).
> >>aStream nextPut: (hex at: each \\ 16 + 1) ].
> >>^ s
> >>
> >> Works like a charm. It would've been nice if a similar example was
> >> available
> >> /somewhere/ on the web.
> >>
> >>
> >>
> >> --
> >> View this message in context:
> >> http://forum.world.st/UUIDGenerator-tp4951725p4951731.html
> >> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
> >>
>
>
>
>
>
> --
> View this message in context: http://forum.world.st/UUIDGenerator-
> tp4951725p4951743.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>


Re: [Pharo-users] Bloated image again. Memory leak?

2017-06-19 Thread p...@highoctane.be
Check

https://gist.github.com/philippeback/39c63bb5aa26b79098511cdfea4fea7e

Phil

On Mon, Jun 19, 2017 at 8:45 AM, Davide Varvello via Pharo-users <
pharo-users@lists.pharo.org> wrote:

>
>
> -- Forwarded message --
> From: Davide Varvello 
> To: pharo-users@lists.pharo.org
> Cc:
> Bcc:
> Date: Sun, 18 Jun 2017 23:45:32 -0700 (PDT)
> Subject: Bloated image again. Memory leak?
> Hi guys,
> I have this problem (http://forum.world.st/Huge-image-td4876854.html), now
> the image grow about 100MB per week and the suggestions shown on
> http://forum.world.st/Huge-image-td4876854.html don't work
>
> I'm on Pharo 5 on a mac.
>
> I suspect it is something related to GLMPanePort, see the attached jpg
> Can you help me please?
>
> TIA
> Davide
>
>
> 
>
>
>
> --
> View this message in context: http://forum.world.st/Bloated-
> image-again-Memory-leak-tp4951861.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>
>


Re: [Pharo-users] UUIDGenerator

2017-06-19 Thread p...@highoctane.be
That being said, maybe one can do a spotter extension that looks into the
help topics.

I did one with windows (should be in Pharo7).

So one would ho to spotter and put a word followed by #help or #he

Maybe this is in already!
Phil

On Mon, Jun 19, 2017 at 10:43 AM, Tim Mackinnon  wrote:

> It is in the Pharo help - however I have noticed that Help doesn’t have a
> convenient search box and the new Welcome screen that launches with Pharo
> possibly should have a shortcut to useful navigational features…. Sounds
> like something I can contributed.
>
> Tim
>
> On 19 Jun 2017, at 00:39, horrido  wrote:
>
> I didn't know about the Spotter. That is so frickin' cool!!!
>
> Thanks.
>
>
> philippeback wrote
>
> Spotting for hex is hardly complex.
>
> Shift-Enter hex #im
>
> --> implementors of hex, first one I see is in ByteArray.
>
> Shit-Enter hex #se
>
> --> senders of hex. First one is a test in ByteArray
>
> testHex
> "self debug: #testHex"
> self assert: #[122 43 213 7] hex = '7a2bd507'.
> self assert: #[151 193 242 221 249 32 153 72 179 41 49 154 48 193 99 134]
> hex = '97c1f2ddf9209948b329319a30c16386'.
> self assert: (ByteArray readHexFrom: '7A2BD507') = #[122 43 213 7].
> self assert: (ByteArray readHexFrom: '7a2bd507') = #[122 43 213 7].
>
> From this test, one can spot readHexFrom: which uses lowercase or
> uppercase
> for reading.
>
> And asUppercase, Shift-Enter upper, scrolll down as bit, find
> String>>#asUppercase
>
> Spotter is really great at finding stuff, and coupled with tests and
> examples it helps in building understanding.
>
> Agreed, this is not the same as looking for stuff as in, say, Java or
> Python. I find it better in the long run still.
>
> Phil
>
> On Sat, Jun 17, 2017 at 9:23 PM, horrido <
>
>
> horrido.hobbies@
>
>
> > wrote:
>
> Message 'next' is not understood.
>
> But yes,
>
> UUID new hex asUppercase
>
> works fine.
>
> This is what happens when there is inadequate documentation: you end up
> doing things the *hard* way.
>
> Thanks.
>
>
>
> Sven Van Caekenberghe-2 wrote
>
> Why not just
>
>  UUIDGenerator default next hex asUppercase.
>
> Or even
>
>  UUID new hex asUppercase.
>
> ?
>
> Since you are using #generateBytes:forVersion: (which is an internal
> method BTW), you must be working in an older Pharo image (older than
>
> 6).
>
> We replaced the UUIDGenerator class, the class comment in from the
>
> newer
>
> version.
>
> On 17 Jun 2017, at 16:27, horrido <
>
>
> horrido.hobbies@
>
>
> > wrote:
>
>
> Okay, I figured it out. Here's my method:
>
> generateUUID
>   | aStream hex s x |
>   hex := '0123456789ABCDEF'.
>   x := ByteArray new: 16.
>   UUIDGenerator default generateBytes: x forVersion: 4.
>   s := String new: 32.
>   aStream := WriteStream on: s.
>   x do: [ :each | aStream nextPut: (hex at: each // 16 + 1).
>   aStream nextPut: (hex at: each \\ 16 + 1) ].
>   ^ s
>
> Works like a charm. It would've been nice if a similar example was
> available
> /somewhere/ on the web.
>
>
>
> --
> View this message in context:
> http://forum.world.st/UUIDGenerator-tp4951725p4951731.html
> Sent from the Pharo Smalltalk Users mailing list archive at
>
> Nabble.com.
>
>
>
>
>
>
>
> --
> View this message in context: http://forum.world.st/UUIDGenerator-
> tp4951725p4951743.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>
>
>
>
>
>
> --
> View this message in context: http://forum.world.st/UUIDGenerator-
> tp4951725p4951844.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com
> .
>
>
>


Re: [Pharo-users] Bloated image again. Memory leak?

2017-06-19 Thread p...@highoctane.be
On Mon, Jun 19, 2017 at 11:52 AM, Davide Varvello via Pharo-users <
pharo-users@lists.pharo.org> wrote:

>
>
> -- Forwarded message --
> From: Davide Varvello 
> To: pharo-users@lists.pharo.org
> Cc:
> Bcc:
> Date: Mon, 19 Jun 2017 02:52:08 -0700 (PDT)
> Subject: Re: Bloated image again. Memory leak?
> Thank you very much Phil,
> Your code works! The image went from 600MB to 80MB
>

I suffered from such a thing for a long time, and thanks to Clément and
Pavel, we are not having to suffer that bloat anymore :-)

This article is worth a read for making things fast(er) in some cases (if
you got to 600MB then you were inspecting decently sized collections):
https://clementbera.wordpress.com/2017/03/12/tuning-the-pharo-garbage-collector/

Phil




> I'm wondering why there is no bug record about GLMPanePort on
> https://pharo.fogbugz.com/f/search/?sSearchFor=GLMPanePort nor a fix.
> Nobody
> has this issue, but you and me? I'm puzzled.
>
> Anyway
> Thank you very much
> Davide
>
>
> philippeback wrote
> > Check
> >
> > https://gist.github.com/philippeback/39c63bb5aa26b79098511cdfea4fea7e
> >
> > Phil
> >
> > On Mon, Jun 19, 2017 at 8:45 AM, Davide Varvello via Pharo-users <
>
> > pharo-users@.pharo
>
> >> wrote:
> >
> >>
> >>
> >> -- Forwarded message --
> >> From: Davide Varvello <
>
> > varvello@
>
> > >
> >> To:
>
> > pharo-users@.pharo
>
> >> Cc:
> >> Bcc:
> >> Date: Sun, 18 Jun 2017 23:45:32 -0700 (PDT)
> >> Subject: Bloated image again. Memory leak?
> >> Hi guys,
> >> I have this problem (http://forum.world.st/Huge-image-td4876854.html),
> >> now
> >> the image grow about 100MB per week and the suggestions shown on
> >> http://forum.world.st/Huge-image-td4876854.html don't work
> >>
> >> I'm on Pharo 5 on a mac.
> >>
> >> I suspect it is something related to GLMPanePort, see the attached jpg
> >> Can you help me please?
> >>
> >> TIA
> >> Davide
> >>
> >>
> >> ;
> >>
> >>
> >>
> >> --
> >> View this message in context: http://forum.world.st/Bloated-
> >> image-again-Memory-leak-tp4951861.html
> >> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
> >>
> >>
> >>
> >>
>
>
>
>
>
> --
> View this message in context: http://forum.world.st/Bloated-
> image-again-Memory-leak-tp4951862p4951885.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>
>


Re: [Pharo-users] Teapot session

2017-06-19 Thread p...@highoctane.be
Try Ctl-q or Cmd-q after having typed a few chars. Continue until you get a
match.

Works in 6.0

Phil

On Mon, Jun 19, 2017 at 5:11 PM, horrido  wrote:

> Interesting. Auto-complete doesn't show #removeAttribute: as an option.
>
> Another question: After I've logged out, I can still click on Backpage in
> the browser to get to a page that should no longer be authorized. Is there
> a
> way to prevent this? Is there a way to invalidate the page?
>
>
>
> Sven Van Caekenberghe-2 wrote
> >> On 19 Jun 2017, at 15:40, horrido <
>
> > horrido.hobbies@
>
> > > wrote:
> >>
> >> I've added an attribute to the session called #user...
> >>
> >> req session attributeAt: #user ifAbsentPut: user
> >>
> >> This is used to *determine if I'm logged in*. On logout, I would like to
> >> *remove* this attribute, but I can't figure out how to do it.
> Suggestion?
> >
> > req session removeAttribute: #user
> >
> >> Sven Van Caekenberghe-2 wrote
> >>> If you are talking about ZnServerSessions, the ones returned from
> >>> ZnRequest>>#session, then the answer is that they are eligible for
> >>> expiration and cleanup after 1 hour (see ZnServerSession>>#isValid).
> >>> Cleanup happens inZnSingleThreadedServer>>#periodTasks. Right now, the
> >>> expiration time is a fixed constant.
> >>>
>  On 19 Jun 2017, at 08:08, Stephane Ducasse <
> >>
> >>> stepharo.self@
> >>
> >>> > wrote:
> 
>  Teapot is a layer on zinc so you may check the Zinc chapters (I do not
>  know if this is there).
> 
> 
>  On Mon, Jun 19, 2017 at 1:42 AM, horrido <
> >>
> >>> horrido.hobbies@
> >>
> >>> > wrote:
> > Does Teapot's (ZnRequest's?) session ever expire? What is the expiry
> > period?
> >
> > I can't find where it's specified or configured.
> >
> >
> >
> >
> > --
> > View this message in context:
> > http://forum.world.st/Teapot-session-tp4951845.html
> > Sent from the Pharo Smalltalk Users mailing list archive at
> > Nabble.com.
> >
> 
> >>
> >>
> >>
> >>
> >>
> >> --
> >> View this message in context:
> >> http://forum.world.st/Teapot-session-tp4951845p4951905.html
> >> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>
>
>
> --
> View this message in context: http://forum.world.st/Teapot-
> session-tp4951845p4951908.html
> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com.
>
>
>


Re: [Pharo-users] UUIDGenerator

2017-06-19 Thread p...@highoctane.be
Spotter rulez :-)

On Mon, Jun 19, 2017 at 6:02 PM, Tim Mackinnon  wrote:

> Damnit your right…. #help keyboard gives you the business… nice
>
> I think the prompt to use Spotter should be in the welcome text though, as
> its a bit hidden - maybe is should be in the “Explore” section.
>
> Tim
>
>
> On 19 Jun 2017, at 11:30, p...@highoctane.be wrote:
>
> That being said, maybe one can do a spotter extension that looks into the
> help topics.
>
> I did one with windows (should be in Pharo7).
>
> So one would ho to spotter and put a word followed by #help or #he
>
> Maybe this is in already!
> Phil
>
> On Mon, Jun 19, 2017 at 10:43 AM, Tim Mackinnon  wrote:
>
>> It is in the Pharo help - however I have noticed that Help doesn’t have a
>> convenient search box and the new Welcome screen that launches with Pharo
>> possibly should have a shortcut to useful navigational features…. Sounds
>> like something I can contributed.
>>
>> Tim
>>
>> On 19 Jun 2017, at 00:39, horrido  wrote:
>>
>> I didn't know about the Spotter. That is so frickin' cool!!!
>>
>> Thanks.
>>
>>
>> philippeback wrote
>>
>> Spotting for hex is hardly complex.
>>
>> Shift-Enter hex #im
>>
>> --> implementors of hex, first one I see is in ByteArray.
>>
>> Shit-Enter hex #se
>>
>> --> senders of hex. First one is a test in ByteArray
>>
>> testHex
>> "self debug: #testHex"
>> self assert: #[122 43 213 7] hex = '7a2bd507'.
>> self assert: #[151 193 242 221 249 32 153 72 179 41 49 154 48 193 99 134]
>> hex = '97c1f2ddf9209948b329319a30c16386'.
>> self assert: (ByteArray readHexFrom: '7A2BD507') = #[122 43 213 7].
>> self assert: (ByteArray readHexFrom: '7a2bd507') = #[122 43 213 7].
>>
>> From this test, one can spot readHexFrom: which uses lowercase or
>> uppercase
>> for reading.
>>
>> And asUppercase, Shift-Enter upper, scrolll down as bit, find
>> String>>#asUppercase
>>
>> Spotter is really great at finding stuff, and coupled with tests and
>> examples it helps in building understanding.
>>
>> Agreed, this is not the same as looking for stuff as in, say, Java or
>> Python. I find it better in the long run still.
>>
>> Phil
>>
>> On Sat, Jun 17, 2017 at 9:23 PM, horrido <
>>
>>
>> horrido.hobbies@
>>
>>
>> > wrote:
>>
>> Message 'next' is not understood.
>>
>> But yes,
>>
>> UUID new hex asUppercase
>>
>> works fine.
>>
>> This is what happens when there is inadequate documentation: you end up
>> doing things the *hard* way.
>>
>> Thanks.
>>
>>
>>
>> Sven Van Caekenberghe-2 wrote
>>
>> Why not just
>>
>>  UUIDGenerator default next hex asUppercase.
>>
>> Or even
>>
>>  UUID new hex asUppercase.
>>
>> ?
>>
>> Since you are using #generateBytes:forVersion: (which is an internal
>> method BTW), you must be working in an older Pharo image (older than
>>
>> 6).
>>
>> We replaced the UUIDGenerator class, the class comment in from the
>>
>> newer
>>
>> version.
>>
>> On 17 Jun 2017, at 16:27, horrido <
>>
>>
>> horrido.hobbies@
>>
>>
>> > wrote:
>>
>>
>> Okay, I figured it out. Here's my method:
>>
>> generateUUID
>>   | aStream hex s x |
>>   hex := '0123456789ABCDEF'.
>>   x := ByteArray new: 16.
>>   UUIDGenerator default generateBytes: x forVersion: 4.
>>   s := String new: 32.
>>   aStream := WriteStream on: s.
>>   x do: [ :each | aStream nextPut: (hex at: each // 16 + 1).
>>   aStream nextPut: (hex at: each \\ 16 + 1) ].
>>   ^ s
>>
>> Works like a charm. It would've been nice if a similar example was
>> available
>> /somewhere/ on the web.
>>
>>
>>
>> --
>> View this message in context:
>> http://forum.world.st/UUIDGenerator-tp4951725p4951731.html
>> Sent from the Pharo Smalltalk Users mailing list archive at
>>
>> Nabble.com <http://nabble.com/>.
>>
>>
>>
>>
>>
>>
>>
>> --
>> View this message in context: http://forum.world.st/UUIDGenerator-
>> tp4951725p4951743.html
>> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com
>> <http://nabble.com/>.
>>
>>
>>
>>
>>
>>
>>
>>
>> --
>> View this message in context: http://forum.world.st
>> /UUIDGenerator-tp4951725p4951844.html
>> Sent from the Pharo Smalltalk Users mailing list archive at Nabble.com
>> <http://nabble.com/>.
>>
>>
>>
>
>


Re: [Pharo-users] PharoJS

2017-06-22 Thread p...@highoctane.be
If one does Angular, one does it the Angular way, typescript and all.

There is little point in doing PharoJS in Angular.

Amber and Angular is also hard to do.

Another issue with Amber is that it "compiles" to JS, and there are a ton
of hard to read context handling code (try to debug that in a js
debugger... ahah). For a project of mine, I can do it all Amber.

Backend code is another story and frankly, a lot of *paying* customer are
not caring about the latest "fad" in SPA/push/reactive/...

A solid app that makes sense in streamlining a process is already heaven,
and translates into cold cash.

I am inheriting some code base where I see jQuery, React, Angular 1.x and
some custom scripting all mixed up along with npm, bower, yarn, grunt
things to do. WTF.

So, customers asking for Angular. Ok, what kind of customers? Business
owners? Or IT departments? I am done trying to sell Pharo to IT people.

We are better off at upper echelons in the food chain. Where there is
business value and speed of execution, and tangible results.

I was explaining some reporting code to a Project Management Officer this
afternoon. It is Pharo and Seaside. Well, he can actually make sense of
what is in the code and can now come back with new ideas for value added
features. Just put a halt at a strategic place and was able to inspect key
business data interactively.
Try that with any JS code.

Phil





On Thu, Jun 22, 2017 at 3:38 PM, andrew glynn  wrote:

> I was wondering:
>
> a) I'm assuming PharoJS would be much like Amber but inside the Pharo VM.
>
> b) How much of the Amber codebase could be re-used for it?
>
> I'm interested on the one hand, mainly due to the demand for Angular code
> in the browser (jQuery is great in Seaside, but many clients are looking
> for Angular recently), and my distaste for debugging JavaScript.  Amber is
> ok but lacks the depth of tooling in Pharo, and isn't keeping up with the
> (constant) breaking changes in node and NPM.  (Not that I blame the
> developers of Amber, it's a problem with the mindset of the developers in
> the JavaScript ecosystem - the way that Angular2 is almost completely
> different from Angular is an example of the lack of interest in the
> existing user base).
>
> The problem I see is that PharoJS would have the same issues.  As a result
> it would not only be a fair amount of work to accomplish, it would be far
> more to maintain.  The Pharo ecosystem is based on an entirely opposite
> mindset to the JS ecosystem - a few very good frameworks and a reasonable
> number of very good libraries, resulting in highly maintainable code even
> on projects with only one or two developers.  On top of that it would have
> to deal with the issues with JS itself that make writing decent tools
> virtually impossible.
>
> Andrew Glynn
>
> -Original Message-
> From: Pharo-users [mailto:pharo-users-boun...@lists.pharo.org] On Behalf
> Of pharo-users-requ...@lists.pharo.org
> Sent: Thursday, June 22, 2017 8:41 AM
> To: pharo-users@lists.pharo.org
> Subject: Pharo-users Digest, Vol 50, Issue 108
>
> Send Pharo-users mailing list submissions to
> pharo-users@lists.pharo.org
>
> To subscribe or unsubscribe via the World Wide Web, visit
> http://lists.pharo.org/mailman/listinfo/pharo-users_
> lists.pharo.org
> or, via email, send a message with subject or body 'help' to
> pharo-users-requ...@lists.pharo.org
>
> You can reach the person managing the list at
> pharo-users-ow...@lists.pharo.org
>
> When replying, please edit your Subject line so it is more specific than
> "Re: Contents of Pharo-users digest..."
>
>
>


Re: [Pharo-users] Using the Debugger to write code

2017-07-12 Thread p...@highoctane.be
(#Motivation asClass fromString: 'a') sayIt

is not working better :-)

Should.

Phil

On Wed, Jul 12, 2017 at 8:54 AM, Sven Van Caekenberghe  wrote:

> Yes, but these are all inside the method editor.
>
> I wanted to start with
>
> (Motivation fromString: 'foo') sayIt.
>
> in a playground/workspace.
>
> But with just a DNU it works.
>
> > On 12 Jul 2017, at 08:49, p...@highoctane.be wrote:
> >
> > What is not working? Check this:
> >
> > 
> >
> > Hit Define new class and just accept what is proposed, then proceed
> >
> > 
> >
> > Now hit Create and define the method.
> >
> > 
> >
> > etc etc for usual coding.
> >
> > Best,
> > Phil
> >
> > On Wed, Jul 12, 2017 at 8:35 AM, K K Subbu  wrote:
> > On Wednesday 12 July 2017 08:33 AM, horrido wrote:
> > But for the life of me, I can't figure out how to create new classes for
> my
> > application from within the Debugger. Must I create new classes using the
> > System Browser first before I can continue adding new methods from within
> > the Debugger? What's the recommended procedure for all this?
> >
> > Not necessarily. In Pharo, everything happens through message sends.
> > Classes are created by sending any one of subclass:* family of messages
> to the parent class. System Browser makes it convenient by adding a
> template to its bottom text panel. Magic happens in the subclass:* message
> sends.
> >
> > When you "inspect" an object in the Debugger, a text panel will open up
> along the right side where you can type in a command just like in System
> Browser and "doIt". E.g. to create a subclass from Object.
> >
> >Object subclass: ...
> >
> > HTH .. Subbu
> >
> >
> >
>
>
>
>


Re: [Pharo-users] Compiling documents with Pillar

2017-07-24 Thread p...@highoctane.be
You do it with Docker.

Check:

https://github.com/cdlm/docker-texlive

and

https://docs.docker.com/docker-for-windows/

Phil

On Sun, Jul 23, 2017 at 8:29 PM, Myroslava Romaniuk 
wrote:

> Hi,
>
> how do I compile a document using Pillar if I want to get a PDF? I tried
> googling but didn't get anything helpful. Btw I'm using Windows.
>
> Thanks,
> Myroslava
>


Re: [Pharo-users] Question

2017-07-24 Thread p...@highoctane.be
LargeInteger is not what you should use.

Try this:

v:= SmallInteger minVal - 1

In 64-bit, one gets:"-1152921504606846977"

and there you have a LargeNegativeInteger that prints properly.

v := SmallInteger maxval + 1

"1152921504606846976"

same but positive.

You have Integers that are Numbers and why bother with the large or small
thing? It works.

If things are getting slow, well, profile and optimize.

Phil



On Mon, Jul 24, 2017 at 10:54 AM, Koos Brandt  wrote:

> Hi
>
> I am still learning but something weird happened.
>
> In a new Workspace
>
> Do-it myVar := LargeInteger new
> Print-it myVar 
>
> When I inspect it I get
> SubclassResponsibility: LargeInteger had the subclass responsibility to
> implement #printOn:base:
>
> When I browse LargeInteger, then at Integer level I get a message “new” as
> follows:
>
> *new*
>
> * self == Integer ifTrue: [*
> * ^ self error: 'Integer is an abstract class.  Make a concrete
> subclass.'].*
> * ^ super new*
>
> I looked for new higher up in the hierarchy(super), but could not see it.
> Maybe I am a bit dumb still with looking up.
>
> I tried on SmallInteger a new, but got back
> Error: SmallIntegers can only be created by performing arithmetic.
>
> I then checked and noticed that SmallInteger actually have new and
> basicNew implemented (override)
>
> So the error I got on smallinteger was from the override
> LargeInteger has no override, but has a “silent" error
>
> This seems a bit weird to me
>
> Just so you know I also tried
> Do-it myVar := LargeInteger new: 1
> Print-it myVar class.-> LargeInteger
> Dot-it myVar := myVar + 1
>
> The last statement hangs the image! (Tried 3 times)
>
> Comment:
> 1. I am surprised that Do-it did not give me an error on the new: (there
> is a message is the hierarchy of new:neg and maybe the neg is optional?)
> 2. The new: seemed to have created 1 LargeIntegers
> 3. I tried the new: also with just 5, and same result, image hang. (I
> thought 10,000 was maybe a very large loop for the + 1..)
>
> Did I damage something in the image maybe? I started this one just
> yesterday to look at MOOC week1.
>
> I do not need LargeIntegers for now but …
>
>
> This is Pharo 6.0 64 Bit on Mac OSX Sierra 10.12.5 (iMac 27, 2.9GHz Intel
> Core i5, 16GB RAM)
>
> Regards
>
> Koos Brandt
> 0824542028
>
>
>
>


Re: [Pharo-users] Compiling documents with Pillar

2017-07-25 Thread p...@highoctane.be
https://github.com/cdlm/docker-texlive



On Jul 23, 2017 8:38 PM, "Glenn Hoetker"  wrote:

> Thanks goodness I'm not the only one who had trouble finding how to do
> this. I also look forward to the answer.
>
> Glenn
>
>
>
> Sent from my iPad
>
> > On Jul 23, 2017, at 11:29 AM, Myroslava Romaniuk 
> wrote:
> >
> > Hi,
> >
> > how do I compile a document using Pillar if I want to get a PDF? I tried
> googling but didn't get anything helpful. Btw I'm using Windows.
> >
> > Thanks,
> > Myroslava
>
>
>


Re: [Pharo-users] Documentation

2017-07-27 Thread p...@highoctane.be
pillar things:

fork and PR

Use https://github.com/cdlm/docker-texlive for generating artefacts like
PDFs.

Edit in any text editor. I am using Vim with pillar syntax. There is some
Emacs available but I do not use Emacs.

HTH
Phil




On Jul 26, 2017 22:58, "Jimmie Houchin"  wrote:

I am looking at participating in the documentation if that is a good area
to plug in.

I do not necessarily have the expertise on the subjects, but I can bring
fresh eyes and the eyes of a native English speaker.

What is the best way to assist?

For example I am currently reading the Booklet-uFFI.

I have some questions and suggestions. How or to whom do I communicate
these?

If I modify the UnifiedFFI.pillar file, do I do the normal GitHub pull
requests? Or is this process handled via Iceberg?

Do I edit them manually in a normal text editor or is there a preferred way
within Pharo.

Is this process documented somewhere? Or do I need to document it? :)

And what about similar for the MOOC?

Any guidance or suggestions, and suggestions where you would like help the
most are greatly appreciated.

Thanks.


Jimmie


Re: [Pharo-users] Critical issues for Dr. Geo on P6

2017-07-28 Thread p...@highoctane.be
Changing too many things at once is indeed annoying.

Now, I am ready to live with that but at one point, I think that we will
have to move to something like I see done in other fast evolving ecosystems.

In Hadoop for example, Hortonworks (a distribution) moved to a set of slow
evolving substrate that is stable and know to stay stable for a long period
(HDFS, YARN) and a set fast moving releases for projects that do build on
top (Spark).

Holding back on the new things makes you feel like you use a tool of the
past. Living on the bleeding edge is not doable because you need to solve
too many non business centric issues.

There needs to be a combination.

As far as I am concerned, I worked in 3.0 a lot, skipped the whole 4.0
ship, embarked on the 5.0 and, albeit if I did a bit on 6.0, I may not
develop production code on it at the moment. 7.0 looks okay but there are
lot of changing things there, so, that is also too much for me.

6.1 can lure me in with Iceberg and 64-bit UFFI and fast inspectors on
large collections. I need a platform I can understand and build upon.

There needs to be a semblance of LTS in this.

Maybe a 6.1, 6.2, 6.3 story and a 7.x line with boostrap magic and what not.

6.x is a great platform and has a lot going for it if stable enough.

I have projects coming my way and using Pharo is an option. Now, I need
something that is not going to shift under my feet.

Especially if I want to embark crew along.

Phil

On Fri, Jul 28, 2017 at 11:00 AM, Serge Stinckwich <
serge.stinckw...@gmail.com> wrote:

>
>
> On Fri, Jul 28, 2017 at 9:34 AM, Hilaire  wrote:
>
>> I don't share your enthusiasm.
>>
>> I once set up a satisfactory build environment for DrGeo, based on P3. As
>> long as I stay with P3, I can concentrate on DrGeo code: write the code,
>> then fire up a build script to deploy the application. Now porting to P6 is
>> a pain: the infrastructure to deploy a desktop application has not evolve
>> since P3, I have to build again a deployment environment from scratch (VM
>> support, shrinked/built image, I don't know the promise of minimal image
>> build up is not palpable for me).
>>
>> Now If I have to spend days on that, I am not sure I will do it again, I
>> can't compete against other geometry application if I have to fight against
>> pharo too. What I want is to concentrate working on DrGeo not Pharo, sorry
>> to make it explicit but I can't much offer to do both.
>>
>
> ​I have sometimes the same concerns with Pharo or some tools of the Pharo
> ecosystem. I know that we are trying to do our best and regarding the
> number of core developers we have already an incredible platform. But
> sometimes, you need to very simple updates and because of subtle problems
> with VM/configurations/CI/ etc ...  this is not that simple and we need to
> spend times on boring stuff.
>
> There is no simple solution.
>
> One solution might be that the core developers only focus on core Pharo
> functionalities but I think this is somewhat difficult, because most of the
> dev are from RMOD. RMOD is a research unit and could not spend all his
> money/effort on an engineering process.
>
> Another solution is to grow our community. More people, more companies to
> sustain more engineers through the consortium. The more people we are able
> to attract, the more people will help to develop working solutions for
> problems like deployment or to have bug-fixing intermediate releases.
>
> ​This is why we all need ​in the community to do as much as possible
> advertisements: lectures at universities, talk to your colleague about
> Pharo, do demos in companies, at open-source forums, use Twitter do talk
> about Pharo ecosystem, the software you are developing with Pharo.
> Don't hide problems but talk about our nice platform and our community.
>
> We have done this with Stephane in the early days of Pharo at open-source
> forums in France and I remember that you come in the community after we
> meet you in one of these forums :-)
> So DrGeo2 exists because of this kind of advertisement.
>
> Regards,
>
> --
> Serge Stinckwich
> UCN & UMI UMMISCO 209 (IRD/UPMC)
> Every DSL ends up being Smalltalk
> http://www.doesnotunderstand.org/
>


Re: [Pharo-users] Critical issues for Dr. Geo on P6

2017-07-28 Thread p...@highoctane.be
On Fri, Jul 28, 2017 at 3:25 PM, Sven Van Caekenberghe  wrote:

>
> > On 28 Jul 2017, at 15:13, p...@highoctane.be wrote:
> >
> > Changing too many things at once is indeed annoying.
> >
> > Now, I am ready to live with that but at one point, I think that we will
> have to move to something like I see done in other fast evolving ecosystems.
> >
> > In Hadoop for example, Hortonworks (a distribution) moved to a set of
> slow evolving substrate that is stable and know to stay stable for a long
> period (HDFS, YARN) and a set fast moving releases for projects that do
> build on top (Spark).
> >
> > Holding back on the new things makes you feel like you use a tool of the
> past. Living on the bleeding edge is not doable because you need to solve
> too many non business centric issues.
> >
> > There needs to be a combination.
> >
> > As far as I am concerned, I worked in 3.0 a lot, skipped the whole 4.0
> ship, embarked on the 5.0 and, albeit if I did a bit on 6.0, I may not
> develop production code on it at the moment. 7.0 looks okay but there are
> lot of changing things there, so, that is also too much for me.
> >
> > 6.1 can lure me in with Iceberg and 64-bit UFFI and fast inspectors on
> large collections. I need a platform I can understand and build upon.
> >
> > There needs to be a semblance of LTS in this.
>
> But even the LTS concept does not solve all problems.
>
> Every 2 years there is a new LTS, which is supported for 5 years.
>

You are a Ubuntu user. I am a CentOS|RHEL user.
There support is 10 years.

Check this: https://wiki.centos.org/About/Product

Official party line here:
https://access.redhat.com/support/policy/updates/errata

TL;DR:

CentOS6: until 2020 for maintenance updates
CentOS7, until 2024 for maintenance updates.

Using the recent/latest is possible with e.g.

* Software Collections https://www.softwarecollections.org/en/
* LXC

If one needs a 4.x kernel that is doable too via elrepo. But there is a lot
of backport happening by RedHat. There is a reason these guys are making
gobs of money: they support business.

Frankly I wouldn't touch Ubuntu with a 10 feet pole anymore now that I have
100+ servers running CentOS under management.




> But in most projects (the same happened here), you are lazy and wait 5
> years until you *have* to upgrade.
>
> And by then the difference between what you started with (say 12.04) and
> the current stable (say 16.04) can already be huge (remember, you skipped
> one LTS release) and the next one is already coming (18.04).
>

To be frank 14.04 is the only decent release I know. All of the other ones
have issues of one kind or another.

>
> Change is unavoidable, it is not just part of life, it *is* life.
>

Sure. But change is to be managed and the business is what makes money. So,
not catering to business needs is a losing proposition.

There is this business by Clement and Esteban that apparently will come to
life at one point. I guess business forces may have more impact at that
time frame. Wait and see.

Phil

>
> > Maybe a 6.1, 6.2, 6.3 story and a 7.x line with boostrap magic and what
> not.
> >
> > 6.x is a great platform and has a lot going for it if stable enough.
> >
> > I have projects coming my way and using Pharo is an option. Now, I need
> something that is not going to shift under my feet.
> >
> > Especially if I want to embark crew along.
> >
> > Phil
> >
> > On Fri, Jul 28, 2017 at 11:00 AM, Serge Stinckwich <
> serge.stinckw...@gmail.com> wrote:
> >
> >
> > On Fri, Jul 28, 2017 at 9:34 AM, Hilaire  wrote:
> > I don't share your enthusiasm.
> >
> > I once set up a satisfactory build environment for DrGeo, based on P3.
> As long as I stay with P3, I can concentrate on DrGeo code: write the code,
> then fire up a build script to deploy the application. Now porting to P6 is
> a pain: the infrastructure to deploy a desktop application has not evolve
> since P3, I have to build again a deployment environment from scratch (VM
> support, shrinked/built image, I don't know the promise of minimal image
> build up is not palpable for me).
> >
> > Now If I have to spend days on that, I am not sure I will do it again, I
> can't compete against other geometry application if I have to fight against
> pharo too. What I want is to concentrate working on DrGeo not Pharo, sorry
> to make it explicit but I can't much offer to do both.
> >
> >
> > ​I have sometimes the same concerns with Pharo or some tools of the
> Pharo ecosystem. I know that we are trying to do our best and regarding the
> number of core developers we have already an incredible platform. But
> 

[Pharo-users] Zinc Crash / semaphores

2017-07-31 Thread p...@highoctane.be
I have this crash log on a server.

https://gist.github.com/philippeback/9527b74c081629c2b05466353c4326b3

It is running on Windows 2012 R2 with a Pharo 5.0
There is a SeasideApp.

Is there any known semaphore leak?

Because this app is very lightly used and I was suprised to see this.

Windows may be the cause but never had such an issue in the environment.

TIA
Phil


Re: [Pharo-users] Zinc Crash / semaphores

2017-07-31 Thread p...@highoctane.be
I am doing external REST calls indeed.

No caching across WASessions.

Phil

On Mon, Jul 31, 2017 at 1:00 PM, Sven Van Caekenberghe  wrote:

> Do you make any external (REST/network) calls yourself while handling your
> requests ?
>
> Do you do any kind of caching yourself ?
>
> > On 31 Jul 2017, at 12:40, p...@highoctane.be wrote:
> >
> > I have this crash log on a server.
> >
> > https://gist.github.com/philippeback/9527b74c081629c2b05466353c4326b3
> >
> > It is running on Windows 2012 R2 with a Pharo 5.0
> > There is a SeasideApp.
> >
> > Is there any known semaphore leak?
> >
> > Because this app is very lightly used and I was suprised to see this.
> >
> > Windows may be the cause but never had such an issue in the environment.
> >
> > TIA
> > Phil
>
>
>
>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
On Mon, Aug 28, 2017 at 12:10 AM, Dimitris Chloupis 
wrote:

> Also most don't know this but light themes of Pharo were in part hard
> coded. Esteban in order to create the dark theme which is based on the most
> popular dark theme ( if my memory serves correctly) , Darcula , he had to
> remove all this nasty code. He essentially made it possible for Pharo to
> have themes without worrying about hard coded colors. So if you ever want
> to make the light theme even lighter you have the dark theme to thank for
> making it easier for you.
>
> Quite an irony , would not agree ?
>
> If the doctors say your eye sight is great , he knows what he is talking
> about.
>
> Black foreground against dark grey background sound like a bug. Care to
> share a screenshot ?
> On Mon, 28 Aug 2017 at 00:51, PBKResearch  wrote:
>
>> I agree with Dimitris - it is all a matter of preference - not all eyes
>> are the same. For myself, I find the default dark theme in Pharo very
>> uncomfortable. On my system, some elements have a black foreground on a
>> dark grey background, which is almost impossible to see. This is always
>> true of the maximise/minimise/close buttons, but sometimes also of text
>> fields in a playground. Whenever I download a new image, I immediately
>> switch to the Watery theme, with light background and nice coloured buttons
>> on the windows.
>>
>> Of course, my eyes may not be typical. I am now aged 84, and I have had
>> cataract operations on both eyes. My sight is actually quite good - my
>> optometrist confirms that I am legal to drive without spectacles - but my
>> adverse reaction to dark mode is strong and immediate.
>>
>
Eye issues as well. Retinal detachment in both, and cataract on the right
one. Loads of floaters.

Light mode kills them.

Dark theme : can code for hours without any trouble.

At the office I am at now 90% of coders are using dark themes.

Indeed the windows buttons are annoying, I have my own little hack to make
them better.
When a control bugs you, bring a halo and try to reverse the form, usually
makes things readable.

Phil


>
>> Just my 2p worth
>>
>> Peter Kenny
>>
>> -Original Message-
>> From: Pharo-users [mailto:pharo-users-boun...@lists.pharo.org] On Behalf
>> Of stephan
>> Sent: 27 August 2017 21:46
>> To: pharo-users@lists.pharo.org
>> Subject: Re: [Pharo-users] Dark Mode
>>
>> On 27-08-17 22:37, Dimitris Chloupis wrote:
>> > White or dark is a matter of preference. But the matter of preference
>> > is also a matter of biology . Not all eyes are same.
>>
>> The research is pretty clear: a large majority of developers does better
>> with light themes. I have been sufficiently clear on the choice to make
>> Pharo6 theme dark default
>>
>> Stephan
>>
>>
>>
>>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
On Mon, Aug 28, 2017 at 1:28 PM, Dimitris Chloupis 
wrote:

> I am no authority on dark theme because I am using my blue theme full time
> and I have addressed any colour issues I had.
>
> Retina detachment, wow that is serious ! I hope you doing better :(
>

Yeah, after that, not much can really stress me out that much.

And 2 x 27 inch monitors help. Pharo is great because I can make it be the
way I want it to code in it.



>
> Well I have myopia in both eyes, my left is 6 degrees which is pretty
> high. We myopics suppose to not see very well in the dark but my visual
> perception is great in dark environments even in almost complete darkness.
>
> Its weird because as I young boy I was non stop out in the sun and I live
> in Greece, here the Sun is very bright, yet it always hurt my eyes. Not
> much as knife pain, but more like feeling pressure on the eye. Of course I
> am not the only Greek in love with his sun glasses during summer.
>
> My eye doctor said it was because of my eyes being light color compared to
> the usual dark coloured eyes Greeks have. But I think the reason most
> likely is more mysterious :D
>
>
Ah ah, 1/2 italian with green eyes here. I feel you. I am running with
shades.

Phil


> On Mon, Aug 28, 2017 at 2:05 PM p...@highoctane.be 
> wrote:
>
>> On Mon, Aug 28, 2017 at 12:10 AM, Dimitris Chloupis <
>> kilon.al...@gmail.com> wrote:
>>
>>> Also most don't know this but light themes of Pharo were in part hard
>>> coded. Esteban in order to create the dark theme which is based on the most
>>> popular dark theme ( if my memory serves correctly) , Darcula , he had to
>>> remove all this nasty code. He essentially made it possible for Pharo to
>>> have themes without worrying about hard coded colors. So if you ever want
>>> to make the light theme even lighter you have the dark theme to thank for
>>> making it easier for you.
>>>
>>> Quite an irony , would not agree ?
>>>
>>> If the doctors say your eye sight is great , he knows what he is talking
>>> about.
>>>
>>> Black foreground against dark grey background sound like a bug. Care to
>>> share a screenshot ?
>>> On Mon, 28 Aug 2017 at 00:51, PBKResearch 
>>> wrote:
>>>
>>>> I agree with Dimitris - it is all a matter of preference - not all eyes
>>>> are the same. For myself, I find the default dark theme in Pharo very
>>>> uncomfortable. On my system, some elements have a black foreground on a
>>>> dark grey background, which is almost impossible to see. This is always
>>>> true of the maximise/minimise/close buttons, but sometimes also of text
>>>> fields in a playground. Whenever I download a new image, I immediately
>>>> switch to the Watery theme, with light background and nice coloured buttons
>>>> on the windows.
>>>>
>>>> Of course, my eyes may not be typical. I am now aged 84, and I have had
>>>> cataract operations on both eyes. My sight is actually quite good - my
>>>> optometrist confirms that I am legal to drive without spectacles - but my
>>>> adverse reaction to dark mode is strong and immediate.
>>>>
>>>
>> Eye issues as well. Retinal detachment in both, and cataract on the right
>> one. Loads of floaters.
>>
>> Light mode kills them.
>>
>> Dark theme : can code for hours without any trouble.
>>
>> At the office I am at now 90% of coders are using dark themes.
>>
>> Indeed the windows buttons are annoying, I have my own little hack to
>> make them better.
>> When a control bugs you, bring a halo and try to reverse the form,
>> usually makes things readable.
>>
>> Phil
>>
>>
>>>
>>>> Just my 2p worth
>>>>
>>>> Peter Kenny
>>>>
>>>> -Original Message-
>>>> From: Pharo-users [mailto:pharo-users-boun...@lists.pharo.org] On
>>>> Behalf Of stephan
>>>> Sent: 27 August 2017 21:46
>>>> To: pharo-users@lists.pharo.org
>>>> Subject: Re: [Pharo-users] Dark Mode
>>>>
>>>> On 27-08-17 22:37, Dimitris Chloupis wrote:
>>>> > White or dark is a matter of preference. But the matter of preference
>>>> > is also a matter of biology . Not all eyes are same.
>>>>
>>>> The research is pretty clear: a large majority of developers does
>>>> better with light themes. I have been sufficiently clear on the choice to
>>>> make
>>>> Pharo6 theme dark default
>>>>
>>>> Stephan
>>>>
>>>>
>>>>
>>>>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
You can eat eggs all you want provided you burn the calories. They are
shock full of amino acids.

Cholesterol is a precursor of testosterone, so, no cholesterol is going to
put a man in a bad place.

Eggs and heavy deadlifts and squats. Yay, feel the burn.

Speaking of which: anyone have a .fit file binding for Pharo?

See this forum thread for a clue:
https://www.thisisant.com/forum/viewthread/4275

Roassal + Dataframe on fit files would be a great thing to have.

Phil





On Mon, Aug 28, 2017 at 2:20 PM, Dimitris Chloupis 
wrote:

> Nutrition wise, scientists always agreed that eggs contained pretty much
> everything the body needs. Problem was cholesterol which the egg does
> significant rise.
>
> The fact that did change was that high cholesterol is bad, some doctors
> would argue even deadly for ones health. Problem was that this fact was
> based on a research that was on a very small group of subjects and if I am
> not mistaken it was not even humans it was lab rats.
>
> The problem none really funded a serious research for this fact and when
> they did they discovered that indeed eggs and other food do raise
> cholesterol significantly but our liver is capable of reducing the
> production of cholesterol to compensate hence its nowhere near as harmful
> as they used to assume.
>
> Science is flawed mainly because finding small facts is easy and cheap but
> general fact are very complex and very very expensive.
>
> Like all things, you get what you are paying for. This is why you see and
> hear so many contradictory facts. They are mostly based on simple cheap
> research. Plus "fact" is purely a fantasy, our world is too complex for
> facts as most people define them. There is truth sure, but not as easy to
> consume and explain as we would wish.
>
> The preference to light and dark themes is not product of bad scientific
> research. I suspect the reasons are too complex for science anyway because
> we are even eons away from explaining the human brain and how it works.
>
> Pharo not only allow you to choose a theme but its theme classes are
> actually very easy to use which is something it inherit from Squeak. It
> took me a day to create my own theme.
>
> The Dark UI theme class is excellent example for anyone who wants to
> subclass it and create his own light or dark theme because its not that
> complex.
>
> On Mon, Aug 28, 2017 at 2:57 PM Davorin Rusevljan <
> davorin.rusevl...@gmail.com> wrote:
>
>> If I can throw in my 2c, themes are like nutrition facts. When I was a
>> kid eggs were the healthiest thing to consume in universe. Then they were a
>> root of all evil, and now days are nutrition packed food.
>>
>> I have observed similar circles in background color usability. Pharo has
>> ability to choose a theme, it has both currently fashionable and older ones
>> to choose from. I do not see need for anything else on that front.
>>
>> Davorin Rusevljan
>>
>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
Alexandre,

Sure, I have swimming files from my Garmin Swim watch and I'd love to graph
them in Roassal/Datatable/Pharo.

Hope we are talking about the same format.

Phil

On Mon, Aug 28, 2017 at 8:36 PM, Alexandre Bergel 
wrote:

> Hi Phil,
>
> Yes, I wrote a FIT file parser. FIT is used to store “scientific” images,
> in particular for astronomy and medicine.
> Do you want the code?
>
> Alexandre
> --
> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
> Alexandre Bergel  http://www.bergel.eu
> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>
>
>
> On Aug 28, 2017, at 9:36 AM, p...@highoctane.be wrote:
>
> You can eat eggs all you want provided you burn the calories. They are
> shock full of amino acids.
>
> Cholesterol is a precursor of testosterone, so, no cholesterol is going to
> put a man in a bad place.
>
> Eggs and heavy deadlifts and squats. Yay, feel the burn.
>
> Speaking of which: anyone have a .fit file binding for Pharo?
>
> See this forum thread for a clue: https://www.thisisant.
> com/forum/viewthread/4275
>
> Roassal + Dataframe on fit files would be a great thing to have.
>
> Phil
>
>
>
>
>
> On Mon, Aug 28, 2017 at 2:20 PM, Dimitris Chloupis 
> wrote:
>
>> Nutrition wise, scientists always agreed that eggs contained pretty much
>> everything the body needs. Problem was cholesterol which the egg does
>> significant rise.
>>
>> The fact that did change was that high cholesterol is bad, some doctors
>> would argue even deadly for ones health. Problem was that this fact was
>> based on a research that was on a very small group of subjects and if I am
>> not mistaken it was not even humans it was lab rats.
>>
>> The problem none really funded a serious research for this fact and when
>> they did they discovered that indeed eggs and other food do raise
>> cholesterol significantly but our liver is capable of reducing the
>> production of cholesterol to compensate hence its nowhere near as harmful
>> as they used to assume.
>>
>> Science is flawed mainly because finding small facts is easy and cheap
>> but general fact are very complex and very very expensive.
>>
>> Like all things, you get what you are paying for. This is why you see and
>> hear so many contradictory facts. They are mostly based on simple cheap
>> research. Plus "fact" is purely a fantasy, our world is too complex for
>> facts as most people define them. There is truth sure, but not as easy to
>> consume and explain as we would wish.
>>
>> The preference to light and dark themes is not product of bad scientific
>> research. I suspect the reasons are too complex for science anyway because
>> we are even eons away from explaining the human brain and how it works.
>>
>> Pharo not only allow you to choose a theme but its theme classes are
>> actually very easy to use which is something it inherit from Squeak. It
>> took me a day to create my own theme.
>>
>> The Dark UI theme class is excellent example for anyone who wants to
>> subclass it and create his own light or dark theme because its not that
>> complex.
>>
>> On Mon, Aug 28, 2017 at 2:57 PM Davorin Rusevljan <
>> davorin.rusevl...@gmail.com> wrote:
>>
>>> If I can throw in my 2c, themes are like nutrition facts. When I was a
>>> kid eggs were the healthiest thing to consume in universe. Then they were a
>>> root of all evil, and now days are nutrition packed food.
>>>
>>> I have observed similar circles in background color usability. Pharo has
>>> ability to choose a theme, it has both currently fashionable and older ones
>>> to choose from. I do not see need for anything else on that front.
>>>
>>> Davorin Rusevljan
>>>
>>
>
>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
Dimming a LED screen is a bad idea. It flickers because of PWM.

My older Dell CCFL monitor feels better than brand new LED things with
brightness down.

http://www.flatpanelshd.com/focus.php?subaction=showfull&id=1362457985

Nvidia drivers are indeed a good thing!

Phil


On Mon, Aug 28, 2017 at 8:54 PM, Peter Uhnák  wrote:

> Or you people can just dim your screen instead of staring into a 60W
> lightbulb... then the theme doesn't matter.
>
> On Mon, Aug 28, 2017 at 8:38 PM, Alexandre Bergel  > wrote:
>
>> Ups… I think this FIT file format is for something else…
>>
>> Alexandre
>> --
>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>> Alexandre Bergel  http://www.bergel.eu
>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>
>>
>>
>> On Aug 28, 2017, at 3:36 PM, Alexandre Bergel 
>> wrote:
>>
>> Hi Phil,
>>
>> Yes, I wrote a FIT file parser. FIT is used to store “scientific” images,
>> in particular for astronomy and medicine.
>> Do you want the code?
>>
>> Alexandre
>> --
>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>> Alexandre Bergel  http://www.bergel.eu
>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>
>>
>>
>> On Aug 28, 2017, at 9:36 AM, p...@highoctane.be wrote:
>>
>> You can eat eggs all you want provided you burn the calories. They are
>> shock full of amino acids.
>>
>> Cholesterol is a precursor of testosterone, so, no cholesterol is going
>> to put a man in a bad place.
>>
>> Eggs and heavy deadlifts and squats. Yay, feel the burn.
>>
>> Speaking of which: anyone have a .fit file binding for Pharo?
>>
>> See this forum thread for a clue: https://www.thisisant.co
>> m/forum/viewthread/4275
>>
>> Roassal + Dataframe on fit files would be a great thing to have.
>>
>> Phil
>>
>>
>>
>>
>>
>> On Mon, Aug 28, 2017 at 2:20 PM, Dimitris Chloupis > > wrote:
>>
>>> Nutrition wise, scientists always agreed that eggs contained pretty much
>>> everything the body needs. Problem was cholesterol which the egg does
>>> significant rise.
>>>
>>> The fact that did change was that high cholesterol is bad, some doctors
>>> would argue even deadly for ones health. Problem was that this fact was
>>> based on a research that was on a very small group of subjects and if I am
>>> not mistaken it was not even humans it was lab rats.
>>>
>>> The problem none really funded a serious research for this fact and when
>>> they did they discovered that indeed eggs and other food do raise
>>> cholesterol significantly but our liver is capable of reducing the
>>> production of cholesterol to compensate hence its nowhere near as harmful
>>> as they used to assume.
>>>
>>> Science is flawed mainly because finding small facts is easy and cheap
>>> but general fact are very complex and very very expensive.
>>>
>>> Like all things, you get what you are paying for. This is why you see
>>> and hear so many contradictory facts. They are mostly based on simple cheap
>>> research. Plus "fact" is purely a fantasy, our world is too complex for
>>> facts as most people define them. There is truth sure, but not as easy to
>>> consume and explain as we would wish.
>>>
>>> The preference to light and dark themes is not product of bad scientific
>>> research. I suspect the reasons are too complex for science anyway because
>>> we are even eons away from explaining the human brain and how it works.
>>>
>>> Pharo not only allow you to choose a theme but its theme classes are
>>> actually very easy to use which is something it inherit from Squeak. It
>>> took me a day to create my own theme.
>>>
>>> The Dark UI theme class is excellent example for anyone who wants to
>>> subclass it and create his own light or dark theme because its not that
>>> complex.
>>>
>>> On Mon, Aug 28, 2017 at 2:57 PM Davorin Rusevljan <
>>> davorin.rusevl...@gmail.com> wrote:
>>>
>>>> If I can throw in my 2c, themes are like nutrition facts. When I was a
>>>> kid eggs were the healthiest thing to consume in universe. Then they were a
>>>> root of all evil, and now days are nutrition packed food.
>>>>
>>>> I have observed similar circles in background color usability. Pharo
>>>> has ability to choose a theme, it has both currently fashionable and older
>>>> ones to choose from. I do not see need for anything else on that front.
>>>>
>>>> Davorin Rusevljan
>>>>
>>>
>>
>>
>>
>


Re: [Pharo-users] Dark Mode

2017-08-28 Thread p...@highoctane.be
Dark Gmail, Dark Twitter, Wikipedia... etc no problem with Stylish.

https://userstyles.org/styles/browse?search_terms=gmail

Or make your own - here are a few I made.

https://userstyles.org/users/304480

I should do a dark Pharo.org :-)

Phil



On Mon, Aug 28, 2017 at 9:11 PM, Dimitris Chloupis 
wrote:

> Actually what you say makes no sense to me because my monitor is already
> at bare minimum. Its not the intensity, its the contrast. The problem
> obviously is not an exposure of 30 minutes. The mail I am writing now  has
> a white background. But its not a problem because I spent an 1 hour tops
> with email total time. I would like if Gmail had a dark theme but its no
> big deal.  However when one spent more than 8 hours it becomes a problem.
>
> It was the same when I was studying in UK law. I was very used into
> reading english because the vast majority of the coding books I had bought
> and reading since I was 13 years old were in english. It was not a problem
> reading for an hour, but after 5 hours both my eyes and brain were tired.
> Its that extra effort that accumulates hour by hour and the more time you
> spent, the more obvious it becomes. 5 hours reading a book in my mother
> tongue is like night and day.
>
> So  when I was spending a lot of hours working with Pharo the white them
> did became a major problem for me. Its not as if I see a light theme and
> after a few minutes I scream in pain "Oh my eyes are burning" :D
>
>
>
> On Mon, Aug 28, 2017 at 9:55 PM Peter Uhnák  wrote:
>
>> Or you people can just dim your screen instead of staring into a 60W
>> lightbulb... then the theme doesn't matter.
>>
>> On Mon, Aug 28, 2017 at 8:38 PM, Alexandre Bergel <
>> alexandre.ber...@me.com> wrote:
>>
>>> Ups… I think this FIT file format is for something else…
>>>
>>> Alexandre
>>> --
>>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>>> Alexandre Bergel  http://www.bergel.eu
>>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>>
>>>
>>>
>>> On Aug 28, 2017, at 3:36 PM, Alexandre Bergel 
>>> wrote:
>>>
>>> Hi Phil,
>>>
>>> Yes, I wrote a FIT file parser. FIT is used to store “scientific”
>>> images, in particular for astronomy and medicine.
>>> Do you want the code?
>>>
>>> Alexandre
>>> --
>>> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
>>> Alexandre Bergel  http://www.bergel.eu
>>> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>>>
>>>
>>>
>>> On Aug 28, 2017, at 9:36 AM, p...@highoctane.be wrote:
>>>
>>> You can eat eggs all you want provided you burn the calories. They are
>>> shock full of amino acids.
>>>
>>> Cholesterol is a precursor of testosterone, so, no cholesterol is going
>>> to put a man in a bad place.
>>>
>>> Eggs and heavy deadlifts and squats. Yay, feel the burn.
>>>
>>> Speaking of which: anyone have a .fit file binding for Pharo?
>>>
>>> See this forum thread for a clue: https://www.thisisant.
>>> com/forum/viewthread/4275
>>>
>>> Roassal + Dataframe on fit files would be a great thing to have.
>>>
>>> Phil
>>>
>>>
>>>
>>>
>>>
>>> On Mon, Aug 28, 2017 at 2:20 PM, Dimitris Chloupis <
>>> kilon.al...@gmail.com> wrote:
>>>
>>>> Nutrition wise, scientists always agreed that eggs contained pretty
>>>> much everything the body needs. Problem was cholesterol which the egg does
>>>> significant rise.
>>>>
>>>> The fact that did change was that high cholesterol is bad, some doctors
>>>> would argue even deadly for ones health. Problem was that this fact was
>>>> based on a research that was on a very small group of subjects and if I am
>>>> not mistaken it was not even humans it was lab rats.
>>>>
>>>> The problem none really funded a serious research for this fact and
>>>> when they did they discovered that indeed eggs and other food do raise
>>>> cholesterol significantly but our liver is capable of reducing the
>>>> production of cholesterol to compensate hence its nowhere near as harmful
>>>> as they used to assume.
>>>>
>>>> Science is flawed mainly because finding small facts is easy and cheap
>>>> but general fact are very complex and very very expensive.
>>>>
>>>> Like all things, you get what you are paying for. This is why you see
>>

Re: [Pharo-users] Dark Mode

2017-08-29 Thread p...@highoctane.be
White all over Smalltalks UIs are a reason why I do *not* use them.

Dark Pharo: good.

Properly themeable Pharo with a palette and logical color mappings:
nirvana. I hope to  contribute to that. I did some GToolkit dark theming
but it was too late for 6.0 so maybe for 7.

Try to code against a white background when you have floaters casting
shadows on your retina. I sucks big time.

I noticed that a lot of older folk suffer from this.

I once had a guy who wasn't telling younger team members that he wasn't
able to read their document due to too small fonts. We are talking C level
executives here...

These accessibility issues are going to become huge with people getting
older and having cash to spend.

>From what I can so see, hearing problems will be quite a thing with newer
generations.

Anyway, there is NegativeScreen on Windows to get whatever I want.

http://arcanesanctum.net/negativescreen/

Phil


On Aug 29, 2017 6:02 AM, "Markus Stumptner"  wrote:

> On 28/08/17 06:07, Dimitris Chloupis wrote:
>
>
>> I completely agree - dark mode is great for content that you want to
>> look cool, but no one consumes. :-)
>>
>
> You assume wrong cause dark themes have been dominating GUIs for over 3
> decades now.
>
> Not really; bright on dark was only dominant in the days of the CRT
> terminal when there were no "themes".  (Even if you could do it as a
> hardware switch, setting, say, a VT220 to black-on-white both looked
> terrible as it was more an uneven gray, and tended to dim  the tube more
> quickly by burning in the background.)
>
> Instead, since full bitmap graphics happened, all screen interfaces back
> to Xerox's prototype office systems, then Lisa/Macintosh, and then Windows
> 2.1 have been using dark type on a white background for text work.  Partly
> this was because of the original office metaphor, but partly also because
> it was shown that it was easier (meaning, less error prone) to read.
>
> Here's a study that showed that participants were 26% more accurate in
> reading text that way (note that "contrast reversal" on displays in those
> days meant dark characters on white background):
>
> Bauer, D., & Cavonius, C., R. (1980). Improving the legibility of visual
> display units through contrast reversal.
> In E. Grandjean, E. Vigliani (Eds.),  Ergonomic Aspects of Visual Display
> Terminals (pp. 137-142).
> London: Taylor & Francis
>
> There were other studies in the 1980s that didn't report lower errors but
> instead faster reading with black on white. Academically, the matter's
> pretty much considered settled - black on white is better for most of the
> population, and that's on screen, not on paper. (You can substitute any
> degree of light or creamy for the white, that's really a variation of
> screen quality.)
> The engineering workstations of the late 80s and 90s (Sun etc) used black
> and white as the application default as well, with white on black limited
> to console/shell windows. This was partly for consistency with the old
> style, partly for easy contrast with application windows in a multi-window
> environment.
>
> Pharo was the rare exception of using a white theme. Light themes may be
> popular but white are definitely not.  The web is the last fort of bright
> themes, but the web was and still is eons behind when it comes to matters
> of UI.
>
> Most other Smalltalks are dark-on-light by default all the way back to
> Smalltalk-80 out of Xerox PARC.  None of this had anything to do with the
> Web, which came after, but which obviously also profits from the same
> increase in readability.  Rather than behind, Smalltalk was ahead and the
> rest of the world followed.
>
> The dark theme as default in Pharo I personally consider a step back. As
> someone who's been busy for 25+ years defending use of Smalltalk for real
> applications, a return to a primarily developer-cool presentation instead
> of a user-oriented default is IMO not a plus for a language branch that was
> billed as more industry-oriented (which IMO is not exactly the same as
> developer-oriented).  But I also understand the desire to attract
> developers with the look that's currently fashionable.
>
> That said, I wonder if the recent preference for dark among developers
> (not Pharo-specific, but many languages) has to do with the rise of
> widespread code highlighting. I could see how colour highlighting shows up
> better on a dark background than being glared over by a white one.
>
> Markus
>


Re: [Pharo-users] Pharo 6.0 Generating Ruby-on-Rails Applications

2017-09-08 Thread p...@highoctane.be
Peter,

How hard would it be to generate other languages? e.g. PHP for Zend
Framework 2.

Best,

Phil

On Sep 7, 2017 14:54, "Peter Fisk"  wrote:

> Hi everyone, The RailsExpress.com website will be updated over the coming
> days to reflect what I am currently working on in Pharo 6.0. I have found
> that the "Smalltalk like" environment in Ruby isn't powerful enough to
> implement a fully automated web application generator. That is why I
> changed to Pharo a couple of weeks ago - progress using Pharo has been
> incredibly fast. So, my primary focus from now on will be development using
> Pharo on my Macintosh. The "Smalltalk like" environment in Ruby actually
> uses an interpreter (written in Ruby) that was designed to run Smalltalk
> byte codes. It would be trivial to run Smalltalk instead of Ruby using the
> framework. The rational for running Ruby instead of Smalltalk was to make
> it more accessible to Ruby-on-Rails developers. An interesting fact is that
> the Ruby/Smalltalk interpreter is already running nicely on the web (in a
> Rails environment using Qooxdoo libraries for the GUI) and also running on
> my Mac using JRuby with a Java Swing GUI. And it could be used with some
> modifications to run Smalltalk in the same environments. My goal is to
> build an "AI" that can automate most of the work that web developers do.
> Smalltalk is the only environment that I know of that can implement such an
> AI in a short period of time. BTW, I have read the material about Pier and
> Magritte which is very interesting, especially in regards to the DSL. My
> approach to building the GUI has been to model the Qooxdoo class structure
> in Smalltalk and use the Smalltalk objects to build the required code when
> I send them a "renderOn: aStream" message. I will be posting more Pharo
> related information on my Rails Express Quora blog
> . Regards, -- Peter
> --
> Sent from the Pharo Smalltalk Users mailing list archive
>  at Nabble.com.
>


Re: [Pharo-users] Pharo 6.0 Generating Ruby-on-Rails Applications

2017-09-08 Thread p...@highoctane.be
Nice. I'll definitely have a look because I need to prototype something
quite domain heavy and it may help a lot.

Phil

On Fri, Sep 8, 2017 at 5:09 PM, Peter Fisk  wrote:

> Hi Phil,
>
> I already have PHP support for CodeIgniter and Laravel.
>
> Adding support for Zend Framework might take a day or so to implement.
>
> Any framework which supports MVC and AJAX should be fairly easy to
> integrate
> (eg Python/Django, NodeJS/Adonis, etc). The main difference amongst the
> frameworks lies in the database object mappings.
>
> The specific language support is handled by streams.
>
> There are streams for HTML, CSS, JavaScript, PHP, Ruby, Python and
> sub-streams for Ruby/Rails, JavaScript/Qooxdoo, and so on.
>
> So, the framework is not at all Ruby or Ruby-on-Rails specific.
>
> Cheers,
>
> -- Peter
>
>
>
>
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>
>
>


[Pharo-users] Continued Fractions

2017-09-17 Thread p...@highoctane.be
Do we have anything related to continued fractions in Pharo?

https://en.wikipedia.org/wiki/Continued_fraction

I need that to match rectanges to aspect ratios etc.

TIA
Phil


Re: [Pharo-users] Continued Fractions

2017-09-17 Thread p...@highoctane.be
Ah, I see there is something in the Numerical Methods book. :rolleyes:

Phil

On Sun, Sep 17, 2017 at 8:30 PM, p...@highoctane.be 
wrote:

> Do we have anything related to continued fractions in Pharo?
>
> https://en.wikipedia.org/wiki/Continued_fraction
>
> I need that to match rectanges to aspect ratios etc.
>
> TIA
> Phil
>


Re: [Pharo-users] Continued Fractions

2017-09-19 Thread p...@highoctane.be
I need to match print ads sizes from various publications with a
standardized list of ratios (e.g. 2:1, 1:1, 2:7...) plus a bunch of other
metrics.

So  a rect of 1543@331 gives a float value that has can be best
approximated by a continued fraction approach.

But there are other complications. Now I am using a lookup table and try to
match with just a distance.

I am using DataFrame and hopefully more Roassal for all of this.

Pharo can be a good tool to manage the object model of this problem space.
I am prototyping something. We'll see how far I can get.

Phil

On Tue, Sep 19, 2017 at 9:30 PM, Stephane Ducasse 
wrote:

> Hi phil
>
> just out of sane curiosity do you have a pointer on ratio and
> rectangle and continued fraction?
>
> Stef
>
> On Mon, Sep 18, 2017 at 12:40 PM, werner kassens 
> wrote:
> > Hi Phil,
> > yes, in polymath it is the the object PMContinuedFraction.
> > werner
> >
> >
> > On 09/17/2017 08:38 PM, p...@highoctane.be wrote:
> >
> > Ah, I see there is something in the Numerical Methods book. :rolleyes:
> >
> > Phil
> >
> > On Sun, Sep 17, 2017 at 8:30 PM, p...@highoctane.be 
> > wrote:
> >>
> >> Do we have anything related to continued fractions in Pharo?
> >>
> >> https://en.wikipedia.org/wiki/Continued_fraction
> >>
> >> I need that to match rectanges to aspect ratios etc.
> >>
> >> TIA
> >> Phil
> >
> >
> >
>
>
>


Re: [Pharo-users] How to make pharo find sqlite?

2017-09-28 Thread p...@highoctane.be
What about

LD_LIBRARY_PATH=;$LD_LIBRARYPATH  ./pharo-ui some.image

Phil


On Thu, Sep 28, 2017 at 7:40 PM, Herby Vojčík  wrote:

> Hello!
>
> I try to deploy UDBCSQLite-using image in a 32bit ubuntu 16.04.3.
>
> I do have libsqlite3:
>
> root@32bit-agent:~# find / -name '*libsqlite*' -type f 2>>/dev/null
> /usr/lib/i386-linux-gnu/libsqlite3.so.0.8.6
> /var/lib/dpkg/info/libsqlite0.list
> /var/lib/dpkg/info/libsqlite3-0:i386.postinst
> /var/lib/dpkg/info/libsqlite3-0:i386.md5sums
> /var/lib/dpkg/info/libsqlite3-0:i386.shlibs
> /var/lib/dpkg/info/libsqlite0.postrm
> /var/lib/dpkg/info/libsqlite3-0:i386.symbols
> /var/lib/dpkg/info/libsqlite3-0:i386.list
> /var/lib/dpkg/info/libsqlite3-0:i386.triggers
> /var/cache/apt/archives/libsqlite0_2.8.17-12fakesync1_i386.deb
>
> but I get this in the output of the CI:
>
> 17:16:54.233 + ../pharo/pharo ./filmtower.image conf/run-tests.st
> 17:16:54.508 pthread_setschedparam failed: Operation not permitted
> 17:16:54.509 This VM uses a separate heartbeat thread to update its
> internal clock
> 17:16:54.509 and handle events.  For best operation, this thread should
> run at a
> 17:16:54.509 higher priority, however the VM was unable to change the
> priority.  The
> 17:16:54.509 effect is that heavily loaded systems may experience some
> latency
> 17:16:54.509 issues.  If this occurs, please create the appropriate
> configuration
> 17:16:54.509 file in /etc/security/limits.d/ as shown below:
> 17:16:54.509
> 17:16:54.509 cat < 17:16:54.509 *  hardrtprio  2
> 17:16:54.509 *  softrtprio  2
> 17:16:54.509 END
> 17:16:54.509
> 17:16:54.509 and report to the pharo mailing list whether this improves
> behaviour.
> 17:16:54.512
> 17:16:54.512 You will need to log out and log back in for the limits to
> take effect.
> 17:16:54.512 For more information please see
> 17:16:54.512 https://github.com/OpenSmalltalk/opensmalltalk-vm/releases/
> tag/r3732#linux
> 17:16:54.785
> 17:16:54.786 TowergameSyncTests
> 17:16:54.831 Error: External module not found
> 17:16:54.832 ExternalLibraryFunction(Object)>>error:
> 17:16:54.832 ExternalLibraryFunction(Object)>>externalCallFailed
> 17:16:54.833 ExternalLibraryFunction(ExternalFunction)>>invokeWithArgumen
> ts:
> 17:16:54.833 UDBCSQLite3DatabaseExternalObject
> class>>finalizeResourceData:
> 17:16:54.834 FFICalloutAPI>>function:module:
> 17:16:54.834 UDBCSQLite3Library(Object)>>ffiCall:module:
> 17:16:54.835 UDBCSQLite3DatabaseExternalObject
> class>>finalizeResourceData:
> 17:16:54.836 FFIExternalResourceExecutor>>finalize
> 17:16:54.836 WeakFinalizerItem>>finalizeValues
> 17:16:54.845 [ each finalizeValues ] in [ :each | [ each finalizeValues ]
> on: Exception fork: [ :ex | ex pass ] ] in WeakRegistry>>finalizeValues in
> Block: [ each finalizeValues ]
> 17:16:54.846 BlockClosure>>on:do:
> 17:16:54.852 [ Processor terminateActive ] in [ :ex |
> 17:16:54.852 | copy onDoCtx process handler bottom thisCtx |
> 17:16:54.852 onDoCtx := thisContext.
> 17:16:54.852 thisCtx := onDoCtx home.
> 17:16:54.852
> 17:16:54.852 "find the context on stack for which this method's is sender"
> 17:16:54.852 [ onDoCtx sender == thisCtx ]
> 17:16:54.852whileFalse: [ onDoCtx := onDoCtx sender.
> 17:16:54.852onDoCtx
> 17:16:54.852ifNil: [ "Can't find our home context.
> seems like we're already forked
> 17:16:54.852and handling another exception in
> new thread. In this case, just pass it through handler." ^ handlerAction
> cull: ex ] ].
> 17:16:54.852 bottom := [ Processor terminateActive ] asContext.
> 17:16:54.853 onDoCtx privSender: bottom.
> 17:16:54.853 handler := [ handlerAction cull: ex ] asContext.
> 17:16:54.853 handler privSender: thisContext sender.
> 17:16:54.853 (Process forContext: handler priority: Processor
> activePriority)
> 17:16:54.853resume.
> 17:16:54.853
> 17:16:54.853 "cut the stack of current process"
> 17:16:54.853 thisContext privSender: thisCtx.
> 17:16:54.853 nil ] in BlockClosure>>on:fork: in Block: [ Processor
> terminateActive ]
> 17:16:54.989
>
> Look like pharo was not able to find the sqlite3 lib.
>
> Any help?
>
> Thanks, Herby
>
>
>


Re: [Pharo-users] How to make pharo find sqlite?

2017-09-30 Thread p...@highoctane.be
Is https://pharo.fogbugz.com/f/cases/19990 showing again?

What is the module being loaded ?

Phil


On Sat, Sep 30, 2017 at 1:28 PM, Herby Vojčík  wrote:

> p...@highoctane.be wrote:
>
>> What about
>>
>> LD_LIBRARY_PATH=;$LD_LIBRARYPATH  ./pharo-ui some.image
>>
>> Phil
>>
>
> Thanks for answer, did not help.
>
> In fact it must be something different. As can be seen in the stack, it
> fails during finalizers, and as can be seen by looking at
> UDBCSQLite3DatabaseExternalObject class>>finalizeResourceData: code, the
> method it calls is sqlite close. It is hardly the first method that is
> should call...
>
> I suspect something around image save / load. Again. Lots of errors in
> those parts. But may be something else, as it kicks in only when
> SQLite-using tests starts to run. :-(
>
> Herby
>
> P.S.: I saw there is a similar thread out there, but it has problems with
> 32bit loaded by 64bit vm; but here, I have 32bit linux, so the vm installed
> should be 32bit.
>
> On Thu, Sep 28, 2017 at 7:40 PM, Herby Vojčík > <mailto:he...@mailbox.sk>> wrote:
>>
>> Hello!
>>
>> I try to deploy UDBCSQLite-using image in a 32bit ubuntu 16.04.3.
>>
>> I do have libsqlite3:
>>
>> root@32bit-agent:~# find / -name '*libsqlite*' -type f 2>>/dev/null
>> /usr/lib/i386-linux-gnu/libsqlite3.so.0.8.6
>> /var/lib/dpkg/info/libsqlite0.list
>> /var/lib/dpkg/info/libsqlite3-0:i386.postinst
>> /var/lib/dpkg/info/libsqlite3-0:i386.md5sums
>> /var/lib/dpkg/info/libsqlite3-0:i386.shlibs
>> /var/lib/dpkg/info/libsqlite0.postrm
>> /var/lib/dpkg/info/libsqlite3-0:i386.symbols
>> /var/lib/dpkg/info/libsqlite3-0:i386.list
>> /var/lib/dpkg/info/libsqlite3-0:i386.triggers
>> /var/cache/apt/archives/libsqlite0_2.8.17-12fakesync1_i386.deb
>>
>> but I get this in the output of the CI:
>>
>> 17:16:54.233 + ../pharo/pharo ./filmtower.image conf/run-tests.st
>> <http://run-tests.st>
>> 17:16:54.508 pthread_setschedparam failed: Operation not permitted
>> 17:16:54.509 This VM uses a separate heartbeat thread to update its
>> internal clock
>> 17:16:54.509 and handle events.  For best operation, this thread
>> should run at a
>> 17:16:54.509 higher priority, however the VM was unable to change
>> the priority.  The
>> 17:16:54.509 effect is that heavily loaded systems may experience
>> some latency
>> 17:16:54.509 issues.  If this occurs, please create the appropriate
>> configuration
>> 17:16:54.509 file in /etc/security/limits.d/ as shown below:
>> 17:16:54.509
>> 17:16:54.509 cat <> 17:16:54.509 *  hardrtprio  2
>> 17:16:54.509 *  softrtprio  2
>> 17:16:54.509 END
>> 17:16:54.509
>> 17:16:54.509 and report to the pharo mailing list whether this
>> improves behaviour.
>> 17:16:54.512
>> 17:16:54.512 You will need to log out and log back in for the limits
>> to take effect.
>> 17:16:54.512 For more information please see
>> 17:16:54.512
>> https://github.com/OpenSmalltalk/opensmalltalk-vm/releases/
>> tag/r3732#linux
>> <https://github.com/OpenSmalltalk/opensmalltalk-vm/releases/
>> tag/r3732#linux>
>> 17:16:54.785
>> 17:16:54.786 TowergameSyncTests
>> 17:16:54.831 Error: External module not found
>> 17:16:54.832 ExternalLibraryFunction(Object)>>error:
>> 17:16:54.832 ExternalLibraryFunction(Object)>>externalCallFailed
>> 17:16:54.833
>> ExternalLibraryFunction(ExternalFunction)>>invokeWithArguments:
>> 17:16:54.833 UDBCSQLite3DatabaseExternalObject
>> class>>finalizeResourceData:
>> 17:16:54.834 FFICalloutAPI>>function:module:
>> 17:16:54.834 UDBCSQLite3Library(Object)>>ffiCall:module:
>> 17:16:54.835 UDBCSQLite3DatabaseExternalObject
>> class>>finalizeResourceData:
>> 17:16:54.836 FFIExternalResourceExecutor>>finalize
>> 17:16:54.836 WeakFinalizerItem>>finalizeValues
>> 17:16:54.845 [ each finalizeValues ] in [ :each | [ each
>> finalizeValues ] on: Exception fork: [ :ex | ex pass ] ] in
>> WeakRegistry>>finalizeValues in Block: [ each finalizeValues ]
>> 17:16:54.846 BlockClosure>>on:do:
>> 17:16:54.852 [ Processor terminateActive ] in [ :ex |
>> 17:16:54.852 | copy onDoCtx process handler bottom thisCtx |
>> 17:16:54.85

Re: [Pharo-users] How to make pharo find sqlite?

2017-09-30 Thread p...@highoctane.be
Also, did you try with this VM:

http://get.pharo.org/vmTLatest60

Phil

On Sat, Sep 30, 2017 at 1:28 PM, Herby Vojčík  wrote:

> p...@highoctane.be wrote:
>
>> What about
>>
>> LD_LIBRARY_PATH=;$LD_LIBRARYPATH  ./pharo-ui some.image
>>
>> Phil
>>
>
> Thanks for answer, did not help.
>
> In fact it must be something different. As can be seen in the stack, it
> fails during finalizers, and as can be seen by looking at
> UDBCSQLite3DatabaseExternalObject class>>finalizeResourceData: code, the
> method it calls is sqlite close. It is hardly the first method that is
> should call...
>
> I suspect something around image save / load. Again. Lots of errors in
> those parts. But may be something else, as it kicks in only when
> SQLite-using tests starts to run. :-(
>
> Herby
>
> P.S.: I saw there is a similar thread out there, but it has problems with
> 32bit loaded by 64bit vm; but here, I have 32bit linux, so the vm installed
> should be 32bit.
>
> On Thu, Sep 28, 2017 at 7:40 PM, Herby Vojčík > <mailto:he...@mailbox.sk>> wrote:
>>
>> Hello!
>>
>> I try to deploy UDBCSQLite-using image in a 32bit ubuntu 16.04.3.
>>
>> I do have libsqlite3:
>>
>> root@32bit-agent:~# find / -name '*libsqlite*' -type f 2>>/dev/null
>> /usr/lib/i386-linux-gnu/libsqlite3.so.0.8.6
>> /var/lib/dpkg/info/libsqlite0.list
>> /var/lib/dpkg/info/libsqlite3-0:i386.postinst
>> /var/lib/dpkg/info/libsqlite3-0:i386.md5sums
>> /var/lib/dpkg/info/libsqlite3-0:i386.shlibs
>> /var/lib/dpkg/info/libsqlite0.postrm
>> /var/lib/dpkg/info/libsqlite3-0:i386.symbols
>> /var/lib/dpkg/info/libsqlite3-0:i386.list
>> /var/lib/dpkg/info/libsqlite3-0:i386.triggers
>> /var/cache/apt/archives/libsqlite0_2.8.17-12fakesync1_i386.deb
>>
>> but I get this in the output of the CI:
>>
>> 17:16:54.233 + ../pharo/pharo ./filmtower.image conf/run-tests.st
>> <http://run-tests.st>
>> 17:16:54.508 pthread_setschedparam failed: Operation not permitted
>> 17:16:54.509 This VM uses a separate heartbeat thread to update its
>> internal clock
>> 17:16:54.509 and handle events.  For best operation, this thread
>> should run at a
>> 17:16:54.509 higher priority, however the VM was unable to change
>> the priority.  The
>> 17:16:54.509 effect is that heavily loaded systems may experience
>> some latency
>> 17:16:54.509 issues.  If this occurs, please create the appropriate
>> configuration
>> 17:16:54.509 file in /etc/security/limits.d/ as shown below:
>> 17:16:54.509
>> 17:16:54.509 cat <> 17:16:54.509 *  hardrtprio  2
>> 17:16:54.509 *  softrtprio  2
>> 17:16:54.509 END
>> 17:16:54.509
>> 17:16:54.509 and report to the pharo mailing list whether this
>> improves behaviour.
>> 17:16:54.512
>> 17:16:54.512 You will need to log out and log back in for the limits
>> to take effect.
>> 17:16:54.512 For more information please see
>> 17:16:54.512
>> https://github.com/OpenSmalltalk/opensmalltalk-vm/releases/
>> tag/r3732#linux
>> <https://github.com/OpenSmalltalk/opensmalltalk-vm/releases/
>> tag/r3732#linux>
>> 17:16:54.785
>> 17:16:54.786 TowergameSyncTests
>> 17:16:54.831 Error: External module not found
>> 17:16:54.832 ExternalLibraryFunction(Object)>>error:
>> 17:16:54.832 ExternalLibraryFunction(Object)>>externalCallFailed
>> 17:16:54.833
>> ExternalLibraryFunction(ExternalFunction)>>invokeWithArguments:
>> 17:16:54.833 UDBCSQLite3DatabaseExternalObject
>> class>>finalizeResourceData:
>> 17:16:54.834 FFICalloutAPI>>function:module:
>> 17:16:54.834 UDBCSQLite3Library(Object)>>ffiCall:module:
>> 17:16:54.835 UDBCSQLite3DatabaseExternalObject
>> class>>finalizeResourceData:
>> 17:16:54.836 FFIExternalResourceExecutor>>finalize
>> 17:16:54.836 WeakFinalizerItem>>finalizeValues
>> 17:16:54.845 [ each finalizeValues ] in [ :each | [ each
>> finalizeValues ] on: Exception fork: [ :ex | ex pass ] ] in
>> WeakRegistry>>finalizeValues in Block: [ each finalizeValues ]
>> 17:16:54.846 BlockClosure>>on:do:
>> 17:16:54.852 [ Processor terminateActive ] in [ :ex |
>> 17:16:54.852 | copy onDoCtx process handler bottom thisCtx |
>> 17:16:54.852 onDoCtx := thisContext.
>&

Re: [Pharo-users] How to make pharo find sqlite?

2017-09-30 Thread p...@highoctane.be
I am using UDBCSQLite on Windows without problems.

Phil

On Sat, Sep 30, 2017 at 9:11 PM, Herby Vojčík  wrote:

> p...@highoctane.be wrote:
>
>> Also, did you try with this VM:
>>
>> http://get.pharo.org/vmTLatest60
>>
>
> 18:51:46.191 + curl get.pharo.org/vmTLatest60
> 18:51:46.207   % Total% Received % Xferd  Average Speed   Time Time
>  Time  Current
> 18:51:46.208  Dload  Upload   Total Spent
>   Left  Speed
> 18:51:46.208
> 18:51:46.242   0 00 00 0  0  0 --:--:--
> --:--:-- --:--:-- 0
> 18:51:46.242 100  6126  100  61260 0   172k  0 --:--:--
> --:--:-- --:--:--  175k
> 18:51:46.253 Downloading the latest pharoVM:
> 18:51:46.253 http://files.pharo.org/get-files/60/pharo-linux-threaded-lat
> est.zip
> 18:51:46.305 [pharo-vm/vm.zip]
> 18:51:46.305   End-of-central-directory signature not found.  Either this
> file is not
> 18:51:46.305   a zipfile, or it constitutes one disk of a multi-part
> archive.  In the
> 18:51:46.305   latter case the central directory and zipfile comment will
> be found on
> 18:51:46.305   the last disk(s) of this archive.
> 18:51:46.305 unzip:  cannot find zipfile directory in one of
> pharo-vm/vm.zip or
> 18:51:46.305 pharo-vm/vm.zip.zip, and cannot find
> pharo-vm/vm.zip.ZIP, period.
>
>
> It probably does not exist any more (I tried 70+vm and it failed in other
> aspects, it wasn't able to load git repo).
>
> Tried both 61+vmT and 61+vmI both; in 32vm/32os and 64vm/64os
> combinations. Always ended with same result.
>
> Must be some error in UDBCSQLiteLibrary itself. :-/
>
> Although the missing transcript output is scary and shows that vm may be
> culprit as well.
>
> Herby
>
> Phil
>>
>> On Sat, Sep 30, 2017 at 1:28 PM, Herby Vojčík > <mailto:he...@mailbox.sk>> wrote:
>>
>> p...@highoctane.be <mailto:p...@highoctane.be> wrote:
>>
>> What about
>>
>> LD_LIBRARY_PATH=;$LD_LIBRARYPATH  ./pharo-ui
>> some.image
>>
>> Phil
>>
>>
>> Thanks for answer, did not help.
>>
>> In fact it must be something different. As can be seen in the stack,
>> it fails during finalizers, and as can be seen by looking at
>> UDBCSQLite3DatabaseExternalObject class>>finalizeResourceData: code,
>> the method it calls is sqlite close. It is hardly the first method
>> that is should call...
>>
>> I suspect something around image save / load. Again. Lots of errors
>> in those parts. But may be something else, as it kicks in only when
>> SQLite-using tests starts to run. :-(
>>
>> Herby
>>
>> P.S.: I saw there is a similar thread out there, but it has problems
>> with 32bit loaded by 64bit vm; but here, I have 32bit linux, so the
>> vm installed should be 32bit.
>>
>> On Thu, Sep 28, 2017 at 7:40 PM, Herby Vojčík > <mailto:he...@mailbox.sk>
>> <mailto:he...@mailbox.sk <mailto:he...@mailbox.sk>>> wrote:
>>
>>  Hello!
>>
>>  I try to deploy UDBCSQLite-using image in a 32bit ubuntu
>> 16.04.3.
>>
>>  I do have libsqlite3:
>>
>>  root@32bit-agent:~# find / -name '*libsqlite*' -type f
>> 2>>/dev/null
>>  /usr/lib/i386-linux-gnu/libsqlite3.so.0.8.6
>>  /var/lib/dpkg/info/libsqlite0.list
>>  /var/lib/dpkg/info/libsqlite3-0:i386.postinst
>>  /var/lib/dpkg/info/libsqlite3-0:i386.md5sums
>>  /var/lib/dpkg/info/libsqlite3-0:i386.shlibs
>>  /var/lib/dpkg/info/libsqlite0.postrm
>>  /var/lib/dpkg/info/libsqlite3-0:i386.symbols
>>  /var/lib/dpkg/info/libsqlite3-0:i386.list
>>  /var/lib/dpkg/info/libsqlite3-0:i386.triggers
>>  /var/cache/apt/archives/libsqlite0_2.8.17-12fakesync1_i386.
>> deb
>>
>>  but I get this in the output of the CI:
>>
>>  17:16:54.233 + ../pharo/pharo ./filmtower.image
>> conf/run-tests.st <http://run-tests.st>
>> <http://run-tests.st>
>>  17:16:54.508 pthread_setschedparam failed: Operation not
>> permitted
>>  17:16:54.509 This VM uses a separate heartbeat thread to
>> update its
>>  internal clock
>>  17:16:54.509 and handle events.  For best operation, this
>> thread
>&

Re: [Pharo-users] How to set library path for UFFI on Linux?

2017-09-30 Thread p...@highoctane.be
Usually there are a number of names to try but on Linux, there are less
users and more distros, so people are not adding more libs to try.

So, yes, symlink in the plugin directory works usually.

Alternative would be to use LD_LIBRARY_PATH or pkg_config support to do
this cleanly (not done at this point).

Phil

On Sat, Sep 30, 2017 at 11:19 PM, Herby Vojčík  wrote:

> Dan Wilczak wrote:
>
>> Hernan -
>>
>> I haven't opened an issue - how do I do it? (I'm very new to Pharo.)
>>
>> About continuing the search - I only mean continuing the search of the
>> LD_LIBRARY_PATH directories, not the whole filesystem. Two changes would
>> be
>> needed to accomplish this:
>>
>
> FWIW, I had problem with loading 'sqlite3' module. Crossposting the
> solution:
>
> It seems FFI for some reason struggles with 'lib' and/or '.so.0' things in
> linux (even if LD_LIBRARY_PATH is properly set).
>
> I had to do this:
>
> TARGETDIR=`find . -type f -name SqueakSSL.so -print0 | xargs -0 dirname`
> ln -s `/sbin/ldconfig -p | sed -e 's|[^/]*||' | grep sqlite3`
> ${TARGETDIR}/sqlite3.so
>
> (so, link in plugin directory, and the name is plain 'sqlite3.so'). With
> that, things work. Maybe, libsqlite.so would do the trick as well, but I
> got no nerve to play with it more.
>
> But, frankly, do not tell me this is what ppl need to do to load external
> libs in linux. :-/
>
> Herby
>
>
>> 1) Athens-Cairo>>  CairoLibrary would have to return a list of paths to
>> all
>> the matching libraries rather than just the first one that it finds. This
>> part seems easy.
>>
>> 2) UFFI Libraries UnixDynamicLoader>>  loadLibrary:flag: would have to
>> take
>> the list of paths (rather than just one), check them for being 32-bit or
>> 64-bit, and load the first correct one. I can't find any way to perform
>> that
>> check in Pharo directly. How would you fork or exec the "file" command
>> from
>> inside Pharo?
>>
>> Dan
>>
>>
>>
>>
>> --
>> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>>
>>
>
>
>


Re: [Pharo-users] How to make pharo find sqlite?

2017-10-02 Thread p...@highoctane.be
Yes, all of this should work and we need to improve on this.

I am willing to do something about that because it frustrates me too.

Herby,

How would you see it working?

Phil

On Mon, Oct 2, 2017 at 1:45 PM, Herby Vojčík  wrote:

> Renaud de Villemeur wrote:
>
>> Hi
>>
>
> [...snip...]
>
> The reason it pass under windows is because the method library return by
>> default sqlite3, which is the dll name you put under pharo VM directory
>> to get it work.
>>
>
> Not true. It is not in pharo vm directory. It finds it on %PATH%.
>
> On linux, unless you link your library in the VM folder, the image has
>> no clue where to find sqlite3.
>>
>
> And this should be fixed, IMNSHO. It probably _partly_ works, but it
> should be made to work better.
>
> Herby
>
> Hope this helps.
>> Renaud
>>
>
>
> .
>
>
>


Re: [Pharo-users] How to make pharo find sqlite?

2017-10-03 Thread p...@highoctane.be
Nice.

We should make a booklet of all this.

There is also the Ansible playbook we have and the Docker story as well.

Phil


On Tue, Oct 3, 2017 at 3:12 AM, Pierce Ng  wrote:

> On Sat, Sep 30, 2017 at 10:16:47PM +0200, Herby Vojčík wrote:
> > case the library name used is the plain 'sqlite3', I don't know - am
> > I supposed to make a symlink on the same directory as the image? Is
> > it the thing that is normally needed / done routinely?
>
> Below is how I've been doing it since early days of Pharo. Desktop OS =
> Linux
> Mint. Current server OS = Ubuntu 16.04.
>
> Firstly, I don't use the distro-provided libsqlite3.so. My self-built copy
> includes features like FTS, JSON, etc.
>
> I place libsqlite3.so in the VM directory, say /pkg/pharo5vm/. I have a
> script
> /pkg/pharo5vm/gopharo:
>
>   #!/bin/sh
>   PHAROVMPATH=$(dirname `readlink -f "$0"`)
>   LD_LIBRARY_PATH="$PHAROVMPATH" exec "$PHAROVMPATH/pharo" $@ &
>
> On desktop, I start Pharo using gopharo. On server, I use daemontools. Say
> my
> application directory on the server is /pkg/app1. Here's the daemontools
> run
> file /pkg/app1/run:
>
>   #!/bin/sh
>   /usr/bin/setuidgid app1 \
>   /pkg/pharo5vm/gopharo -vm-display-null -vm-sound-null
> smallcms1.image --no-quit
>
> The other files in /pkg/app1 are PharoV*.sources and the application
> image/changes files.
>
> /pkg/pharo5vm contains the pharo executable, vm-*, and the *so*
> files/symlinks
> that come with Pharo plus any others that I custom build myself such as
> libsqlite3.so and libshacrypt.so.
>
> HTH.
>
> Pierce
>
>
>
>


Re: [Pharo-users] Deploying on Linux with LibC version < 2.15

2017-10-05 Thread p...@highoctane.be
CentOS6.9 for one.

Phil

On Thu, Oct 5, 2017 at 11:30 AM, Holger Freyther  wrote:

>
> > On 4. Oct 2017, at 17:39, Cyril Ferlicot 
> wrote:
> >
> > Hi,
> >
> > I am migrating some applications from Pharo 4 to Pharo 6. The new
> > deployment of those applications needs to work on linux with LibC <
> > 2.15. With Pharo 4 there was a special VM[1]. I do not see such VM for
> > Pharo 6.
>
> Which OS has such old versions of LibC? Which LSB standard does it support?
>
>
>


Re: [Pharo-users] Deploying on Linux with LibC version < 2.15

2017-10-05 Thread p...@highoctane.be
Any developer can get a free RHEL license and a dev account for accessing
docs and what not. This includes CVE fixes etc.

CentOS is close but not always the same. e.g. no security fixes are
included vs RHEL when updating (even if the flag is accepted).

I am going next week to the RedHat forum in Breda. I would like to find how
to get Pharo available on RHEL out of the box.

Phil

On Thu, Oct 5, 2017 at 4:29 PM, Holger Freyther  wrote:

>
> > On 5. Oct 2017, at 22:22, Cyril Ferlicot 
> wrote:
> >
> >
>
> > Your instructions describes the steps for CentOS 6.x. Are they the
> > exact same steps for RHEL6?
>
> I don't have a RHEL subscription but I assumed they are similar but
> OBS even produces RHEL packages:
>
> https://download.opensuse.org/repositories/devel:/languages:
> /pharo:/stable/RHEL_6/
>
>
>
> > Also, I am trying this on a CentOS 6.0 virtual machine and I get this
> error :
> >
> > [centoslive@livecd test]$ yum-config-manager --add-repo
> > http://download.opensuse.org/repositories/devel:/languages:
> /pharo:/latest/CentOS_6/devel:languages:pharo:latest.repo
> > Loaded plugins: fastestmirror, refresh-packagekit
> > Usage: "yum-config-manager [options] [section]
> >
> > Command line error: no such option: --add-repo
> > [centoslive@livecd test]$
> >
> >
> > Is there something else to install before?
>
> Not sure. Even the RHEL documentation mentions --add-repo exists. I assume
> you can download the .repo[1] file and put it in the right directory?
>
>
> holger
>
>
>
>
> [1]
> RHEL6:
> https://download.opensuse.org/repositories/devel:/languages:
> /pharo:/stable/RHEL_6/devel:languages:pharo:stable.repo
>
> CentOS6:
> https://download.opensuse.org/repositories/devel:/languages:
> /pharo:/stable/CentOS_6/devel:languages:pharo:stable.repo
>
>


Re: [Pharo-users] Embeddable Smalltalk (was: Re: Behold Pharo: The Modern Smalltalk)

2017-10-07 Thread p...@highoctane.be
https://github.com/guillep/Scale is quite cool for quick scripts on *nix.

Now for embeddable, yes it would help. Bootstrapping will be helpful but
the current main issue is the VM interpret loop that is in the current VMs.

It is not an intrinsic problem. Telepharo is also a great step to enable
that to exist.

Phil

On Oct 7, 2017 13:05, "Herby Vojčík"  wrote:

Ben Coman wrote:

> Nice article. I like the way you've structured it and pushed the
> "updated" angle.
>
> I feel a bit too strong a claim is laid on Pharo producing the CogVM.
> Much of the Cog + Spur + 64bit VM work was originally done for Squeak
> with Pharo riding the coat-tails of that work.  Lately Pharo community
> has been involved in improving VM with hotspot optimisation with Sista
> and moving towards making Pharo embeddable.. (@Clement, is "hotspot
>

Hi, this made me curious. I always had the problem with Amber (and, all the
rest of Smalltalks in similar vein) that it is hard to use to one-off
scripting, as it presumes existence of the not really small class library
(objects, classes, collections, etc.). This disadvantaged it IMO in the
field of "can I just embed it here and script it with a few lines?"
scenarios.

Did you (the Pharo community that is "moving towards making Pharo
embeddable") find some way to work this around?

cheers -ben
>

Herby


Re: [Pharo-users] Deploying on Linux with LibC version < 2.15

2017-10-07 Thread p...@highoctane.be
I would rather qualify Ubuntu as hell when deploying large setups of
machines that have to be kept in working order for a long while.

We should give top notch support for RHEL if we want to be relevant in
spaces like Hadoop for example as the reference platform is RHEL/CentOS.

Phil


On Oct 6, 2017 16:20, "Andrew Glynn"  wrote:

> There's a reason it's referred to by numerous developers as R-HELL.
>
> Andrew Glynn
>
> -Original Message-
>
> *Date*: Thu, 5 Oct 2017 21:46:20 +0800
> *Subject*: Re: [Pharo-users] Deploying on Linux with LibC version < 2.15
> *To*: bruce.on...@pckswarms.ch, Any question about pharo is welcome <
> pharo-users@lists.pharo.org
> 
> >
> Reply-to: Any question about pharo is welcome  >
> *From*: Holger Freyther  >
>
>
> On 5. Oct 2017, at 18:08, Bruce O'Neel  wrote:
>
> Hi,
>
>
>
> Hi!
>
>
>
>
> Well, our redhat 6.9 systems have 2.12, so, that qualifies.
>
> And yes, we still have RedHat 6, and 6.9 was released only 6 months ago!  It 
> will finish extended support in a mind-blowing 7 more years in 2024.
>
> Redhat 5, still supported for another 3 years till 2020 has glibc 2.5.
>
>
>
>
> for a brief moment you really scared me. I thought you referred to RedHat 
> Linux 6 which was released in 1999 but you are referring to Red Hat 
> Enterprise Linux (RHEL).
>
> As it turns out we have "latest" (as soon as a commit is made to 
> pharo-vm.git) and hand curated "stable" (hand created source tarballs, 
> rebuilt from a git commit of opensmalltalk-vm) for RHEL6 and CentOS 6.
>
> CentOS 6.x:
>
> # Add the repo
> $ yum-config-manager --add-repo 
> http://download.opensuse.org/repositories/devel:/languages:/pharo:/latest/CentOS_6/devel:languages:pharo:latest.repo
>
> OR (for stable):
> http://download.opensuse.org/repositories/devel:/languages:/pharo:/latest/CentOS_6/devel:languages:pharo:stable.repo
>
> # Install 32bit packages (with X11 dependency for *-ui or not)
>
> $ yum install pharo6-32-ui.i686 or pharo6-32.i386
>
> # Install 64bit packages
>
> $ yum install pharo6-64-ui.x86_64 pharo6-64.x86_64
>
>
>
>
>
>
>


Re: [Pharo-users] How to make pharo find sqlite?

2017-10-08 Thread p...@highoctane.be
Oh my, am doing too much Windows at the moment.

Phil

On Sat, Oct 7, 2017 at 11:47 PM, Alistair Grant 
wrote:

> On Sat, Sep 30, 2017 at 01:28:06PM +0200, Herby Vojk wrote:
> > p...@highoctane.be wrote:
> > >What about
> > >
> > >LD_LIBRARY_PATH=;$LD_LIBRARYPATH  ./pharo-ui some.image
> > >
> > >Phil
> >
> > Thanks for answer, did not help.
> >
> > In fact it must be something different. As can be seen in the stack, it
> > fails during finalizers, and as can be seen by looking at
> > UDBCSQLite3DatabaseExternalObject class>>finalizeResourceData: code, the
> > method it calls is sqlite close. It is hardly the first method that is
> > should call...
> >
> > I suspect something around image save / load. Again. Lots of errors in
> those
> > parts. But may be something else, as it kicks in only when SQLite-using
> > tests starts to run. :-(
> >
> > Herby
> >
> > P.S.: I saw there is a similar thread out there, but it has problems with
> > 32bit loaded by 64bit vm; but here, I have 32bit linux, so the vm
> installed
> > should be 32bit.
>
>
> Sorry I'm a bit late to the party...
>
> I'm using Glorp / UDBCSQLite3 on Ubuntu 16.04 without any problems
> (admittedly 64 bit Ubuntu, but as you say, that shouldn't matter).
>
> Just in case you copy-and-pasted the code, Phil's example has a typo:
> the path separator is a colon (:), not semicolon (;).
>
> Install libsqlite3-dev and adding /usr/lib/i386-linux-gnu to
> LD_LIBRARY_PATH is all I had to do to get it to work (no changes to
> UDBCSQLite3Library>>library).  Actually LD_LIBRARY_PATH normally
> shouldn't be required, but I'm running inside a snap container, which is
> an unusual environment.
>
>
>
> > root@32bit-agent:~# find / -name '*libsqlite*' -type f
> 2>>/dev/null
> > /usr/lib/i386-linux-gnu/libsqlite3.so.0.8.6
>
> It seems strange that there isn't libsqlite3.so.  I think the real
> solution would be to find out why libsqlite3.so doesn't exist, but after
> installing libsqlite3-dev, a workaround would be to try creating a
> symbolic link from libsqlite3.so.0.8.6 to libsqlite3.so.
>
>
>
> Cheers,
> Alistair
>
>
>


Re: [Pharo-users] Behold Pharo: The Modern Smalltalk

2017-10-10 Thread p...@highoctane.be
A Bluebook updated picture would be great. And I am sure Roassal could
produce it right away.

Phil

On Oct 10, 2017 15:58, "horrido"  wrote:

> Interestingly, I'm getting a fair amount of pushback on this. Personally, I
> think it would be very helpful to have a live (updatable, so as to keep it
> current) reference page for the class library, something that developers
> can
> easily look up what they need. After all, most of the power of Pharo comes
> from the class library and we need to make it as accessible as possible to
> less experienced Pharoers (i.e., beginners).
>
> Exploring the class library through the System Browser is very inefficient.
> This is further exacerbated by the fact that many classes and methods are
> simply not well-documented (containing a cursory remark which is just
> barely
> useful).
>
> I realize that creating a live reference page is not easy to do. In fact,
> it's a lot of work. But the absence of such a page is a real obstacle to
> Pharo acceptance.
>
>
>
> horrido wrote
> > Thanks. I gave your answer verbatim. I also added the following
> paragraph:
> >
> > The problem I find with today’s developers is that they are rather
> > closed-minded. They are rigid and inflexible, and not willing to adapt to
> > new and different ways of doing things. In my generation (circa
> > 1980–1990),
> > people didn’t have a problem with trying different technologies. That’s
> > why
> > I had no issue with learning Smalltalk 10 years ago, after I had retired
> > from a 20-year-long career in C systems programming and FORTRAN
> scientific
> > programming.
> >
> >
> >
> > Sven Van Caekenberghe-2 wrote
> >>> On 6 Oct 2017, at 14:54, horrido <
> >
> >> horrido.hobbies@
> >
> >> > wrote:
> >>>
> >>> I received this comment from someone who complained:
> >>>
> >>> *What about the lack of documentation? From time to time I’ve checked
> >>> some
> >>> SmallTalk implementations like Squeak, GNU-Smalltalk and now Pharo. Of
> >>> these, only GNU-SmallTalk appears to have a free, official programming
> >>> guide
> >>> and core library reference that any serious programmer expects from a
> >>> language.
> >>>
> >>> https://www.gnu.org/software/smalltalk/manual-base/html_node/*
> >>>
> >>> I pointed to Pharo's documentation but then he came back with:
> >>>
> >>> *Then show me a link of the free, maintained reference documentation
> for
> >>> the
> >>> classes that form “the core library”, like this one for Python
> >>> (https://docs.python.org/3/library/index.html)*
> >>>
> >>> It's true, most Smalltalks do not have a core library reference, not
> >>> even
> >>> VisualWorks! So what is the proper response to this complaint?
> >>
> >> The first answer is that Pharo/Smalltalk is unique in that a running
> >> system/IDE contains _all_ source code, _all_ documentation (class,
> >> method,
> >> help, tutorial), _all_ unit tests and _all_ runnable examples in a very
> >> easy, accessible way. It takes some getting used to, but this is
> actually
> >> better and much more powerful than any alternative.
> >>
> >> The second answer is that there are lots of books and articles that take
> >> the classic/structured book/paper approach. There is
> >> http://books.pharo.org, http://themoosebook.org,
> >> http://book.seaside.st/book, http://medium.com/concerning-pharo and
> many
> >> more.
> >>
> >>> Thanks.
> >>>
> >>>
> >>>
> >>> --
> >>> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
> >>>
> >
> >
> >
> >
> >
> > --
> > Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>
>
>
>
>
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>
>
>


[Pharo-users] Music beat detection and 60FPS graphics on Pharo?

2017-10-14 Thread p...@highoctane.be
I'd like to do something like this:
https://www.youtube.com/watch?v=vL7D4eU0lYE

to showcase FFI, Bloc, and the Pharo liveliness.

And once I get the basics working, level up in getting it working in a VR
headset.

Is there anyone having a binding to a library for dealing with the sound
part, like FMod or other things like that?

I see this as a medium term project, so, like I can get it working by the
end of the year.

TIA

Phil


Re: [Pharo-users] Music beat detection and 60FPS graphics on Pharo?

2017-10-14 Thread p...@highoctane.be
Thanks, I'll try that out!

Phil

On Sat, Oct 14, 2017 at 5:36 PM, Clément Bera 
wrote:

> Hi Phil,
>
> I did that using Ronie's OpenAL binding and Merwann's wav parser back in
> 2014-2015:
>
> MCSmalltalkhubRepository
> owner: 'ronsaldo'
> project: 'OpenAL'
>
> MCSmalltalkhubRepository
> owner: 'MerwanOuddane'
> project: 'WAVParser'
>
> I did things such as (build yourself something derived from this code I
> did not check if it works):
>
> MyClass>>example
> WAVParser wavFromStream: ('resources/music/spellNoise.wav'
> asFileReference readStream binary readStream).
> contextAttributes := ALContextAttributes new.
> device := OpenALC openDefaultDevice.
> context := device createContext: contextAttributes asList.
> context process.
> context currentDuring: [
> "Create the buffer"
> buffer := self makeBufferFromHeader: wav header data: wav data asByteArray.
> "Create the source"
> source := OpenAL genSource.
> OpenAL sourcei: source param: AL_BUFFER value: buffer.
> "Play the source"
> OpenAL sourcePlay: source.
> "Play for sometime "
> (Delay forSeconds: wav header soundDuration) wait.
> "Delete the source and the buffer"
> OpenAL deleteSource: source;
> deleteBuffer: buffer
> ].
> OpenALC nullCurrentContext.
> context destroy.
> device close.
>
> MyClass>>makeBufferFromHeader: header data: data
> | buffer |
> buffer := OpenAL genBuffer.
> OpenAL bufferData: buffer format: (self readFormatFromHeader: header)
> data: data size: data size freq: header sampleRate.
> ^ buffer
>
> MyClass>>readFormatFromHeader: header
> ^ header channels = 1
> ifTrue: [
> header bitsPerSample = 8
> ifTrue: [ AL_FORMAT_MONO8 ]
> ifFalse: [ AL_FORMAT_MONO16 ] ]
> ifFalse: [
> header bitsPerSample = 8
> ifTrue: [ AL_FORMAT_STEREO8 ]
> ifFalse: [ AL_FORMAT_STEREO16 ] ]
>
> I am pretty sure with a little work those things could work again. I have
> never succeeded in playing mp3 files from Pharo though (but I'm on mac and
> I remembered trying solutions that did not work on Mac but may work on
> other OS).
>
> Have fun guys :-)
>
> On Sat, Oct 14, 2017 at 10:01 AM, p...@highoctane.be 
> wrote:
>
>> I'd like to do something like this: https://www.youtube.com/
>> watch?v=vL7D4eU0lYE
>>
>> to showcase FFI, Bloc, and the Pharo liveliness.
>>
>> And once I get the basics working, level up in getting it working in a VR
>> headset.
>>
>> Is there anyone having a binding to a library for dealing with the sound
>> part, like FMod or other things like that?
>>
>> I see this as a medium term project, so, like I can get it working by the
>> end of the year.
>>
>> TIA
>>
>> Phil
>>
>
>
>
> --
> Clément Béra
> Pharo consortium engineer
> https://clementbera.wordpress.com/
> Bâtiment B 40, avenue Halley 59650
> <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve+d'Ascq&entry=gmail&source=g>Villeneuve
> d
> <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve+d'Ascq&entry=gmail&source=g>
> 'Ascq
> <https://maps.google.com/?q=40,+avenue+Halley+59650%C2%A0Villeneuve+d'Ascq&entry=gmail&source=g>
>


Re: [Pharo-users] UFFI with asynchronous callbacks

2017-10-23 Thread p...@highoctane.be
I've callbacks all over in https://github.com/Pharophile/XmppTalk

They do work.

Phil

On Mon, Oct 23, 2017 at 8:13 PM, Ben Coman  wrote:

>
>
> On Mon, Oct 23, 2017 at 11:46 PM, Jan Cada  wrote:
>
>> Hi,
>>
>> I would like to connect fingerprint reader to pharo - so far I am able to
>> use C library to connect to it using UFFI,
>> however the problem is that I can wait for fingerprint indefinitely (
>> blocking call to library) or register call-back for moment when fingerprint
>> is available.
>> The registration function returns immediately, so it is clear that the
>> callback will be called from another thread.
>>
>> Is such situation supported by UFFI ?
>>
>> Thanks for any tip,
>>
>> Jan
>>
>
> Callbacks are supported. Here is an example...
> http://blog.openinworld.com/2016/09/pharo-libclang-ffi-
> part-4-ast-walking-with-visitors-callbacks/
>
> @Todd, How did find working through this part?
> cheers -ben
>


Re: [Pharo-users] Smalltalk Argument

2017-10-25 Thread p...@highoctane.be
I like that piece a lot, seeing exactly the described situation in large
enterprises.

I made a strategic decision to go with Pharo for the long run for my
solutions because it is a stable base on which to build (ok, there are
evolutions, but fundamentally, I can rely on it being under control and can
maintain solutions in a version).

The rationale is that at a deep level I am really fed up with having to
deal with accidental complexity (now having to deal with
Spark/Scala/sbt/Java/maven stuff) that makes the dev focus 80% technology
drag and 20% net business contribution.

One key thing is that a team needs guidance and Smalltalk makes it easier
due to well known ways of doing things.

Now we miss the boat on mobile and bigdata, but this is solvable.

If we had an open Java bridge (and some people in the community have it for
Pharo but do not open source it - so this is eminently doable) + Pharo as
an embeddable piece (e.g. like Tcl and Lua) and not a big executable we
would have a way to embed Pharo in a lot of places (e.g. in the Hadoop
ecosystem where fast starting VMs and small footprint would make the
cluster capacity x2 or x3 vs uberjars all over the place)  this would be a
real disruption.

Think about being able to call Pharo from JNA
https://github.com/java-native-access/jna the same way we use C with UFFI.

Smalltalk argument for me is that it makes development bearable (even fun
and enjoyable would I say) vs the other stacks. That matters.

Phil








On Thu, Oct 26, 2017 at 12:46 AM, Andrew Glynn  wrote:

> There’s other questions that are relevant to me:
>
>
>
> Do I give a f*** about cool looking web apps?  No, I don’t use web apps if
> in any way I can avoid it.
>
>
>
> Do I give a f*** about mobile apps?  No, the screen’s too small to read
> anything longer than a twit, or anyone with anything worthwhile to say.
>
>
>
> Do I give a f*** about the number of libraries in other languages?  No,
> because most of them are crap in every language I’ve had to work in, and
> the base languages are crap so they have to keep changing radically, and
> libraries and frameworks therefore also have to and never get any better.
> The few that are worthwhile I can almost always use from Smalltalk without
> a problem (read, Blender, ACT-R and Synapse, since every other
> library/framework I’ve used outside Smalltalk has been a waste of time).
>
>
>
> Do I give a f*** about implementing a complex piece of machine learning
> software in 22 hours, compared to 3 months for the Java version?  Well,
> actually yes, I do, because that was 3 months of my life down the toilet
> for something that is too slow to be useful in Java.
>
>
>
> Any argument depends on your priorities. I’ve written tons of web apps,
> because I needed to get paid.  I’ve written better shitty mobile apps than
> the average shitty mobile apps.  However, I’m not going to do any of that
> any longer in crap that never improves, because after 26 years the
> irritability it produces is more than it’s worth.
>
>
>
> A few weeks ago, a recruiter that specializes in Smalltalk called me about
> a job, although they were well aware I live 1500 miles away from the city I
> lived in when I had worked through them, to see if I’d be willing to move
> back there for a job.  That sounds like another ‘there aren’t enough
> Smalltalk developers”, but it wasn’t, because the job wasn’t writing
> Smalltalk.  It was writing Java.
>
>
>
> The person hiring, though, wouldn’t look at anyone who didn’t write
> Smalltalk, because “people who grew up with Java don’t know how to write
> code”.  I don’t agree with that, I’ve known a (very few) good Java
> developers.  I would say, though, that I’ve known far more incompetent ones
> than good ones, and I can’t think of any incompetent Smalltalk developers
> off the top of my head.
>
>
>
> Nor have I ever heard a developer in Smalltalk, or Haskell, or LISP, or
> even C, complain about how hard maintaining state is or coming up with
> various hacks to avoid it, which seems to be the main point of every
> JavaScript based ‘technology’.  An application is by definition a
> state-machine, which implies plenty about JS developers on the whole.
>
>
>
> If you’re a good developer you can write good code in (nearly) anything.
> My question then is why would you want to write in crap?  The better
> question is why aren’t there more good developers in *any* language?
>
>
>
> Every project I have been able to do in Smalltalk, though, has had one
> thing in common, the “shit has to work”.  Companies do use it, in fact I
> could name 4 large enterprises I’ve worked for who’ve written their own
> dialects, and they all use it only when “shit has to work”.  They know it’s
> more productive, they also know using it for more things would increase the
> availability of Smalltalk developers.
>
>
>
> Why do they not do it?  One reason, though it takes a while to recognize
> it, because management doesn’t admit even to themselves why they d

Re: [Pharo-users] Smalltalk Argument

2017-10-26 Thread p...@highoctane.be
Sure. Current main issue is to have Pharo work with Kerberos as secured
Hadoop uses the UGI (UserGroupInformation) thing and that is a black hole
of crypto things.

How would you see ParrotTalk work?

I made a XmppTalk thing (binding for libstrophe) for having Pharo images
and other stuff talk together (currently using OpenFire/Gajim/Profanity)
FWIW

See
https://docs.google.com/presentation/d/1HTG3GB3xdwlje8wADZPjUQNIyA6tmuxyZz1UaX5ikEU/edit?usp=sharing

libstrophe does the SSL thing under the hood (using OpenSSL) and is
actively maintained.
https://github.com/strophe/libstrophe/blob/master/src/tls_openssl.c

And I currently work with Kafka so, Pharo as a consumer or producer, sure
am interested. But need Kerberos support.

Tell me more about your vision. Even better, draw it in some way :-)

Phil


On Thu, Oct 26, 2017 at 8:43 AM, henry  wrote:

> This is a goal of ParrotTalk, to bring bit-compatible communications to
> Squeak, Pharo and Java. This is not an invocation bridge you speak of but a
> communications bridge to be able to run against Hadoop or whichever big
> data needs integration with (Kafka). I had hoped it might be adopted for
> such. Yet again this is not exactly what you were looking for but yet
> interesting perhaps?
>
>
> - HH
>
>
> On Thu, Oct 26, 2017 at 02:17, p...@highoctane.be 
> wrote:
>
> I like that piece a lot, seeing exactly the described situation in large
> enterprises.
>
> I made a strategic decision to go with Pharo for the long run for my
> solutions because it is a stable base on which to build (ok, there are
> evolutions, but fundamentally, I can rely on it being under control and can
> maintain solutions in a version).
>
> The rationale is that at a deep level I am really fed up with having to
> deal with accidental complexity (now having to deal with
> Spark/Scala/sbt/Java/maven stuff) that makes the dev focus 80% technology
> drag and 20% net business contribution.
>
> One key thing is that a team needs guidance and Smalltalk makes it easier
> due to well known ways of doing things.
>
> Now we miss the boat on mobile and bigdata, but this is solvable.
>
> If we had an open Java bridge (and some people in the community have it
> for Pharo but do not open source it - so this is eminently doable) + Pharo
> as an embeddable piece (e.g. like Tcl and Lua) and not a big executable we
> would have a way to embed Pharo in a lot of places (e.g. in the Hadoop
> ecosystem where fast starting VMs and small footprint would make the
> cluster capacity x2 or x3 vs uberjars all over the place)  this would be a
> real disruption.
>
> Think about being able to call Pharo from JNA https://github.com/java-
> native-access/jna the same way we use C with UFFI.
>
> Smalltalk argument for me is that it makes development bearable (even fun
> and enjoyable would I say) vs the other stacks. That matters.
>
> Phil
>
>
>
>
>
>
>
>
> On Thu, Oct 26, 2017 at 12:46 AM, Andrew Glynn 
> wrote:
>
> There’s other questions that are relevant to me:
>
>
>
> Do I give a f*** about cool looking web apps?  No, I don’t use web apps if
> in any way I can avoid it.
>
>
>
> Do I give a f*** about mobile apps?  No, the screen’s too small to read
> anything longer than a twit, or anyone with anything worthwhile to say.
>
>
>
> Do I give a f*** about the number of libraries in other languages?  No,
> because most of them are crap in every language I’ve had to work in, and
> the base languages are crap so they have to keep changing radically, and
> libraries and frameworks therefore also have to and never get any better.
> The few that are worthwhile I can almost always use from Smalltalk without
> a problem (read, Blender, ACT-R and Synapse, since every other
> library/framework I’ve used outside Smalltalk has been a waste of time).
>
>
>
> Do I give a f*** about implementing a complex piece of machine learning
> software in 22 hours, compared to 3 months for the Java version?  Well,
> actually yes, I do, because that was 3 months of my life down the toilet
> for something that is too slow to be useful in Java.
>
>
>
> Any argument depends on your priorities. I’ve written tons of web apps,
> because I needed to get paid.  I’ve written better shitty mobile apps than
> the average shitty mobile apps.  However, I’m not going to do any of that
> any longer in crap that never improves, because after 26 years the
> irritability it produces is more than it’s worth.
>
>
>
> A few weeks ago, a recruiter that specializes in Smalltalk called me about
> a job, although they were well aware I live 1500 miles away from the city I
> lived in when I had worked through them, to see if I’d be willing to move
> back there for a job. 

Re: [Pharo-users] Smalltalk Argument

2017-10-26 Thread p...@highoctane.be
There are two key Kerberos implementations one can use with Hadoop.

One is the FreeIpa/RedHat IdM.
The other is ActiveDirectory.

I am using FreeIPA which bundles MIT Kerberos/389/sssd and more for making
a CA etc. Works wonderfullý well.

AD is well ... part of the corporate landdscape.

Most of Kerberos needs are done with Java in Hadoop. But details are buried
in private Sun classes..

Google Madness beyond the gate hadoop for some Lovecraftian quotes
describing the situation along educated info.

Phil

On Thu, Oct 26, 2017 at 6:23 PM, henry  wrote:

> I have no idea which is best. For being able to say we use industry
> standard Kerberos, calling an accepted implementation seems wise, like
> OpenSSL support.
>
> - HH
>
>
> On Thu, Oct 26, 2017 at 11:39, Paulo R. Dellani  wrote:
>
> This all sounds very interesting. What is the idea? Wrap libkrb5 through
> UFFI or implement it in Smalltalk?
>
> On 10/26/2017 04:38 PM, henry wrote:
>
> A Kerberos effort will have to be a group effort. Sideways to my main
> focus and your all’s main focii.
>
>
> - HH
>
>
> On Thu, Oct 26, 2017 at 09:15, henry  wrote:
>
> I think another good service to integrate well to is Elastic Search.
>
> Of the 4 types of integration, I vote for and step forward to volunteer to
> help Kerberos integration in Pharo. What to do?
>
>
> - HH
>
>
> On Thu, Oct 26, 2017 at 09:06, henry  wrote:
>
> I try posting with a smaller image.
>
> [image: ""hubbub.jpg""]
>
> - HH
>
>
> ——— Original Message ———
> Subject: Re: [Pharo-users] Smalltalk Argument
> Local Time: October 26, 2017 8:52 AM
> UTC Time: October 26, 2017 12:52 PM
> From: he...@callistohouse.club
> To: p...@highoctane.be  , Any
> question about pharo is welcome 
> 
>
> Perhaps not, or not yet. Perhaps it is the communications foundation for
> an always-on cloud/bigData control layer.
>
> I would position ParrotTalk as a Kerberos transport. ParrotTalk does
> 2048-bin key negotiation and subsequent encryption/encoding, both
> user-supplied.
>
> Please see the attached diagram, co-locating ParrotTalk with my other
> components.
>
> ParrotTalk does not do user authentication/authorization. Which means to
> me that I should consider Kerberos authorization/authentication to
> establish as an integratable transport to play in bigData.
>
> This means you still need a Kerberos client and I need a Kerberos client.
> How do we start?
>
> - HH
>
> PS: I did much work integrating Kafka into a framework. I was thinking of
> inserting msg sending replication to a partition count of replicate queues
> for sending and receiving Hubbub traffic, thus inserting right where
> Kerberos is in the diagram. I would love to see client coupling for
> Kerberos, Kafka and Hadoop, while I figure out proper security to make that
> group happy with this as a possible control layer solution, forking off
> jobs.
>
>
> On Thu, Oct 26, 2017 at 03:14, p...@highoctane.be 
> wrote:
>
> Sure. Current main issue is to have Pharo work with Kerberos as secured
> Hadoop uses the UGI (UserGroupInformation) thing and that is a black hole
> of crypto things.
>
> How would you see ParrotTalk work?
>
> I made a XmppTalk thing (binding for libstrophe) for having Pharo images
> and other stuff talk together (currently using OpenFire/Gajim/Profanity)
> FWIW
>
> See https://docs.google.com/presentation/d/1HTG3GB3xdwlje8wADZPjUQNIyA6tm
> uxyZz1UaX5ikEU/edit?usp=sharing
>
> libstrophe does the SSL thing under the hood (using OpenSSL) and is
> actively maintained.
> https://github.com/strophe/libstrophe/blob/master/src/tls_openssl.c
>
> And I currently work with Kafka so, Pharo as a consumer or producer, sure
> am interested. But need Kerberos support.
>
> Tell me more about your vision. Even better, draw it in some way :-)
>
> Phil
>
>
> On Thu, Oct 26, 2017 at 8:43 AM, henry  wrote:
>
> This is a goal of ParrotTalk, to bring bit-compatible communications to
> Squeak, Pharo and Java. This is not an invocation bridge you speak of but a
> communications bridge to be able to run against Hadoop or whichever big
> data needs integration with (Kafka). I had hoped it might be adopted for
> such. Yet again this is not exactly what you were looking for but yet
> interesting perhaps?
>
>
> - HH
>
>
> On Thu, Oct 26, 2017 at 02:17, p...@highoctane.be < p...@highoctane.be>
> wrote:
>
> I like that piece a lot, seeing exactly the described situation in large
> enterprises.
>
> I made a strategic decision to go with Pharo for the long run for my
> solutions because it is a stable base on which to build (ok, there are
> evolutions, but fundament

Re: [Pharo-users] Smalltalk Argument

2017-10-29 Thread p...@highoctane.be
Pharo can read Avro when this will be UFFI'ed

https://avro.apache.org/docs/1.7.3/api/c/index.html

But that is eminently doable.

Phiil

On Sun, Oct 29, 2017 at 7:13 PM, henry  wrote:

> I have heard this summarized by the term: "build it and they will come". I
> think the data visualization aspect is where Pharo entering BigData space
> could really payoff. That comes down to data manipulation. Can Pharo read
> Avro?
>
> - HH
>
>
> On Sun, Oct 29, 2017 at 14:00, Offray Vladimir Luna Cárdenas <
> offray.l...@mutabit.com> wrote:
>
> Thanks a lot Paulo for starting this thread and all the participants for
> the clever and enlightening answers. I just want to add my two cents. On
> 26/10/17 07:53, Dimitris Chloupis wrote: > > My personal opinion is that as
> pessimistic it may sound, Smalltalk has > very little to offer in the
> library front. The language is still > stellar and live environment is a
> great concept but from there on > there is a decline. Sure if your are low
> demand kind of person on the > library front and dont mind implementing
> stuff by yourself you wont > mind the lack of libraries but most coders ,
> me included , dont have > this luxury. Especially making a living with a
> language is a > completely different story from learning it as a hobby,  >
> > I think and that's a personal opinion, that Smalltalk goes the wrong >
> direction. It tries to be a do it all language, but we already have an >
> army of do it all languages. I think it would excel as the backbone in >
> big complex projects. Like the Moose project is doing with code > analysis
> and visualization. I think this is an excellent direction to > go with
> Smalltalk. Reflection is the big strength of Smalltalk the > ability to
> communicate with its code in a direct matter. So I think > that a Smalltalk
> implementation that can analyze and visualize code > written in other
> languages would have been a pretty serious reason for > people to learn
> Smalltalk.  > > I am very happy to see Pharo go towards that direction and
> yes I would > definitely recommend it without hesitation  for code analysis
> and > project management tool. Its no coincidence that we have seen a >
> serious growth in our community. When I joined back in 2011 we all > were
> posting at pharo-dev, pharo-users was a dead zone and then the > community
> grow larger and larger we soon may need a third mailing list.  > > Code
> complexity is an issues for all large projects and tools that > help manage
> this without having to convert to another language are > very popular.
> About finding  niche where you can learn Pharo and make a living from it, I
> think that I may be behind a sweet spot in the field of reproducible
> research and data storytelling and visualization, for different fields like
> activism, journalism, science and engineering. I'm "working in my PhD", so
> I don't get paid for using Pharo & friends (well if fact I'm in a loan to
> finish my PhD), but using Pharo have allowed my to get more dynamic results
> that with previous technologies (mostly Python and Web ones). By being able
> to prototype quickly I have improved my research experience and results,
> which is a way to improve research (self) funding. Also, activists,
> journalist, researchers and other novices interested in data storytelling
> and visualization, care little about popularity of the language or being
> able to make apps (mobile or web). What they care is about being able to
> tell the story and Pharo, agile visualization and moldable tools, have a
> lot to offer in this front. They're easy to learn and to adapt to fit the
> needs of the problems behind those stories, as we have done with
> Grafoscopio[1]. So, is nice to be part of a "trend", (data science,
> reproducible research, data storytelling and data visualization) but not
> being part of one that doesn't give you the freedom to use tools that
> matter to you, because of the ideas they embody and the added value they
> create for you and your community. [1] http://mutabit.com/
> grafoscopio/index.en.html Also, being in Latin America, means that we can
> bootstrap ourselves into alternative futures by using alternative (digital)
> infrastructures and tools, without to much worry about the deep investments
> in money and/or expertise on bloated/popular technologies (we don't have
> such investments here!). We can learn from the experience of the "Global
> North", without following that path, but by taking a critical approach to
> it (for example regarding overcomplex, non-dynamic, bloated technologies).
> On the community front, I think is important to do something to break the
> circular logic of popularity: Smalltalk is unpopular, so we don't get
> developers, so we don't have libraries, and this makes such tech unpopular.
> We're a nascent community of data storytellers and activists learning how
> to use Pharo to tell our voices and how to modify the tools to tell them in
> more potent/fluid ways. We have d

[Pharo-users] DDD (Domain Driven Design) framework

2017-11-23 Thread p...@highoctane.be
I saw in a success story (http://pharo.org/success/Contestia) that a DDD
framework was created and used.

Is there any way to have it available in some form? No need for it to be
open source.

I am writing code for a specific domain where Pharo can really shine due to
the exploratory nature of the domain.

DDD is an important aspect of the project and if I can avoid reinventing
the wheel, that would be awesome.

The current alternative to Pharo is with PHP and ZendFramework + Prooph
http://getprooph.org/

Needless to say, I'd be happier with Pharo (even if the PHP stack is very
capable and proved itself in battle).

Phil


Re: [Pharo-users] Travis build failing because of bad CRC

2017-11-24 Thread p...@highoctane.be
Same issues for me.

I actually use an older thing that I know works instead of using zeroconf
etc anymore.

Others may just walk away from Pharo silently.

Look in an age of Docker and multi gig successful downloads, a couple megs
sjouldn't be that hard.

S3 or whatever works for millions of podcasts, BinTray also works nicely
etc.

Shouldn't some consortium money channeled in there?

Phil


On Fri, Nov 24, 2017 at 3:24 AM, Ben Coman  wrote:

> On 23 November 2017 at 20:18, Christophe Demarey <
> christophe.dema...@inria.fr> wrote:
>
>>
>> > Le 23 nov. 2017 à 12:34, Norbert Hartl  a écrit :
>> >
>> >
>> >
>> >> Am 23.11.2017 um 11:39 schrieb Christophe Demarey <
>> christophe.dema...@inria.fr>:
>> >>
>> >> Hi Norbert,
>> >>
>> >> I understand your point of view that others probably share.
>> >> I also agree the situation is very bad: Inria took too much time to
>> investigate the problem and now, renater also …
>> >> The question is: would it be really better outside Inria? Maybe ...
>> maybe not …
>> >
>> > Maybe that is the point. It is not a question if it works better
>> outside because it will. The problem we have is so serious that it will be
>> hard to find elsewhere. I can only repeat: It is not the download that
>> fails which TCP wise means that exactly the thing is downloaded that inria
>> offered. So something below the web server is broken and most probably they
>> have a corrupt storage solution meaning only if you give it broken to the
>> web server the broken thing can be transported in a sane manner.
>>
>> I’m not confident with the diagnostic.
>> I never encountered this problem
>
>
>
> The problem seems geo-specific.  So you may never personally observe the
> problem.  Of course that can make it near-impossible for  yourself to
> troubleshoot.
> So consider the engineering principal...  "If you can't solve the problem,
> change the problem."
>
>
> cheers -ben
>


Re: [Pharo-users] I love the launcher!!!!

2017-11-26 Thread p...@highoctane.be
So, I try it on my CentOS 7 64 bit and... as there is no 64 bit version of
the launcher...

pharo6-64-ui PharoLauncher.image
This interpreter (vers. 68021) cannot read image file (vers. 6521).
Press CR to quit...

How is one using the launcher for 64 bit stuff?

Phil

On Sun, Nov 26, 2017 at 9:45 PM, Stephane Ducasse 
wrote:

> If you don't try you will not understand what you miss.
>
> On Sun, Nov 26, 2017 at 2:10 PM, Herby Vojčík  wrote:
> > Stephane Ducasse wrote:
> >>
> >> Then do not try :) like that you will never get a chance to know :)
> >
> >
> > Could you please explain? I understood your sentence has high dose of
> homour
> > which I cannot decipher since I lack certain abilities for that.
> >
> > Thanks, Herby
> >
> >> Stef
> >>
> >>
> >> On Sun, Nov 26, 2017 at 1:48 PM, Herby Vojčík  wrote:
> >>>
> >>> Stephane Ducasse wrote:
> 
>  Why don't you try? It does not bite.
> 
>  For me it works in all scenario. I have projects that i manage over
>  several weeks and others I drop day to day.
>  And I have also startup script per versions.
> >>>
> >>>
> >>> Maybe I will. The main problem was I didn't what it's good about at
> all -
> >>> load image for a version, runs it - what's the "wow it's great" about?
> >>> Missed part was it loads correct vm; plus makes sense when you have
> >>> hundreds
> >>> (I don't). Now it must be combined with the startup script magic to
> work
> >>> with long-time projects, but those are also new to me - did not know of
> >>> them
> >>> until your booklet, not using them at all yet.
> >>>
> >>> Herby
> >>>
> >>>
>  Stef
> 
>  On Fri, Nov 24, 2017 at 3:10 PM, Herby Vojčík
>  wrote:
> >
> > Thank you all, now I understand it better. Good for lots of
> "branches".
> >
> > However, I wonder how does it work with the rule I read somewhere:
> > "start
> > each day [of work on a project] with a new image", which means I
> should
> > not
> > reuse clean new image (as it needs populating from VCSes etc.) nor
> > reuse
> > existing image (I should start with the new one). Or does it combine
> > with
> > some startup-magic described in one of the recent Steph's booklets,
> the
> > "one
> > start per [new] image" case (but again, one should discriminate
> > projects
> > from each other)?
> >
> > Thanks, Herby
> >
> > Peter Uhnák wrote:
> >>
> >> Hi Herby,
> >>
> >> normally people use different images for their different projects,
> >> different versions, trying things, etc. Which means we end up with
> >> many
> >> locations on disk, and it can be hard to track.
> >> So PharoLauncher is a nice tool where you can download fresh image
> >> just
> >> by clicking, and you see the list of your local images and can
> launch
> >> them, etc.
> >>
> >> Peter
> >>
> >> On Thu, Nov 23, 2017 at 12:56 PM, Herby Vojčík >> >   wrote:
> >>
> >>   Stephane Ducasse wrote:
> >>
> >>   Hi
> >>
> >>   I love the PharoLauncher.
> >>
> >>
> >>   Pardon my question, I have downloaded it and looked at it,
> but I
> >>   don't get it. What does it do / what are the use cases (honest
> >>   question)?
> >>
> >>   Thanks, Herby
> >>
> >>
> >>   It helps me to manage my parallel development and
> projects.
> >>
> >>   We should put a link on the Pharo web site because
> >>
> >>   http://files.pharo.org/platform/launcher/
> >>   
> >>
> >>   is arcane.
> >>
> >>   Stef
> >>
> >>
> >>
> >>
> >>>
> >>
> >
> >
>
>
>


Re: [Pharo-users] How to write a little REPL

2017-11-27 Thread p...@highoctane.be
NeoConsole could be an option.

https://github.com/svenvc/pharo-server-tools/blob/master/README.md

Phil

On Nov 27, 2017 03:56, "Holger Freyther"  wrote:


> On 27. Nov 2017, at 05:38, Stephane Ducasse 
wrote:
>
> Hi

Hey!


> I'm working on a mini scheme implementation and I would like to add a
REPL and
> I wonder how I can super easily get a read line.

The easiest might just be to use "rlwrap your-interpreter"? But I think you
want to allow multi-line input. So either link libreadline (GPL) or libedit?

holger


Re: [Pharo-users] How to write a little REPL

2017-11-27 Thread p...@highoctane.be
Or https://github.com/guillep/Scale

but linux.

Phil

On Nov 27, 2017 03:56, "Holger Freyther"  wrote:

>
> > On 27. Nov 2017, at 05:38, Stephane Ducasse 
> wrote:
> >
> > Hi
>
> Hey!
>
>
> > I'm working on a mini scheme implementation and I would like to add a
> REPL and
> > I wonder how I can super easily get a read line.
>
> The easiest might just be to use "rlwrap your-interpreter"? But I think
> you want to allow multi-line input. So either link libreadline (GPL) or
> libedit?
>
> holger
>
>


Re: [Pharo-users] How do you store and manage small programs?

2017-11-27 Thread p...@highoctane.be
QuickAccess is also a great option.

*https://pharoweekly.wordpress.com/2015/11/06/quickaccess/
*

On Mon, Nov 27, 2017 at 11:16 AM, Alistair Grant 
wrote:

> On 26 November 2017 at 13:07, Stephane Ducasse 
> wrote:
> > Hi Andy
> >
> > As you saw there are plenty of solutions.
> >
> > Now what I learned is that it is often better in the long to have a
> > little object because suddenly
> > it opens your mind and you realise that you can teach him something more.
> >
> > So I often find myself realising that I created some class methods and
> > that it was stupid
> > better have a real little object because it can do more and in
> > particular for open new path
> >
> > So now I do not use scripts but plain little classes with nice little
> > printOn: methods and arguments
> > to get customized.
>
> +1
>
> And if you create a class method to do the most common operation(s),
> you can add the "

Re: [Pharo-users] How do you store and manage small programs?

2017-11-27 Thread p...@highoctane.be
It is useful for presentations.

https://www.youtube.com/watch?v=JhmmoEtAq20&t=269s

Phil

On Mon, Nov 27, 2017 at 1:06 PM, Tim Mackinnon  wrote:

> Wow - I never noticed that extension - that’s amazing.
>
> On 27 Nov 2017, at 10:56, p...@highoctane.be wrote:
>
> QuickAccess is also a great option.
>
> *https://pharoweekly.wordpress.com/2015/11/06/quickaccess/
> <https://pharoweekly.wordpress.com/2015/11/06/quickaccess/>*
>
> On Mon, Nov 27, 2017 at 11:16 AM, Alistair Grant 
> wrote:
>
>> On 26 November 2017 at 13:07, Stephane Ducasse 
>> wrote:
>> > Hi Andy
>> >
>> > As you saw there are plenty of solutions.
>> >
>> > Now what I learned is that it is often better in the long to have a
>> > little object because suddenly
>> > it opens your mind and you realise that you can teach him something
>> more.
>> >
>> > So I often find myself realising that I created some class methods and
>> > that it was stupid
>> > better have a real little object because it can do more and in
>> > particular for open new path
>> >
>> > So now I do not use scripts but plain little classes with nice little
>> > printOn: methods and arguments
>> > to get customized.
>>
>> +1
>>
>> And if you create a class method to do the most common operation(s),
>> you can add the "

Re: [Pharo-users] Running headless on Windows

2017-12-29 Thread p...@highoctane.be
If you want to run Pharo as a service, I have found nssm to be working well.

https://nssm.cc

Phil

On Dec 29, 2017 09:25, "Nicolai Hess"  wrote:

>
>
> 2017-12-29 3:07 GMT+01:00 Andrei Stebakov :
>
>> Pierce, I tried all of those "no display" options, the result is the same
>>
>> On Dec 28, 2017 8:37 PM, "Pierce Ng"  wrote:
>>
>>> On Wed, Dec 27, 2017 at 04:58:39PM +0100, Cyril Ferlicot D. wrote:
>>> > On 12/27/2017 04:39 PM, Andrei Stebakov wrote:
>>> > > When I run Pharo 6.1 with -- headless option on Windows, it executes
>>> the
>>> > > eval command as expected but during the execution (which lasts 4
>>> sec) it
>>> > > opens the Pharo GUI.
>>> > > Is it expected? I thought headless means that the whole execution
>>> would
>>> > > happen in the background
>>> >
>>> > I think that currently Pharo does not have a "real" headless. But I
>>> > heard there was work on that part for Pharo 7.
>>>
>>> I know OP is talking about Windows...  I've been running server
>>> applications on
>>> Linux without X11 with -vm-display-null and in-image RFBServer for
>>> access to
>>> Pharo over VNC. This works very well for me.
>>>
>>> I believe "real" headless means GUI is not run at all and therefore does
>>> not
>>> consume CPU cycles, which is very welcome. Meanwhile, maybe
>>> -vm-display-null
>>> works on Windows for scripting purposes?
>>>
>>> Pierce
>>>
>>>
>>>
>
> Hi Andrei,
>
> can you try this:
>
> Open Pharo normal (no headless option).
> Change the window size to "not-maximized" (eve if it is actually not
> maximized, maximize it ones and change it back to "not-maximized")
> Save and quit the image.
>
> After that, a call like
>
> pharo --headless pharo.image eval "DateAndTime now"
>
> will write the output to the stdout file, without opening a window.
>
>
>
>
>
>
>
>


Re: [Pharo-users] PharoS

2014-09-08 Thread p...@highoctane.be
On Mon, Sep 8, 2014 at 10:14 AM, Sven Van Caekenberghe  wrote:

> Hi Annick,
>
> On 08 Sep 2014, at 09:26, Annick Fron  wrote:
>
> > What is the difference between pharoS and pharo ?
> > Annick
>
> At one point there was just the standard Squeak VM. Then Eliot started the
> CogVM project, whose ultimate goal was to have a JIT compiler. That meant
> that he had to change part the way the image interacted with the VM,
> especially around stack and closure/block usage [this is not 100% accurate,
> but the details are complex]. So he decided to tackle this in two broad
> steps: first make the just mentioned changes, test that part and then do
> the JIT part.
>
> So the Pharo S (aka Stack) VM and the Pharo (COG/JIT) VM are brothers,
> with the old Squeak VM being their ancestor.
>
> Practically, the S VM is slower (because it does not do JIT compilation),
> but much more portable (because it does not have to generate machine code).
> The S VM is often used to decided whether a VM problem is JIT related or
> not.
>
> HTH,
>
> Sven
>

and PharoS is what you run on an iPad or iPhone.

Phil


Re: [Pharo-users] The fourth R

2014-09-11 Thread p...@highoctane.be
"Smalltalk is not a language, it is an object computer"

Wow, that nails it quite nicely.

And it feels a lot like that, especially with tools like GT-Playground.

Now, the most complicated bit is for me to get the user to discuss with the
object computer through the UI in a satisfying way. Getting the right UI
for delivering the value is taking a very long time.

Phil

On Thu, Sep 11, 2014 at 5:42 PM, Trygve Reenskaug 
wrote:

>  Hi kilon alios,
> I want to go deeper than any programming language. "What is a computer?"
> Almost all programming languages build  on the von Neumann architecture
> with data processing as " The execution of a systematic sequence of
> operations
> performed upon data." I believe this is unnecessarily low-level and
> complex  for general use. Much closer to the human mind is to build on an
> object computer  where the unit of storage is the object rather than the
> bit or byte. Data processing becomes "the systematic exchange of messages
> between objects." Lots of stuff that's of no interest to the general user
> is then hidden under the hood.
>
> The users of immediate importance may be power users. Computational
> chemists are my favorite examples. What shall be their mental model, what
> do we teach them and how do we form our programs such that they can
> understand and modify what goes on on the computer?
>
> I foresee that (virtual) object computers will supersede our current
> computers for general programming. They will be supported by experts doing
> systems programming on various levels from virtual machines down to
> microcode and hardware. When this is achieved; Java, Ruby, C++, C, Haxe,
> etc. will no longer be used for general application programming. (Smalltalk
> is, of course, not a language but an object computer.)
>
> The "pythonic" culture should permeate more than Phyton, it should  be
> behind all we do. Thanks for sharing it.
> C. A. R. Hoare says it succintly:
>" There are two ways of constructing a software design:
> -One way is to make it so simple that there are  obviously no
> deficiencies
> -The other way is to make it so complicated that there are no
> obvious deficiencies."
> and
> "The first method is far more difficult…."
> also:
> "The price of reliability is the pursuit of the utmost simplicity"
>
> I think we are in agreement about the need for readable code. But I
> disagree when you say "We need very complex solutions to very complex
> problems". I believe we can attain simple solutions to very complex
> problems.  If the complexity is in the user's mental model then a direct
> mapping of this model into code will be simple as seen from the user's
> point of view. If the program is more complex than the user's mental model,
> the program should be simplified.
>
> It would be helpful if you would suggest an example where Phyton leads to
> more readable code than say Pharo.
>
>
> On 07.09.2014 12:29, kilon alios wrote:
>
> Python has no competition. Sure there are languages that are more popular
> than Python for their own reasons. There have been simpler languages before
> python, there have been more popular languages, more cross platform
> languages etc etc but Python fills a gap that no language was able to fill
> before it , easy to use very powerful well documented libraries. Python is
> a language that you can teach to a kid now and make a living later on using
> until his or her old age. Its not because the language is simple , its
> simple enough but not the simplest. Its because the culture surrounding the
> creation of libraries . That culture has a name its called "pythonic"
>
>   Beautiful is better than ugly.
> Explicit is better than implicit.
> Simple is better than complex.
> Complex is better than complicated.
> Flat is better than nested.
> Sparse is better than dense.
> Readability counts.
> Special cases aren't special enough to break the rules.
> Although practicality beats purity.
> Errors should never pass silently.
> Unless explicitly silenced.
> In the face of ambiguity, refuse the temptation to guess.
> There should be one-- and preferably only one --obvious way to do it.
> Although that way may not be obvious at first unless you're Dutch.
> Now is better than never.
> Although never is often better than *right* now.
> If the implementation is hard to explain, it's a bad idea.
> If the implementation is easy to explain, it may be a good idea.
> Namespaces are one honking great idea -- let's do more of those!
>
> this kind of ideology is why Python has been so successful. It has also 
> inspired jokes like this
>
> http://xkcd.com/353/
>
> it may look funny and it says thinks about overestimating the simplicity of 
> those libraries but python does feel at times as simple as this, as simple as 
> importing antigravity.
>
> So if a kid comes to me and ask me "what language should I learn" , I will 
> recommend a language

Re: [Pharo-users] [ANN] Easy I18N for Pharo

2014-09-15 Thread p...@highoctane.be
With a .po bridge to/from I18N, wouldn't we have a pretty nice solution?

Phil

On Mon, Sep 15, 2014 at 11:35 AM, Hilaire  wrote:

>
> Nice for project with a delimited scope.
> Problem: you cut yourself from translators aggregated in oneline free
> software community. For example https://translations.launchpad.net/drgeo
> For DrGeo this is a show stopper.
>
> Hilaire
>
> Le 15/09/2014 10:23, Torsten Bergmann a écrit :
>
>> Need an easy translation framework for your Pharo application
>> with no external dependency?
>>
>> Then check out the I18N project:
>>
>>http://smalltalkhub.com/#!/~TorstenBergmann/I18N
>>
>> Docu and examples can be found on the same page, screenshot
>> is attached.
>>
>> Bye
>> T.
>>
>>
>
> --
> Dr. Geo - http://drgeo.eu
> iStoa - http://istao.drgeo.eu
>
>
>
>


Re: [Pharo-users] How can I help make installing Pharo easier (on Debian Wheezy)?

2014-09-16 Thread p...@highoctane.be
Like this

http://philippeback.be/2014/02/pharovm-now-running-on-debian-wheezy/

---
Philippe Back
Visible Performance Improvements
Mob: +32(0) 478 650 140 | Fax: +32 (0) 70 408 027
Mail:p...@highoctane.be | Web: http://philippeback.eu
Blog: http://philippeback.be | Twitter: @philippeback
Youtube: http://www.youtube.com/user/philippeback/videos

High Octane SPRL
rue cour Boisacq 101 | 1301 Bierges | Belgium

Pharo Consortium Member - http://consortium.pharo.org/
Featured on the Software Process and Measurement Cast -
http://spamcast.libsyn.com
Sparx Systems Enterprise Architect and Ability Engineering EADocX Value
Added Reseller



On Tue, Sep 16, 2014 at 2:48 PM, Damien Cassou 
wrote:

> On Mon, Sep 15, 2014 at 9:51 PM, Sloane Simmons 
> wrote:
> > For learning Smalltalk, running in a virtualbox VM absolutely works
> > (for me), but I'd like to try and compile for Debian stable (or
> > statically link glibc(?)) and then add to the official repositories so
> > that it's easier to install.  Bonus points would be making a 64-bit
> > version... ;)
>
> You have a few solutions solutions:
>
> 1/ try this
> http://files.pharo.org/vm/pharo/linux/old-libc/pharovm-ubuntu804.tar.gz
> 2/ try the .deb file for Ubuntu that is closest to your distribution:
> https://launchpad.net/~pharo/+archive/unstable/+packages
> 3/ create a .deb file yourself using the deb generator scripts I
> wrote:
> https://github.com/pharo-project/pharo-ubuntu/tree/master/pharo-vm-core-i386
> (as soon as it is compiled, it will work fine on 64 bits
> architectures)
> 4/ use the nix package manager that already has a package for Pharo:
> http://nixos.org/nix/manual/. Nix can very easily be installed on any
> Unix system including Debian and Mac OSX
>
>
> --
> Damien Cassou
> http://damiencassou.seasidehosting.st
>
> "Success is the ability to go from one failure to another without
> losing enthusiasm."
> Winston Churchill
>
>
>


[Pharo-users] Solution for memoization

2014-09-17 Thread p...@highoctane.be
I saw http://www.slideshare.net/esug/memoization-aspects

Do we have a memoization package based on that work?

Phil


Re: [Pharo-users] Zoomable & Infinitely scrollable PasteupMorph

2014-09-17 Thread p...@highoctane.be
Ah one thing with roassal:

Please honor the global keymappings and morph local ones.

TRMorph swallows them due to the key press related methods which hijack
them all.

Once a TRMorph is active is feels weird.

I love TRMorph and animations. Very nice code.

Phil


Le 18 sept. 2014 05:46, "Alexandre Bergel"  a
écrit :

> Yes it can. But Roassal is not made to replace Morphic.
> In my opinion, Morphic is not simply about having graphic elements
> answering events, as Roassal does. Morphic provides ways to build
> sophisticated UI (even if Morphic behaves poorly in comparison with
> state-of-the-art UI frameworks). Roassal is made to visualize and interact
> with data.
>
> As it is defined today, Roassal is not made to build sophisticated UI.
>
> Cheers,
> Alexandre
>
>
> On Sep 16, 2014, at 10:30 AM, Denis Kudriashov 
> wrote:
>
> > Do you think Roassal can replace Morphic at all?
> >
>
> --
> _,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:
> Alexandre Bergel  http://www.bergel.eu
> ^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;._,.;:~^~:;.
>
>
>
>
>
>


Re: [Pharo-users] Where pharo stores its selfies?

2014-09-19 Thread p...@highoctane.be
 As a side note, open the file browser from the world menu, it should open
on that very folder.

Or FileList open. in a Workspace.

Then when you pick a png there (PharoScreenshot.png for example ^_^) you
can right click and say "Open Graphic in a Window".



Phil



On Fri, Sep 19, 2014 at 5:07 PM, Torsten Bergmann  wrote:

> Offray wrote:
> >> I'm taking somescreenshots of Pharo using the functionality provided by
> Pharo itself to make this. It seems that >screenshot is properly saved, but
> there is no indication about where is stored. Could someone point me the
> place?
>
> Yes this is confusing. I opened an issue and fixed this for Pharo 4.0. See
> details
> and screenshot in:
>
>
> https://pharo.fogbugz.com/f/cases/14044/Selfies-shot-with-Pharo-should-give-visual-feedback
>
> Bye
> T.
>
>
>


Re: [Pharo-users] Pharo by Example : Still usable?

2014-09-19 Thread p...@highoctane.be
Because there is a lot of content of value which isn't in the GitHub
project yet.

As I do have a ton of old Smalltalk books (hardcopy, Amazon is your friend)
and a hardcopy of all Pharo books (including Pharo for the Enterprise,
which is not out yet), I can tell you that, except on the "windows and
widgets" front, almost all older books are still full of gems. Smalltalk
with Style has been mentioned. Very good indeed.

On thing about Smalltalk is that a lot of it is properly done and has been
honed over time.
So, an "old Smalltalk book" is not the typical door stopper kind of book in
IT.

(For the story, I've got two Java books which are under my monitors stands,
never had any need to look at them since I've put them there. Not so with
the Smalltalk books, from which I learn everyday).

For blowing you mind, check Andres Valloud books. There is nothing like it
elsewhere methinks.

I tought I understood something about programming. Then I met Smalltalk.
And I realized how little I knew. Pharo made me a better programmer. So
much that I am now making a living out of Pharo exclusively. This thing
makes you realize how much we have been slow on progress, and how current
tools, no matter how great, are still stone age style tools.

Being able to extend my own environment, shape it to my needs, well, that's
a real "bicycle for the mind". The other tools are really "Anvils for the
mind". I've been debugging Javascript in the latest Chrome, hell; the beast
can't even locate the line I am stepping over properly (well known
problem...).

And I feel happy when doing Smalltalk. I can focus on the real problem. And
not battling with all the damn paraphernalia that usually is with the other
things (Maven anyone?)

aRant stop.

Phil


---
Philippe Back
Visible Performance Improvements
Mob: +32(0) 478 650 140 | Fax: +32 (0) 70 408 027
Mail:p...@highoctane.be | Web: http://philippeback.eu
Blog: http://philippeback.be | Twitter: @philippeback
Youtube: http://www.youtube.com/user/philippeback/videos

High Octane SPRL
rue cour Boisacq 101 | 1301 Bierges | Belgium

Pharo Consortium Member - http://consortium.pharo.org/
Featured on the Software Process and Measurement Cast -
http://spamcast.libsyn.com
Sparx Systems Enterprise Architect and Ability Engineering EADocX Value
Added Reseller



On Fri, Sep 19, 2014 at 5:10 PM, Mayuresh Kathe  wrote:

> Thanks for that link.
>
> Just curious; in what way would the old PBE still be useful for someone
> very new to Pharo?
>
> ~Mayuresh
>
>
> On 2014-09-19 20:32, kilon alios wrote:
>
>> I have ported the first 5 chapters to Pharo 3
>> --> https://www.gitbook.io/book/kilon/pbe [1]
>>
>> the old PBE is outdated by still highly useful.
>>
>> On Fri, Sep 19, 2014 at 5:18 PM, Mayuresh Kathe 
>> wrote:
>>
>>  I believe "Pharo by Example" is the primary book to start-off with
>>> Pharo.
>>> A look at the Lulu.com page shows it to be from early 2010.
>>>
>>> Would it still be usable with the present version of Pharo?
>>>
>>> Thanks,
>>>
>>> ~Mayuresh
>>>
>>
>>
>>
>> Links:
>> --
>> [1] https://www.gitbook.io/book/kilon/pbe
>>
>
>
>


Re: [Pharo-users] Booting into Pharo!

2014-09-19 Thread p...@highoctane.be
Sure is.

You want to use OSProcess.

Load OSProcess from the configuration browser.

You can get environment variables like this:

dirString:= OSProcess thisOSProcess environment at: #PRJ_DIR.

Check this thread:
http://comments.gmane.org/gmane.comp.lang.smalltalk.pharo.user/12496

Example:

command := 'tac ', file fullName, ' | head -200'.
output := ''.
[
c :=  (PipeableOSProcess command: command).
output := c output.
] ensure: [ c closePipes ].

 Or check for all references for PipeableOSProcess, there are a ton.

Do not forget the closePipes or you'll run out of resources at one point.

Phil


On Fri, Sep 19, 2014 at 6:18 PM, Mayuresh Kathe  wrote:

> Hello,
>
> While I am still waiting for my copy of the PBE, I would like to
> initiate work on a project (along with friends).
>
> The idea is to build a minimalist Linux based system which would boot up
> straight into a full-screen Pharo environment.
>
> The system itself would be single user, consisting of not more than a
> Linux kernel, a few system utilities (busybox?), X (KDrive?) and Pharo
> (vm + image + ...).
>
> Would like to know if it's some how possible to control external
> programs from within Pharo, essentially shell scripts for network setup,
> etc.
>
> Thanks,
>
> ~Mayuresh
>
>
>
>


Re: [Pharo-users] Theme : Choices : Good, but ...

2014-09-19 Thread p...@highoctane.be
Try the DawnTheme.

https://github.com/sebastianconcept/Pharo3DawnTheme

I've got my own little tweaks of it here:

http://www.smalltalkhub.com/#!/~philippeback/HOExtras/packages/Pharo3DawnTheme

Looks like Sublime. It is based on the Dark Theme.


Phil

On Fri, Sep 19, 2014 at 7:55 PM, Mayuresh Kathe  wrote:

> It's been close to 6 hours that I've been playing with the defaults
> offered with Pharo 3.
>
> Everything works so much more smoothly than Squeak! It also feels great.
> What's kind of problematic (as I see it) is the "look".
>
> There are 3 themes that I got with the default image;
> Pharo 3, Vistary and Watery.
>
> Look good, but somehow give off the feel of having more style than
> substance.
>
> I remember using something called Java Swing long back.
> It too had a plethora of themes, but the one that was the most detailed,
> and well designed (as in how well it worked), was something called "Java
> Steel".
>
> Please see the images at;
> http://docs.oracle.com/javase/tutorial/figures/uiswing/
> lookandfeel/OceanLAF.gif
> https://today.java.net/images/2004/02/laf_fig2.gif
>
> If there could be some way to have that look and feel, while adhering to
> the Java LaF Guidelines for the same, we might have a Pharo system which
> would be not only neater looking, but also lighter weight (by virtue of
> fewer extravagant graphical properties).
>
> Hope this suggestion isn't preposterous. :)
>
> ~Mayuresh
>
>
>
>


Re: [Pharo-users] Preorder tree traversal

2014-09-19 Thread p...@highoctane.be
Check the FileSystem guides: Preorder is in there.

Look at GuideTest and PreorderGuideTest for a starting point.

Phil


​


Re: [Pharo-users] FFI examples on Linux don't work

2014-09-22 Thread p...@highoctane.be
I've been able to reproduce this.

Well, my CentOS thing requires me for some reason to put
/usr/lib/libX11.so.6 in the module name (doing these kind of things looks
like usual for lib names with FFI from what I saw from old Squeak threads).


XCreateGC: xDisplay with: aDrawable with: valueMask with: values


Now, other internal FFIPrims tests do work.

So, it is X11 or something else, I do not know.

Phil


On Mon, Sep 22, 2014 at 4:39 PM, Ben Coman  wrote:

> Annick Fron wrote:
>
>> Hi,
>>
>> I have posted a bug about this in fogbugz.
>> FFI example on Linux don’t work
>>
>> X11Display coloredRectangles
>> raises an error « coud not coerce arguments ».
>> In fogbugz, I was asked to raise this question in the mailing list, to
>> know if it comes from the VM or from FFI.
>>
>> Annick
>>
>>
>>
> Hi Annick,
> Sorry I don't know anything about this topic to help, just a minor
> observation that a link to the fogbugz issue would help streamline things
> for someone who does.
> :)
> cheers -ben
>
>
>
>


Re: [Pharo-users] FFI examples on Linux don't work

2014-09-22 Thread p...@highoctane.be
More on the story.

So, the X11 example may not be the best one to have in FFI. It is
interesting but complicated.

A basic call, like:

Sample class>>callC: aString

^self externalCallFailed

works nicely.

Sample callC: 'Hello'.

prints Hello on stdout.

Phil



On Mon, Sep 22, 2014 at 6:10 PM, p...@highoctane.be 
wrote:

> I've been able to reproduce this.
>
> Well, my CentOS thing requires me for some reason to put
> /usr/lib/libX11.so.6 in the module name (doing these kind of things looks
> like usual for lib names with FFI from what I saw from old Squeak threads).
>
>
> XCreateGC: xDisplay with: aDrawable with: valueMask with: values
>  '/usr/lib/libX11.so.6'>
>
> Now, other internal FFIPrims tests do work.
>
> So, it is X11 or something else, I do not know.
>
> Phil
>
>
> On Mon, Sep 22, 2014 at 4:39 PM, Ben Coman  wrote:
>
>> Annick Fron wrote:
>>
>>> Hi,
>>>
>>> I have posted a bug about this in fogbugz.
>>> FFI example on Linux don’t work
>>>
>>> X11Display coloredRectangles
>>> raises an error « coud not coerce arguments ».
>>> In fogbugz, I was asked to raise this question in the mailing list, to
>>> know if it comes from the VM or from FFI.
>>>
>>> Annick
>>>
>>>
>>>
>> Hi Annick,
>> Sorry I don't know anything about this topic to help, just a minor
>> observation that a link to the fogbugz issue would help streamline things
>> for someone who does.
>> :)
>> cheers -ben
>>
>>
>>
>>
>


Re: [Pharo-users] FFI examples on Linux don't work

2014-09-22 Thread p...@highoctane.be
Little FFI example with Syslog:
https://gist.github.com/philippeback/078944c4f6a3bdfe582f

Phil


On Mon, Sep 22, 2014 at 6:50 PM, p...@highoctane.be 
wrote:

> More on the story.
>
> So, the X11 example may not be the best one to have in FFI. It is
> interesting but complicated.
>
> A basic call, like:
>
> Sample class>>callC: aString
> 
> ^self externalCallFailed
>
> works nicely.
>
> Sample callC: 'Hello'.
>
> prints Hello on stdout.
>
> Phil
>
>
>
> On Mon, Sep 22, 2014 at 6:10 PM, p...@highoctane.be 
> wrote:
>
>> I've been able to reproduce this.
>>
>> Well, my CentOS thing requires me for some reason to put
>> /usr/lib/libX11.so.6 in the module name (doing these kind of things looks
>> like usual for lib names with FFI from what I saw from old Squeak threads).
>>
>>
>> XCreateGC: xDisplay with: aDrawable with: valueMask with: values
>> > '/usr/lib/libX11.so.6'>
>>
>> Now, other internal FFIPrims tests do work.
>>
>> So, it is X11 or something else, I do not know.
>>
>> Phil
>>
>>
>> On Mon, Sep 22, 2014 at 4:39 PM, Ben Coman  wrote:
>>
>>> Annick Fron wrote:
>>>
>>>> Hi,
>>>>
>>>> I have posted a bug about this in fogbugz.
>>>> FFI example on Linux don’t work
>>>>
>>>> X11Display coloredRectangles
>>>> raises an error « coud not coerce arguments ».
>>>> In fogbugz, I was asked to raise this question in the mailing list, to
>>>> know if it comes from the VM or from FFI.
>>>>
>>>> Annick
>>>>
>>>>
>>>>
>>> Hi Annick,
>>> Sorry I don't know anything about this topic to help, just a minor
>>> observation that a link to the fogbugz issue would help streamline things
>>> for someone who does.
>>> :)
>>> cheers -ben
>>>
>>>
>>>
>>>
>>
>


Re: [Pharo-users] Forcing a library to load

2014-09-22 Thread p...@highoctane.be
NativeBoost has loadModule: aModuleName which should do the trick.

Phil
​


Re: [Pharo-users] FFI examples on Linux don't work

2014-09-22 Thread p...@highoctane.be
I passed 'localhost:0:0' in the XWindows example and this gave me a window
reference.

The next problem was that it broke after that. But I got the handle.

Try with that, it may help.

Phil


On Mon, Sep 22, 2014 at 10:02 PM, Annick Fron  wrote:

> Thanks you
> The problem is I wanted to use X windows !
> Otherwise I have managed to use FFI on Linux.
> Perhaps there is a glitch when passing nil as argument. It is not clear
> whether we have to use nil or 0 (as a null pointer).
> This is really my point, I sometimes need to pass NULL.
> Annick
>
> Le 22 sept. 2014 à 21:22, Nicolai Hess  a écrit :
>
>
> 2014-09-22 18:10 GMT+02:00 p...@highoctane.be :
>
>> I've been able to reproduce this.
>>
>> Well, my CentOS thing requires me for some reason to put
>> /usr/lib/libX11.so.6 in the module name (doing these kind of things looks
>> like usual for lib names with FFI from what I saw from old Squeak threads).
>>
>
> Yes, I read this threads too, I solved it by
> LD_LIBRARY_PATH= ./pharo 
>
> but no matter which of this (LD_LIBRARY_PATH or full name in the ffi
> pragma) the call throws the
> "could not coerce arguments"- error.
>
> But the Sample class>>callC: method you wrote in the other mail works.
>
>
>>
>> XCreateGC: xDisplay with: aDrawable with: valueMask with: values
>> > '/usr/lib/libX11.so.6'>
>>
>> Now, other internal FFIPrims tests do work.
>>
>> So, it is X11 or something else, I do not know.
>>
>> Phil
>>
>>
>> On Mon, Sep 22, 2014 at 4:39 PM, Ben Coman  wrote:
>>
>>> Annick Fron wrote:
>>>
>>>> Hi,
>>>>
>>>> I have posted a bug about this in fogbugz.
>>>> FFI example on Linux don’t work
>>>>
>>>> X11Display coloredRectangles
>>>> raises an error « coud not coerce arguments ».
>>>> In fogbugz, I was asked to raise this question in the mailing list, to
>>>> know if it comes from the VM or from FFI.
>>>>
>>>> Annick
>>>>
>>>>
>>>>
>>> Hi Annick,
>>> Sorry I don't know anything about this topic to help, just a minor
>>> observation that a link to the fogbugz issue would help streamline things
>>> for someone who does.
>>> :)
>>> cheers -ben
>>>
>>>
>>>
>>>
>>
>
>


Re: [Pharo-users] Ridiculous we are

2014-09-22 Thread p...@highoctane.be
Also, sometimes things do look like "Téléchargement" but are still
Downloads under the hood as the OS translates the UI.

Phil





On Mon, Sep 22, 2014 at 10:35 PM, stepharo  wrote:

> Hilaire
>
> These are two days that after upgrading my iPhone, the recovery process
> crash.
> After two days trying I finally succeeded to upload my recovery to my
> iPhone and
> now my iPhone crashes continously at boot time. I get a nice sepia
> screenshot and
> it restarts. I will have to send my iPhone to Apple for real check.
> Just because I did an update!
>
> So I do not accept the title of your email. Simply I cannot.
>
> Do you imagine the billions injected into iPhone. So probably iPhone is
> one order of magnitude
> more complex than Pharo but the money injected into Pharo is our
> collective time and
> it is far from being an order of magnitude smaller than several billions.
>
> Stef
>
>
> On 22/9/14 22:07, Hilaire wrote:
>
>> Hello,
>>
>> Tested on Linux, when I move DrGeo.app folder under hierarchy tree with
>> accent characters (For example, /home/hilaire/Téléchargement/), loading
>> font does not work
>>
>> However font path seems ok:
>>   File @ /home/hilaire/Téléchargements/DrGeo.app/Contents/Resources.
>> Inspecting this path, it looks like 'Téléchargements' is 8 bits, but it
>> should be utf-8, right?
>>
>> I think there are issue on Windows, as some user reported to me.
>>
>> Holy shit.
>>
>> Hilaire
>>
>>
>
>
>


Re: [Pharo-users] FFI examples on Linux don't work

2014-09-22 Thread p...@highoctane.be
I've got the 32 bit ones. I checked.

Nicolas got it working, I'll check.

Phil



On Tue, Sep 23, 2014 at 12:32 AM, Casimiro de Almeida Barreto <
casimiro.barr...@gmail.com> wrote:

>  Sometimes the problem is that you have Linux x86_64 and only the 64bit
> libraries. When using squeak it is necessary to have the proper 32bit
> libraries to have the system working.
>
> On 22-09-2014 18:10, p...@highoctane.be wrote:
>
>   I passed 'localhost:0:0' in the XWindows example and this gave me a
> window reference.
>
>  The next problem was that it broke after that. But I got the handle.
>
>  Try with that, it may help.
>
>  Phil
>
>
> On Mon, Sep 22, 2014 at 10:02 PM, Annick Fron  wrote:
>
>> Thanks you
>> The problem is I wanted to use X windows !
>> Otherwise I have managed to use FFI on Linux.
>> Perhaps there is a glitch when passing nil as argument. It is not clear
>> whether we have to use nil or 0 (as a null pointer).
>> This is really my point, I sometimes need to pass NULL.
>> Annick
>>
>>  Le 22 sept. 2014 à 21:22, Nicolai Hess  a écrit :
>>
>>
>> 2014-09-22 18:10 GMT+02:00 p...@highoctane.be :
>>
>>>   I've been able to reproduce this.
>>>
>>>  Well, my CentOS thing requires me for some reason to put
>>> /usr/lib/libX11.so.6 in the module name (doing these kind of things looks
>>> like usual for lib names with FFI from what I saw from old Squeak threads).
>>>
>>
>>  Yes, I read this threads too, I solved it by
>>  LD_LIBRARY_PATH= ./pharo 
>>
>>  but no matter which of this (LD_LIBRARY_PATH or full name in the ffi
>> pragma) the call throws the
>>  "could not coerce arguments"- error.
>>
>>  But the Sample class>>callC: method you wrote in the other mail works.
>>
>>
>>>
>>>  XCreateGC: xDisplay with: aDrawable with: valueMask with: values
>>>  >> module: '/usr/lib/libX11.so.6'>
>>>
>>>  Now, other internal FFIPrims tests do work.
>>>
>>>  So, it is X11 or something else, I do not know.
>>>
>>>  Phil
>>>
>>>
>>> On Mon, Sep 22, 2014 at 4:39 PM, Ben Coman  wrote:
>>>
>>>> Annick Fron wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I have posted a bug about this in fogbugz.
>>>>> FFI example on Linux don’t work
>>>>>
>>>>> X11Display coloredRectangles
>>>>> raises an error « coud not coerce arguments ».
>>>>> In fogbugz, I was asked to raise this question in the mailing list, to
>>>>> know if it comes from the VM or from FFI.
>>>>>
>>>>> Annick
>>>>>
>>>>>
>>>>>
>>>> Hi Annick,
>>>> Sorry I don't know anything about this topic to help, just a minor
>>>> observation that a link to the fogbugz issue would help streamline things
>>>> for someone who does.
>>>> :)
>>>> cheers -ben
>>>>
>>>>
>>>>
>>>>
>>>
>>
>>
>
>


Re: [Pharo-users] BLOG: Block Translators - parsing magic

2014-09-23 Thread p...@highoctane.be
Cool article & technique indeed. Ah Smalltalk, where were you all those
years ;-)

Speaking of PetitParser, which is excellent indeed, there is this #==>
method in Boolean.

PetitParser uses that a lot. I can use the thing but do not really grasps
how it works.

Now, the method comment says:

Boolean #==> aBlock
"The material conditional, also known as the material implication or truth
functional conditional. Correspond to not ... or ... and does not
correspond to the English if...then... construction.
 known as:
b if a
a implies b
if a then b
b is a consequence of a
a therefore b (but note: 'it is raining therefore it is cloudy' is
implication; 'it is autumn therefore the leaves are falling' is
equivalence).
 Here is the truth table for material implication:
   p   |   q   |   p ==> q
---|---|-
   T   |   T   |  T
   T   |   F   |  F
   F   |   T   |  T
   F   |   F   |  T
"

^self not or: [aBlock value]


This is still a bit foggy to me.

Anyone caring to shed some light on that?
What are the typical ways to use that?

TIA
Phil




On Tue, Sep 23, 2014 at 10:07 AM, Udo Schneider <
udo.schnei...@homeaddress.de> wrote:

> > just as it is black magic for me now :D
> The nice thing about this approach is the fact that it "just" piggybacks
> the normal Smalltalk message sending. So you can step through it using the
> Debugger - it's Smalltalk all the way down.
>
> I still remember my first shock when (having no formal background on
> parsing theory at that time) I saw the parsing tables generated by T-Gen.
> Of course it was Smalltalk ... but understanding those tables was a
> nightmare.
>
> PetitParser is the gold standard here IMHO. It is able to parse arbitrary
> input (compared to my block expressions only). And you can still use the
> Debugger to step through the parsing process *and still understand what's
> going on!*
>
> CU,
>
> Udo
>
> On 23.09.14 09:54, kilon alios wrote:
>
>> just as it is black magic for me now :D
>>
>> At least I get the general feeling. I am new to parsing too, so far I
>> have only played with regex parsing. Not the most smalltalkish way but
>> it works well so far.
>>
>> On Tue, Sep 23, 2014 at 9:39 AM, Udo Schneider
>> > > wrote:
>>
>> Hi Estaban,
>>
>> I think the first time I saw this pattern was in ReStore on Dolphin
>> Smalltalk. I didn't understand it's implementation back then. I
>> assume that it's similar to what I described though. But having a
>> Smalltalk block automagically creating the equivalent SQL SELECT
>> expression was like black magic at that time :-)
>>
>> CU,
>>
>> Udo
>>
>>
>>
>>
>> On 23.09.14 04:15, Esteban A. Maringolo wrote:
>>
>> Excellent article.
>>
>> I think GLORP uses a similar technique to setup its expressions,
>> and
>> also have issues with #and:/#or: selectors due to inlining, so
>> it uses
>> AND:/#OR: instead.
>>
>> Regards!
>>
>> Esteban A. Maringolo
>>
>> pd: Your blog and it's choosen topic made me remember
>> http://use-the-index-luke.com/
>>
>> 2014-09-22 20:48 GMT-03:00 Udo Schneider
>> > >__:
>>
>>
>> All,
>>
>> I just finished a blog entry. It shows how to use Smalltalk
>> blocks as parsers/translators. E.g. translating a Block
>>
>>   [:customer | (customer joinDate year is: Date
>> today year)]
>>
>> into an SQL-like String
>>
>>   (YEAR(customers.joinDate) = 2014)
>>
>> The SQL stuff is just an example - you can create nearly any
>> output.
>>
>> Check out
>> http://readthesourceluke.__blogspot.de/2014/09/block-__
>> translators-parsing-magic.html
>> > translators-parsing-magic.html>
>>
>> Maybe that's old stuff for some of you - but I hope it's
>> interesting for some at least :-)
>>
>> Comments and feedback appreciated.
>>
>> CU,
>>
>> Udo
>>
>>
>>
>>
>>
>>
>>
>>
>>
>
>
>
>


Re: [Pharo-users] BLOG: Block Translators - parsing magic

2014-09-23 Thread p...@highoctane.be
On Tue, Sep 23, 2014 at 10:15 AM, kilon alios  wrote:

> it reminds a lot of Kent's Beck Smalltalk Practice Patterns where it
> removes all ifs and replaces them with regular unary messages . It is
> definitely an elegant way of coding making the code just flow.
>
> I have not used PettitParser yet, looks powerful but I find it a bit weird
> in design. On the other hand regex is quite ugly and understanding complex
> regex a pain.
>

Well, I started writing Regexes for parsing some flat file content.
Quickly turned into a harder than needed way.
Moved to PP and things are now crystal clear. Give it a shot, it is really
powerful and easy to write once you get the hang of it.

Phil

>
> On Tue, Sep 23, 2014 at 11:07 AM, Udo Schneider <
> udo.schnei...@homeaddress.de> wrote:
>
>> > just as it is black magic for me now :D
>> The nice thing about this approach is the fact that it "just" piggybacks
>> the normal Smalltalk message sending. So you can step through it using the
>> Debugger - it's Smalltalk all the way down.
>>
>> I still remember my first shock when (having no formal background on
>> parsing theory at that time) I saw the parsing tables generated by T-Gen.
>> Of course it was Smalltalk ... but understanding those tables was a
>> nightmare.
>>
>> PetitParser is the gold standard here IMHO. It is able to parse arbitrary
>> input (compared to my block expressions only). And you can still use the
>> Debugger to step through the parsing process *and still understand what's
>> going on!*
>>
>> CU,
>>
>> Udo
>>
>> On 23.09.14 09:54, kilon alios wrote:
>>
>>> just as it is black magic for me now :D
>>>
>>> At least I get the general feeling. I am new to parsing too, so far I
>>> have only played with regex parsing. Not the most smalltalkish way but
>>> it works well so far.
>>>
>>> On Tue, Sep 23, 2014 at 9:39 AM, Udo Schneider
>>> >> > wrote:
>>>
>>> Hi Estaban,
>>>
>>> I think the first time I saw this pattern was in ReStore on Dolphin
>>> Smalltalk. I didn't understand it's implementation back then. I
>>> assume that it's similar to what I described though. But having a
>>> Smalltalk block automagically creating the equivalent SQL SELECT
>>> expression was like black magic at that time :-)
>>>
>>> CU,
>>>
>>> Udo
>>>
>>>
>>>
>>>
>>> On 23.09.14 04:15, Esteban A. Maringolo wrote:
>>>
>>> Excellent article.
>>>
>>> I think GLORP uses a similar technique to setup its expressions,
>>> and
>>> also have issues with #and:/#or: selectors due to inlining, so
>>> it uses
>>> AND:/#OR: instead.
>>>
>>> Regards!
>>>
>>> Esteban A. Maringolo
>>>
>>> pd: Your blog and it's choosen topic made me remember
>>> http://use-the-index-luke.com/
>>>
>>> 2014-09-22 20:48 GMT-03:00 Udo Schneider
>>> >> >__:
>>>
>>>
>>> All,
>>>
>>> I just finished a blog entry. It shows how to use Smalltalk
>>> blocks as parsers/translators. E.g. translating a Block
>>>
>>>   [:customer | (customer joinDate year is: Date
>>> today year)]
>>>
>>> into an SQL-like String
>>>
>>>   (YEAR(customers.joinDate) = 2014)
>>>
>>> The SQL stuff is just an example - you can create nearly any
>>> output.
>>>
>>> Check out
>>> http://readthesourceluke.__blogspot.de/2014/09/block-__
>>> translators-parsing-magic.html
>>> >> translators-parsing-magic.html>
>>>
>>> Maybe that's old stuff for some of you - but I hope it's
>>> interesting for some at least :-)
>>>
>>> Comments and feedback appreciated.
>>>
>>> CU,
>>>
>>> Udo
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>>
>


Re: [Pharo-users] BLOG: Block Translators - parsing magic

2014-09-23 Thread p...@highoctane.be
Thx for this!

I'd say that the material is worthy of inclusion into a bool chapter.

Phil
Le 23 sept. 2014 12:51, "Udo Schneider"  a
écrit :

> Phil,
>
> I'd say that's an implementation of the "Material implication"[1] operator
> from Propositional calculus.
>
> You can write it as
>
> P -> Q
>
> and read it as "P implies Q" or (not 100% correct) "if P (is true) then Q
> (is true)".
>
> Let's take a look at the truth table:
>
>  P | Q | P -> Q
> ---+---+---
>  t | t | t
> ---+---+---
>
> inserting it into the statement above yields:
>
> "if true then true" which is true indeed.
>
> The funny thing starts when we look at the case(s), where P is false. The
> general (verbal) rule says that if the premise (P) is false the truth value
> of the conclusion doesn't matter. Hence the complete term is true:
>
>  P | Q | P -> Q
> ---+---+---
>  f | t | t
> ---+---+---
>  f | f | t
> ---+---+---
>
> There is one case left: What happens if the premise is true but the
> conclusion is false? That's in direct violation of the defintion which
> states that "if P (is true) then Q (is true)". As P is true and Q is false
> the truth value of the complete term is false!
>
>  P | Q | P -> Q
> ---+---+---
>  t | f | f
> ---+---+---
>
> Or to put it in different words: An implication can only be false if the
> premise is true but the conclusion is false.
>
> So we end up with this truth table:
>
>  P | Q | P -> Q
> ---+---+---
>  t | t | t
> ---+---+---
>  f | t | t
> ---+---+---
>  f | f | t
> ---+---+---
>  t | f | f
> ---+---+---
>
> We did not take a look yet, at how to implement this with basic boolean
> operators. So we need to take a look at the table and find the expression:
> Let's start with the exception (fourth case). We can express this as:
>
> !(P & !Q) -> "The term is false if P is true and Q is false"
>
> I added the inner term "P & !Q" to the table to make it easier to follow:
>
>
>  P | Q | P -> Q | P & !Q | !(P & !Q)
> ---+---+++---
>  t | t | t  | f  | t
> ---+---+++---
>  f | t | t  | t  | f
> ---+---+++---
>  f | f | t  | f  | t
> ---+---+++---
>  t | f | f  | f  | t
> ---+---+++---
>
> The "last" step is to simplify the term "!(P & !Q)" using one of de
> Morgan's laws:
> !(A & B) == !A | !B
>
> Using this for our term gives
>
> !(P & !Q) == !P | !!Q == !P | Q
>
>  P | Q | P -> Q | P & !Q | !(P & !Q) | !P | Q
> ---+---+++---+
>  t | t | t  | f  | t | t
> ---+---+++---+
>  f | t | t  | t  | f | f
> ---+---+++---+
>  f | f | t  | f  | t | t
> ---+---+++---+
>  t | f | f  | f  | t | t
> ---+---+++---+
>
> So our final term is "correct" (proof in the truth table) and is
> equivalent to the smalltalk term:
>
> !P | Q  := self not or: [aBlock value]
>
>
> I have to admit though that implications in Propositional calculus really
> gave me a headache. You might simply want to accept that they are defined
> this way. And maybe it doesn't help ... but there are even more strange
> things lurking around the corner [4] :-)
>
> Although not immidiatly obvious all the terms in Propositional calculus do
> not neccessarly have a semantic meaning in context to each other. They are
> totaly independent. The only thing that counts is the truth value of its
> terms. E.g. something like this is mathematically/syntacically valid but
> doesn't make any sense from a semantic point of view:
>
> P := I am 12y old
> Q := It rains
>
> The term "P -> Q" is perfectly fine mathematically/syntacically but
> doesn't mean anything in terms of semantics.
>
>
> Hope this helps.
>
> CU,
>
> Udo
>
>
> [1] http://en.wikipedia.org/wiki/Material_implication_(rule_of_inference)
> [2] http://en.wikipedia.org/wiki/Propositional_calculus
> [3] http://en.wikipedia.org/wiki/De_Morgan's_laws
> [4] http://en.wikipedia.org/wiki/Paradoxes_of_material_implication
>
> On 23.09.14 10:49, p...@highoctane.be wrote:
>
>> Cool article & technique indeed. Ah Smalltalk, where were you all thos

Re: [Pharo-users] Threaded callbacks with FFI

2014-09-25 Thread p...@highoctane.be
Le 25 sept. 2014 11:32, "Annick Fron"  a écrit :
>
> Hi,
>
> I am calling C from pharo with a callback,  and it seems the callback is
called in another thread.
> I can’t wrap the block in a process, because the return will be wrong,
how can I do ???
>
Can you send us sample code ?
> Annick
>


[Pharo-users] Loading PetitParser loads a hell of a lot of things... is there a terser version?

2014-09-25 Thread p...@highoctane.be
I am loading PetitParser in my image but it takes a lng time to load
and below is what I see in my Jenkins console.

Build for that step starts at 13:48:51 and ends at 14:03:15. Phew!

Also a couple errors in loading examples.

What is recommended to use to not have all of this? I just need the parser
and tools to browse the grammars.


[34m13:48:51 :  --> loadPetitParser step starting

Loading 1.6-baseline of ConfigurationOfPetitParser...
Fetched -> ConfigurationOfGlamour-AndreiChis.158 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Loaded -> ConfigurationOfGlamour-AndreiChis.158 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
/var/lib/jenkins/jobs/CXP Frontend/workspace/package-cache
Fetched -> PetitParser-JanKurs.247 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitTests-JanKurs.59 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitAnalyzer-DiegoLont.46 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitSmalltalk-JanKurs.71 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitCSV-tg.7 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitJson-DamienCassou.8 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitMSE-AndreHora.21 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitManifestMf-tg.9 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitRegex-JanKurs.29 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitXml-JanKurs.36 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitXPath-EstebanLorenzano.7 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> PetitIslands-JanKurs.9 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Fetched -> Factorial-Language-lr.6 ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/ ---
http://smalltalkhub.com/mc/Moose/PetitParser/main/
Project: Glamour development [2.91-baseline]
Fetched -> ConfigurationOfGraphET-TudorGirba.8 ---
http://smalltalkhub.com/mc/ObjectProfile/GraphET/main/ ---
http://smalltalkhub.com/mc/ObjectProfile/GraphET/main/
Loaded -> ConfigurationOfGraphET-TudorGirba.8 ---
http://smalltalkhub.com/mc/ObjectProfile/GraphET/main/ ---
/var/lib/jenkins/jobs/CXP Frontend/workspace/package-cache
Fetched -> ConfigurationOfRubric-AndreiChis.7 ---
http://smalltalkhub.com/mc/AlainPlantec/Rubric/main/ ---
http://smalltalkhub.com/mc/AlainPlantec/Rubric/main/
Loaded -> ConfigurationOfRubric-AndreiChis.7 ---
http://smalltalkhub.com/mc/AlainPlantec/Rubric/main/ ---
/var/lib/jenkins/jobs/CXP Frontend/workspace/package-cache
Fetched -> ConfigurationOfRoassal-StephaneDucasse.1195 ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/ ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/
Loaded -> ConfigurationOfRoassal-StephaneDucasse.1195 ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/ ---
/var/lib/jenkins/jobs/CXP Frontend/workspace/package-cache
Fetched -> Glamour-Announcements-TudorGirba.7 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Fetched -> Glamour-Helpers-AndreiChis.35 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Fetched -> Glamour-Core-AndreiChis.277 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Fetched -> Glamour-Presentations-TudorGirba.157 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Fetched -> Glamour-Browsers-TudorGirba.104 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Fetched -> Glamour-Examples-StephanEggermont.284 ---
http://smalltalkhub.com/mc/Moose/Glamour/main/ ---
http://smalltalkhub.com/mc/Moose/Glamour/main/
Project: Roassal for Glamour development [0.7-baseline]
Fetched -> Roassal-AlexandreBergel.759 ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/ ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/
Fetched -> RoassalMorphic-AlexandreBergel.175 ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/ ---
http://smalltalkhub.com/mc/ObjectProfile/Roassal/main/
Fetched -> RoassalExtras-AlexandreBergel.61 ---
http:/

Re: [Pharo-users] Ridiculous we are

2014-09-26 Thread p...@highoctane.be
I'd love another title for this thread.

It depresses me.

Phil

On Fri, Sep 26, 2014 at 8:48 PM, stepharo  wrote:

> Sven I love this chapter.
> I will read it calmly now.
>
> Stef
>
> On 25/9/14 07:23, Sven Van Caekenberghe wrote:
>
>> On 25 Sep 2014, at 01:04, Alain Rastoul  wrote:
>>
>>  Le 25/09/2014 00:06, Sven Van Caekenberghe a écrit :
>>>
 Alain,
 The character encoding situation in Pharo is pretty good actually. The
 only problem is that there is some old school code left that encodes
 strings into strings, but today you can easily write much better and
 conceptually correct code.

 You could have a look at this draft chapter of the upcoming 'Enterprise
 Pharo' book that I am currently writing:

http://stfx.eu/EnterprisePharo/Zinc-Encoding-Meta/

 Concerning file system paths, FilePathEncoder and FilePluginPrimitives
 already do the right thing.

 Now, your idea about using UTF-8 to represent internal Strings is
 something that has been discussed before and in many other languages as
 well. The short answer is that due to it being variable length, the
 inefficiency is (probably) just too high. Simple indexed access becomes a
 problem, let alone more complex string manipulations. I am not saying that
 it cannot be done, I think it is just not worth the trouble. The current
 solution in Pharo with ByteString and WideString is quite nice (check the
 chapter I mentioned before).

 Sven

  Very interesting !
>>> It seems that most of what I was saying is already here :)
>>> I was not saying that Pharo should use utf8 (I mentionned utf8 because
>>> it is a standard, but I find the variable length encoding very weird), I
>>> was rather talking of using WideString in UTF 16 or 32 and that's done.
>>> I saw asWideString but didn't know about automatic convertion or
>>> codepoint selector and internal wide string support.
>>> Does it means that Pharo Greek users (for example) use WideString for
>>> Strings without having to specify it or make explicit convertions (except
>>> of course when dealing with bytes if they want to) ?
>>> If yes, very good, job is almost done :)
>>> (personnally I would also deprecate ByteString, and get rid of it, just
>>> my opinion).
>>> Thanks for the link, another good chapter .
>>>
>>> Regards,
>>>
>>> Alain
>>>
>> Yes, the Greek users won't notice a difference, it is all transparent.
>> ByteString is important because it is an optimalization of the most common
>> case. As a normal user you should only think of abstract Strings and never
>> use #asByteString (but use proper encoding).
>>
>> Feedback on the chapter is always welcome.
>>
>> Sven
>>
>>
>
>
>


Re: [Pharo-users] Unicode support in Pharo

2014-09-27 Thread p...@highoctane.be
https://en.wikipedia.org/wiki/Open-source_Unicode_typefaces is also
interesting.

Phil



On Sat, Sep 27, 2014 at 12:41 PM, Alain Rastoul 
wrote:

> Le 27/09/2014 12:32, Sven Van Caekenberghe a écrit :
>
>>
>> On 27 Sep 2014, at 05:51, Alain Rastoul  wrote:
>>
>>  Le 27/09/2014 01:02, Sven Van Caekenberghe a écrit :
>>>

 On 26 Sep 2014, at 23:22, Alain Rastoul  wrote:

  Pasting a Greek string in a workspace shows hieroglyphs (editors?
> morph?), but GT Inspector display is ok.
>

 That is a font issue. Check your font settings in the Settings Browser.

 Like I mentioned in the chapter, you could try to use 'Arial Unicode
 MS'.

 I would guess you use Source Code Pro for code panes (like the
 workspace) and Open Sans for the rest. Source Code Pro has limited Unicode
 support. GT probably uses only Open Sans.

  Ouch, forgot about different font settings for morphic elements, and
>>> evident, GTInspector could not display correctly if editor would not deal
>>> with WideString (forgot about bytestring/widestring transparency?).
>>> BTW I do not have Arial unicode MS on my system, it comes with MS
>>> Office, but Deja Vu and Bitmap Deja vu display some Greek chars correctly.
>>>
>>
>> It is a TrueType font, you have to enable it in System Setting, then you
>> should see a very long list of fonts to choose from, not just one or two.
>>
>>
>>
>>  True type fonts are enabled on my system and I have a lot of fonts, but
> no Arial unicode MS. It doesn't hurt me not to have it, it's my personal
> laptop :)
> List of  "products that supply this font" here:
> http://www.microsoft.com/typography/fonts/font.aspx?FMID=1081
>
> Regards,
>
> Alain
>
>
>
>


Re: [Pharo-users] Installing GToolkit

2014-10-04 Thread p...@highoctane.be
The following works for me on Pharo 3.0:

Gofer new
 url: 'http://www.smalltalkhub.com/mc/Moose/GToolkit/main';
 configuration;
 load.
#ConfigurationOfGToolkit asClass loadDevelopment.

"Use the inspector"
#GTInspector asClass registerToolsOn: Smalltalk tools.
"Use the debugger"
#GTGenericStackDebugger asClass registerToolsOn: Smalltalk tools.
"Use the playground"
#GTPlayground asClass registerToolsOn: Smalltalk tools.

"For back to normal workspace"
#Workspace asClass registerToolsOn: Smalltalk tools.

HTH

Phil



On Sat, Oct 4, 2014 at 8:07 PM, Evan Donahue  wrote:

> Hello,
>
> I am trying to check out GTPlaygroundl, but I can't seem to get it working
> and was wondering if anyone had any idea what I might be overlooking.
>
> I download a new image with curl get.pharo.org | bash
> I run, from http://www.humane-assessment.com/blog/installing-gtoolkit
>
> Gofer new
>  smalltalkhubUser: 'Moose' project: 'GToolkit';
>  configuration;
>  loadDevelopment.
> #GTImageSetupCommandLineHandler asClass new activate
>
> It loads for a while and then the image closes. When I open it again the
> background is white and my settings have been wiped. The playground does
> appear, but it doesn't seem to work properly (there seems to be no way to
> advance the miller columns). Am I looking at the wrong installation
> information?
>
> Thanks,
> Evan
>
>
>
>


Re: [Pharo-users] Using a private git repository with Metacello

2014-10-11 Thread p...@highoctane.be
Very nice to have BitBucket support!

Private repositories for free, that's golden.

Thx
Phil

On Sat, Oct 11, 2014 at 10:40 AM, Julien Delplanque 
wrote:

> Thanks a lot I'll try this out!
>
> Julien
>
>
> On 09/10/14 18:37, Dale Henrichs wrote:
> > Julien,
> >
> > I recently added bitbucket:// support to metacello[1].
> >
> > If you follow the installation instructions here[2], you can get the
> > support loaded into Pharo3.0.
> >
> > Dale
> >
> > [1] https://groups.google.com/forum/#!topic/metacello/0vOzvQL10cQ
> > [2] https://github.com/dalehenrich/metacello-work#pharo30
> >
> > On Wed, Oct 8, 2014 at 1:44 AM, Julien Delplanque 
> wrote:
> >
> >> Hello,
> >>
> >> Is it possible to use Metacello to load a Pharo project from a private
> >> git repository hosted on bitbucket for example? If it is, how?
> >>
> >> To load project from github I use:
> >>
> >> Metacello new
> >> baseline: 'Project';
> >> repository: 'github://owner/reponame/repository';
> >> load.
> >>
> >> Is there a prefix for a git repository that is not hosted on github?
> >>
> >> Also, I think Metacello use HTTP to download the project, am I right? Is
> >> it possible to make it use ssh?
> >>
> >> Thanks in advance,
> >>
> >> Julien
> >>
> >>
>
>
>
>


Re: [Pharo-users] About Zinc http components

2014-10-11 Thread p...@highoctane.be
Alain,​

Yes, 0mq seems to be a good way to go as there is just more support across
the board.

Have you a project on Smalltalkhub (or elsewhere) with your experiments so
that I could have a look?
I've updated the 0MQ bindings page to list the smalltalkhub pharo client
and also had a look at what was in the GST client.

It would be nice to port the GST code to Pharo so that we would have a nice
package.

0mq could help with the multicore support very nicely. We are going to use
SDL for low level, why not go 0mq for interimage communication? It makes
sense to me.

Phil


Re: [Pharo-users] "Tabular" announcement: support of Excel/Calc spreadsheets formats

2014-10-14 Thread p...@highoctane.be
Loaded fine in my 3.0 and got the XLSX sample in $HOME.

Great to have something like this!

Phil




On Tue, Oct 14, 2014 at 10:39 AM, Юрий Мироненко 
wrote:

> Couple years after failing of the last, GSoC-powered effort to implement
> Excel/Calc support, I come to the point when I need it desperately.
> Therefore I started Tabular (ss3.gemstone.com/ss/Tabular.html) package.
>
> It's now very early stages, and exporting code is quite dirty - but it
> works as proof-of-concept, generating XLSX files with cells meging support
> - which is, anyway, more than we have in SCV. It was already used in
> production code, and already generating tax reports or something like this.
>
> Some of other members of RSUG looks interested in participating in this
> development, so we may expect significiant progress in nearest future.
>


Re: [Pharo-users] FFI syntax

2014-10-16 Thread p...@highoctane.be
I can push RFB in there as it seems to be missing.

Phil

On Thu, Oct 16, 2014 at 8:49 AM, Torsten Bergmann  wrote:

> >I can not even find up to date information on how to *install* current
> >working FFI
>
> In Pharo 3.0 open the world menu, then "Tools", then "Config browser"
> and there look for "FFI" in the list ...
>
> If people would care on providing easy access to own packages
> life would be easy for all.
>
> Bye
> T.
>
>
>


Re: [Pharo-users] FFI syntax

2014-10-16 Thread p...@highoctane.be
Works fine here with TightVNC.

Worked all evening on a remote box that was quite far in FullHD.

I noticed some missing keybindings (numeric pad for example). But that's
because the supported mappings in RFB are incomplete, not because of bugs.

Phil
​


Re: [Pharo-users] [squeak-dev] Using libraries in FFI

2014-10-22 Thread p...@highoctane.be
Try to run pharo with strace.

That way you will see all syscalls including libraries opens that pharo
does attempt.

That's what I do when trying to figure out such things.

HTH
Phil



On Wed, Oct 22, 2014 at 2:45 PM, Annick Fron  wrote:

> Hi Eliot,
>
> My problem is not with the VM, my problem is with my own library
> that I connect to through FFI.
> I know where the libraries are !
>
> I have tried to add them in /etc/ld.so.conf.d , that does not work.
> I have tried export LD_LIBRARY_PATH, but somehow it erases some libraries
> needed by pharo.
> I have done sudo ldconfig ...
>
> In fact I have one library that depends from another one.
> In FFI I call one method which calls another method in the other library.
> I have tried to create symbolics links in the directory …
> I have checked that nm gives the right symbol with the right type ..
>
> So I have no idea what to try now !
>
> Annick
>
> Le 22 oct. 2014 à 12:46, Eliot Miranda  a écrit :
>
> > Hi Annick,
> >
> > LD_LIBRARY_PATH should be set to point to the relevant directories,
> but this can be tricky as there is a lot if variation across Linux distros
> as to where libraries are kept.  The squeak script that comes with the Cog
> VMs extends LD_LIBRARY_PATH, so if you know where your libraries are you
> can use the script to find the other libraries the VM needs (c library and
> plugins).
> >
> > Eliot (phone)
> >
> > On Oct 22, 2014, at 2:55 AM, Annick Fron  wrote:
> >
> >> Hi,
> >>
> >> I am using a module in FFI which depends on a large library let’s say
> 10 dynamic .so files in a directory.
> >> How is it possible to use this library without making all symbolic
> links ?
> >>
> >> Annick
> >
>
>
>
>


Re: [Pharo-users] Starting a pool of worker images using command line parameters

2014-10-23 Thread p...@highoctane.be
On Thu, Oct 23, 2014 at 11:11 PM, Esteban A. Maringolo  wrote:

> 2014-10-23 17:04 GMT-03:00 Sven Van Caekenberghe :
>
> >> Why do you use the pharo shell script instead of pharo-vm with
> >> --no-display? Is there any benefit other than having the pwd set to
> >> the image location? And hence, the argument script should be relative
> >> to the image.
> >
> > No particular reason, mostly because I hate adding the --no-display
> > But yes, I usually bypass the script and use the executable directly.
>
> I don't know how Pharo resolves the file names by default.
>
> Pharo's FileLocator seems to provide something similar to the
> Dolphin's FileLocator I'm used to work with  (see attached image) to
> avoid the "resolution guessing" of relative paths when defined in the
> context of a script or app code (e.g. to specify template files).
> I should use it more. :)
>
> > All this sharing, talking & discussing, even over small issues and style
> is important, we can all learn a lot from each other and save time and
> money.
>
> Absolutely.
>
> I'd like to know the development process of others, from SCM to
> building, deploying and server provisioning.
>
> After a year o Pharo development I think I'm ready to embrace a CI
> server (I already use scripts to build images), but I think I will
> move all my repositories to git before.
>

I have been using Jenkins for a while, due to Sebastian kicking my ass to
do so.
I am very glad I did. It brings a lot of confidence in rebuilding it all
quickly.


> However, my remote server provisioning is still manual, and too
> rudimentary even for my own taste. If I could speed up this, I would
> deliver features faster to my customers. Now everything runs inside a
> two week sprint window.
>

Now investigating Ansible (and the hello-pharo project on GH as a start).
Takes a moment to sink in but it is very useful.

I see that you use supervisord. I am looking into monit for keeping things
alive.
Maybe can we compare notes on these.

Phil


> Regards,
>
> Esteban A. Maringolo
>


Re: [Pharo-users] Starting a pool of worker images using command line parameters

2014-10-23 Thread p...@highoctane.be
On Fri, Oct 24, 2014 at 12:50 AM, Luc Fabresse 
wrote:

> Hi,
>
>
>> Note that zeroconf handlers allow you to build images incrementally (the
>> image is saved after each build), which is way faster than always starting
>> from scratch.
>>
>
> what are zeroconf "handlers"?
>

the things you get in the list when you do ./pharo someimage.image --list

So "save" is one.

There is one in here if you like a sample.
https://github.com/philippeback/Bubble


> because I use zeroconf to rebuild images and it is slow because it
> downloads the vm, the image, the mcz then installing, ...
> did I missed something?
>

No, but as my full build takes half an hour on a powerful box, this is not
practical to do like that.
So:

CI JOB 1 (half an hour, every once in a while)
---
- get pharo
- get image
- build "baseworker" image with standard packages etc

CI JOB2 (whenever a commit is done in git, lasts a minute max)
--
- take baseworker
- pull from repo
- build user code upon the base worker

HTH
Phil

>
> thx, Sven and Esteban, I like reading development and deployment processes
> from experienced people!
>
> #Luc
>
>
>>
>> > After a year o Pharo development I think I'm ready to embrace a CI
>> > server (I already use scripts to build images), but I think I will
>> > move all my repositories to git before.
>>
>> These are orthogonal decisions, most CI jobs on the Pharo contribution
>> server run against StHub.
>>
>> > However, my remote server provisioning is still manual, and too
>> > rudimentary even for my own taste. If I could speed up this, I would
>> > deliver features faster to my customers. Now everything runs inside a
>> > two week sprint window.
>>
>> I am not into provisioning myself, but more automation is always good,
>> though sometimes setting up and maintaining all these things takes a lot of
>> time as well.
>>
>> > Regards,
>> >
>> > Esteban A. Maringolo
>> > 
>>
>>
>>
>


  1   2   3   4   5   6   7   >