Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Hernán Morales Durand
Hi Thierry,

Big thanks, with your suggestions I could install my package with the
DeployUtils depdendency resolved, and all its dependencies
(SystemLogger) also were loaded. I have to modify manually the
baseline: method in my config because the Versionner expected a
ConfigurationOf to be added as dependency.

The ConfigurationOf is in the repository
http://www.smalltalkhub.com/#!/~SergeStinckwich/CORMAS

Cheers,

Hernán


2017-09-27 4:41 GMT-03:00 Thierry Goubier :
> Hi Hernán,
>
> I think what is happening is you're not including completely the DeployUtils
> baseline. You need to write something like:
>
> spec baseline: 'DeployUtils' with: [
> spec repository: 'github://fstephany/DeployUtils/repository'];
> import: 'DeployUtils'.
>
> And have one of the packages (or groups?) of DeployUtils listed as
> dependency of one of your packages.
>
> Regards,
>
> Thierry
>
> 2017-09-25 20:19 GMT+02:00 Hernán Morales Durand :
>>
>> I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
>> following instructions at:
>>
>> https://github.com/fstephany/DeployUtils
>>
>> If I include the dependency as suggested:
>>
>> spec baseline: 'DeployUtils' with: [
>> spec repository: 'github://fstephany/DeployUtils/repository'].
>>
>> then when I load the configuration I get:
>>
>> Error: Unable to resolve project package for 'DeployUtils'. It is
>> likely that that the configuration referencing this project will not
>> validate properly (see MetacelloToolBox
>> class>>validateConfiguration:).
>>
>> If I include the dependency as:
>>
>> spec
>> project: 'DeployUtils' with: [
>> spec
>> className: #DeployUtils;
>> versionString: 'baseline';
>> repository:
>> 'github://fstephany/DeployUtils/repository' ];
>>
>> Then I get DU multiple missing dependencies:
>>
>> This package depends on the following classes:
>>   StringStreamLogger
>>   Log
>>   StdoutStreamLogger
>> You must resolve these dependencies before you will be able to load
>> these definitions:
>>   DUFileLogger
>>   DUFileLogger>>#withFileLocator:
>>   DUFileLogger>>#addLogHook:
>>   DUFileLogger>>#defaultFormatter
>>   DUFileLogger>>#defaultStream
>>   DUFileLogger>>#fileLocator:
>>   DUStdoutStreamLogger
>>   DUStdoutStreamLogger>>#addLogHook:
>>   Log>>#debug:tag:
>>   Log>>#info:tag:
>>   Log>>#warning:tag:
>>
>> And finally a MNU with
>>
>> #loader: was sent to nil
>>
>> (also when I try to inspect I got a #gtInspectorProjectsIn: was sent to
>> nil)
>> Any ideas?
>> Cheers,
>>
>> Hernán
>>
>



Re: [Pharo-users] Roasssal not working on Windows with Pharo 6.1

2017-09-27 Thread Hernán Morales Durand
I couldn't reproduce any problem installing Pharo 6.1 in Windows 8.1
from command line:

wget -O- get.pharo.org/61+vm | bash -

And then installing Roassal from the Catalog Browser. All the examples
ran wiithout problems.
Cheers

Hernán


2017-09-23 5:57 GMT-03:00 kmo :
> Is it just me or my systems but is there a major problem with Roassal on
> Pharo 6.1 on Windows?
>
> At work on my Windows 7 machine, Roassal installs from the catalog browser
> but the examples will not run. I get an error - External module not found.
> it seems to be looking for the Surface dll which is definitely present in
> the pharo folder.
>
> On my Windows 10 netbook, Roassal will not even install from the catalog
> browser. It starts to install then comes up with an unhelpful "something has
> gone wrong" message.
>
> Roassal still works in Pharo 5. So is this just a 6.1 issue?
>
>
>
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html
>



Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Igor Stasenko
imo, best what could be done is to forget about 32-bit version and use
64-bit VM & libs, to avoid
problems like above.
but for that, i need a 64-bit VM/image pair for a start,
because one that you gave me is 32-bit.. and hence drags all the trouble
with all this .so dependency zoo..

-- 
Best regards,
Igor Stasenko.


Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Igor Stasenko
apparently the SDL2 library is not in LD search path

ldd libSDL2DisplayPlugin.so
linux-gate.so.1 =>  (0xf77e9000)
libSDL2-2.0.so.0 => not found

libc.so.6 => /lib/i386-linux-gnu/libc.so.6 (0xf75dd000)
/lib/ld-linux.so.2 (0x56573000)

so it simply doesn't starts,

so i installed
sudo apt-get install libsdl2-2.0-0:i386

but then i found that i need to install 32-bit version of cairo as well..
but alas.. here is where i stuck:

sudo apt-get install libcairo2:i386
Reading package lists... Done
Building dependency tree
Reading state information... Done
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
 libtheora0 : Depends: libcairo2 (>= 1.2.4) but it is not going to be
installed
E: Error, pkgProblemResolver::Resolve generated breaks, this may be caused
by held packages.
 

something in my installation are in conflict with 32-bit version of cairo..
that's weird..
but unmet dependencies/dependency conflict resolution of linux .deb
packages is not my strong side.
So, it would be nice if someone could help how to proceed with that.




On 28 September 2017 at 01:41, Igor Stasenko  wrote:

> okay, first, i have to change the path to SDL2 library, because on my
> machine it's in
> /usr/lib/x86_64-linux-gnu/libSDL2-2.0.so.0
> but there's another trouble:
> browsing is incredibly slooow...
> First, i used finder to look for 'libSDL2-2.0.so.0' in sources. it took
> like 2 minutes to go through first few classes with starting A letter in
> their name.
> Then i lost temper, interrupted it and decided to browse into SDL bindings
> manually - clicked on OSWindow-SDL2 package... and its still 100% CPU and
> didn't opened
> while i typing this whole message.
>
> What is going on? Are .sources file corrupted or what?
>
>
>
> On 28 September 2017 at 01:27, Igor Stasenko  wrote:
>
>>
>>
>> On 27 September 2017 at 22:54, Stephane Ducasse 
>> wrote:
>>
>>> Igor I will share the dropbox for you.
>>> What would be great is to port the code of clement to Pharo 6.1 or
>>> even 70 to check SDL20
>>> Esteban was integrating some of the code of ronie.
>>>
>>> Downloading..
>> Would be nice, if someone could give me short directions how to test it ,
>> what to run and what to expect. Because i am clearly was out of context for
>> too long.
>>
>>
>>> Stef
>>>
>>>
>>> On Wed, Sep 27, 2017 at 1:05 PM, Igor Stasenko 
>>> wrote:
>>> > i'm on ubuntu right now, so i could help with trying & testing things
>>> and/or
>>> > diagnosing problems. Just tell me what to do
>>> >
>>> >
>>> > --
>>> > Best regards,
>>> > Igor Stasenko.
>>>
>>>
>>
>>
>> --
>> Best regards,
>> Igor Stasenko.
>>
>
>
>
> --
> Best regards,
> Igor Stasenko.
>



-- 
Best regards,
Igor Stasenko.


Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Igor Stasenko
okay, first, i have to change the path to SDL2 library, because on my
machine it's in
/usr/lib/x86_64-linux-gnu/libSDL2-2.0.so.0
but there's another trouble:
browsing is incredibly slooow...
First, i used finder to look for 'libSDL2-2.0.so.0' in sources. it took
like 2 minutes to go through first few classes with starting A letter in
their name.
Then i lost temper, interrupted it and decided to browse into SDL bindings
manually - clicked on OSWindow-SDL2 package... and its still 100% CPU and
didn't opened
while i typing this whole message.

What is going on? Are .sources file corrupted or what?



On 28 September 2017 at 01:27, Igor Stasenko  wrote:

>
>
> On 27 September 2017 at 22:54, Stephane Ducasse 
> wrote:
>
>> Igor I will share the dropbox for you.
>> What would be great is to port the code of clement to Pharo 6.1 or
>> even 70 to check SDL20
>> Esteban was integrating some of the code of ronie.
>>
>> Downloading..
> Would be nice, if someone could give me short directions how to test it ,
> what to run and what to expect. Because i am clearly was out of context for
> too long.
>
>
>> Stef
>>
>>
>> On Wed, Sep 27, 2017 at 1:05 PM, Igor Stasenko 
>> wrote:
>> > i'm on ubuntu right now, so i could help with trying & testing things
>> and/or
>> > diagnosing problems. Just tell me what to do
>> >
>> >
>> > --
>> > Best regards,
>> > Igor Stasenko.
>>
>>
>
>
> --
> Best regards,
> Igor Stasenko.
>



-- 
Best regards,
Igor Stasenko.


Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Igor Stasenko
On 27 September 2017 at 22:54, Stephane Ducasse 
wrote:

> Igor I will share the dropbox for you.
> What would be great is to port the code of clement to Pharo 6.1 or
> even 70 to check SDL20
> Esteban was integrating some of the code of ronie.
>
> Downloading..
Would be nice, if someone could give me short directions how to test it ,
what to run and what to expect. Because i am clearly was out of context for
too long.


> Stef
>
>
> On Wed, Sep 27, 2017 at 1:05 PM, Igor Stasenko  wrote:
> > i'm on ubuntu right now, so i could help with trying & testing things
> and/or
> > diagnosing problems. Just tell me what to do
> >
> >
> > --
> > Best regards,
> > Igor Stasenko.
>
>


-- 
Best regards,
Igor Stasenko.


Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Hernán Morales Durand
Hi Stef

2017-09-27 4:32 GMT-03:00 Stephane Ducasse :
> Hi hernan
>
> Are you creating a configurationOf or a baselineOf?

ConfigurationOf

> Do you have the Log and StringStreamLogger in your image? Because I
> have the impression that they are not in
> the DeployUtils package.

If I install DeployUtils using the Metacello script in the page, Log
and StringStreamLogger are included. So the problem only arises when
trying to include DeployUtils as dependency in a Configuration.

> Are the classes coming from the SystemLogger we wrote with Norbert?

Yes but from MetaRepoForPharo30. The dependency is actually in
ConfigurationOfDeployUtils in the #baseline: method

spec project: 'SystemLogger' with: [
spec
className: #ConfigurationOfSystemLogger;
versionString: '1.5';
repository:
'http://smalltalkhub.com/mc/Pharo/MetaRepoForPharo30/main/' ].

Hernán

> Because if this is the case you should add this dependency.
>
> Stef
>
>
> On Mon, Sep 25, 2017 at 8:19 PM, Hernán Morales Durand
>  wrote:
>> I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
>> following instructions at:
>>
>> https://github.com/fstephany/DeployUtils
>>
>> If I include the dependency as suggested:
>>
>> spec baseline: 'DeployUtils' with: [
>> spec repository: 'github://fstephany/DeployUtils/repository'].
>>
>> then when I load the configuration I get:
>>
>> Error: Unable to resolve project package for 'DeployUtils'. It is
>> likely that that the configuration referencing this project will not
>> validate properly (see MetacelloToolBox
>> class>>validateConfiguration:).
>>
>> If I include the dependency as:
>>
>> spec
>> project: 'DeployUtils' with: [
>> spec
>> className: #DeployUtils;
>> versionString: 'baseline';
>> repository: 'github://fstephany/DeployUtils/repository' 
>> ];
>>
>> Then I get DU multiple missing dependencies:
>>
>> This package depends on the following classes:
>>   StringStreamLogger
>>   Log
>>   StdoutStreamLogger
>> You must resolve these dependencies before you will be able to load
>> these definitions:
>>   DUFileLogger
>>   DUFileLogger>>#withFileLocator:
>>   DUFileLogger>>#addLogHook:
>>   DUFileLogger>>#defaultFormatter
>>   DUFileLogger>>#defaultStream
>>   DUFileLogger>>#fileLocator:
>>   DUStdoutStreamLogger
>>   DUStdoutStreamLogger>>#addLogHook:
>>   Log>>#debug:tag:
>>   Log>>#info:tag:
>>   Log>>#warning:tag:
>>
>> And finally a MNU with
>>
>> #loader: was sent to nil
>>
>> (also when I try to inspect I got a #gtInspectorProjectsIn: was sent to nil)
>> Any ideas?
>> Cheers,
>>
>> Hernán
>>
>



Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Dale Henrichs

Hernán.

Well I tried to look at this, but the first problem I ran into is that the 
package name is a Symbol (#ConfigurationOfSystemLogger) and the package name is 
supposed to be a String --- I'm trying to look at this from GemStone --- the 
package name is also a Symbol (#DeployUtils), so I cannot actually try to 
execute the Metacello record code to see what might be going wrong ... since 
the Metacello error is that the package is that it cannot resolve the project 
package name #DeployUtils, this might be the root cause of the problem ... the 
error also says that the there are likely to be invalid configurations involved 
as well ...

Your second error gives me a bit more of a clue as to what might be going on ... again 
this points to a problem with the DeployUtils baseline: there are no dependencies 
declared between the DeployUtils package and the SystemLogger project, so Metacello is 
"free to load the two in any order" ... from your second error message it seems 
that in the absence of dependencies, Metacello loaded the package before loading 
SystemLogger ...

Dale


On 09/27/2017 12:53 PM, Stephane Ducasse wrote:

Thierry what is import:
and why should it be recursive?

On Wed, Sep 27, 2017 at 9:41 AM, Thierry Goubier
 wrote:

Hi Hernán,

I think what is happening is you're not including completely the DeployUtils
baseline. You need to write something like:

spec baseline: 'DeployUtils' with: [
 spec repository: 'github://fstephany/DeployUtils/repository'];
 import: 'DeployUtils'.

And have one of the packages (or groups?) of DeployUtils listed as
dependency of one of your packages.

Regards,

Thierry

2017-09-25 20:19 GMT+02:00 Hernán Morales Durand :

I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
following instructions at:

https://github.com/fstephany/DeployUtils

If I include the dependency as suggested:

spec baseline: 'DeployUtils' with: [
 spec repository: 'github://fstephany/DeployUtils/repository'].

then when I load the configuration I get:

Error: Unable to resolve project package for 'DeployUtils'. It is
likely that that the configuration referencing this project will not
validate properly (see MetacelloToolBox
class>>validateConfiguration:).

If I include the dependency as:

 spec
 project: 'DeployUtils' with: [
 spec
 className: #DeployUtils;
 versionString: 'baseline';
 repository:
'github://fstephany/DeployUtils/repository' ];

Then I get DU multiple missing dependencies:

This package depends on the following classes:
   StringStreamLogger
   Log
   StdoutStreamLogger
You must resolve these dependencies before you will be able to load
these definitions:
   DUFileLogger
   DUFileLogger>>#withFileLocator:
   DUFileLogger>>#addLogHook:
   DUFileLogger>>#defaultFormatter
   DUFileLogger>>#defaultStream
   DUFileLogger>>#fileLocator:
   DUStdoutStreamLogger
   DUStdoutStreamLogger>>#addLogHook:
   Log>>#debug:tag:
   Log>>#info:tag:
   Log>>#warning:tag:

And finally a MNU with

#loader: was sent to nil

(also when I try to inspect I got a #gtInspectorProjectsIn: was sent to
nil)
Any ideas?
Cheers,

Hernán






Re: [Pharo-users] Roasssal not working on Windows with Pharo 6.1

2017-09-27 Thread Jan Blizničenko
I recommend replacing your VM by last stable one from
http://files.pharo.org/vm/pharo-spur32/win/stable-20170827.zip and if it
does not help, replacing the image by current one from
http://files.pharo.org/image/60/60510.zip

You probably use older image or VM that either contained some kind of bug
that has been already fixed in current version, or something has been
changed, Roassal adapted to it, but your older image or VM does not contain
that change to which Roassal is adapted now.

Jan


kmo wrote
> Many thanks. I tried this and it worked fine and Roassal installs and
> runs.
> 
> I then typed the same gofer command into my original Pharo 6.1 directory
> and
> I got an error - #withSqueakLineEndings was sent to nil. Perhaps that's a
> clue to what was going wrong.
> 
> 
> 
> 
> 
> --
> Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html





--
Sent from: http://forum.world.st/Pharo-Smalltalk-Users-f1310670.html



Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Stephane Ducasse
Igor I will share the dropbox for you.
What would be great is to port the code of clement to Pharo 6.1 or
even 70 to check SDL20
Esteban was integrating some of the code of ronie.

Stef


On Wed, Sep 27, 2017 at 1:05 PM, Igor Stasenko  wrote:
> i'm on ubuntu right now, so i could help with trying & testing things and/or
> diagnosing problems. Just tell me what to do
>
>
> --
> Best regards,
> Igor Stasenko.



Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Stephane Ducasse
Thierry what is import:
and why should it be recursive?

On Wed, Sep 27, 2017 at 9:41 AM, Thierry Goubier
 wrote:
> Hi Hernán,
>
> I think what is happening is you're not including completely the DeployUtils
> baseline. You need to write something like:
>
> spec baseline: 'DeployUtils' with: [
> spec repository: 'github://fstephany/DeployUtils/repository'];
> import: 'DeployUtils'.
>
> And have one of the packages (or groups?) of DeployUtils listed as
> dependency of one of your packages.
>
> Regards,
>
> Thierry
>
> 2017-09-25 20:19 GMT+02:00 Hernán Morales Durand :
>>
>> I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
>> following instructions at:
>>
>> https://github.com/fstephany/DeployUtils
>>
>> If I include the dependency as suggested:
>>
>> spec baseline: 'DeployUtils' with: [
>> spec repository: 'github://fstephany/DeployUtils/repository'].
>>
>> then when I load the configuration I get:
>>
>> Error: Unable to resolve project package for 'DeployUtils'. It is
>> likely that that the configuration referencing this project will not
>> validate properly (see MetacelloToolBox
>> class>>validateConfiguration:).
>>
>> If I include the dependency as:
>>
>> spec
>> project: 'DeployUtils' with: [
>> spec
>> className: #DeployUtils;
>> versionString: 'baseline';
>> repository:
>> 'github://fstephany/DeployUtils/repository' ];
>>
>> Then I get DU multiple missing dependencies:
>>
>> This package depends on the following classes:
>>   StringStreamLogger
>>   Log
>>   StdoutStreamLogger
>> You must resolve these dependencies before you will be able to load
>> these definitions:
>>   DUFileLogger
>>   DUFileLogger>>#withFileLocator:
>>   DUFileLogger>>#addLogHook:
>>   DUFileLogger>>#defaultFormatter
>>   DUFileLogger>>#defaultStream
>>   DUFileLogger>>#fileLocator:
>>   DUStdoutStreamLogger
>>   DUStdoutStreamLogger>>#addLogHook:
>>   Log>>#debug:tag:
>>   Log>>#info:tag:
>>   Log>>#warning:tag:
>>
>> And finally a MNU with
>>
>> #loader: was sent to nil
>>
>> (also when I try to inspect I got a #gtInspectorProjectsIn: was sent to
>> nil)
>> Any ideas?
>> Cheers,
>>
>> Hernán
>>
>



Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Igor Stasenko
i'm on ubuntu right now, so i could help with trying & testing things
and/or diagnosing problems. Just tell me what to do


-- 
Best regards,
Igor Stasenko.


Re: [Pharo-users] [Pharo-dev] Scraping HTML chapter 2 (soon chapter 3 coming)

2017-09-27 Thread Tudor Girba
Nice work!

Doru


> On Sep 27, 2017, at 9:25 AM, Stephane Ducasse  wrote:
> 
> I came with the idea of this booklet thank to Peter Kenny that kindly
> answered a question on the Pharo mailing-list.
> To help, Peter showed to a Pharoer how to scrap a web site
> using XPath. In addition, some years ago
> I was maintaining Soup a scraping framework because I was scraping
> magic web sites and I wanted an application to manage my magic cards.
> Since then I always wanted to try XPath and in addition I wanted to
> offer this booklet to Peter. Why because I asked Peter
> if he would like to write something and he told that he was at a great
> age where he would not take any commitment.
> I realised that I would like to get as old as him and be able to hack
> like a mad in Pharo with new technology.
> So this booklet is a gift to Peter, a great and gentle Pharoer.
> 
> Stef
> 

--
www.tudorgirba.com
www.feenk.com

"Being happy is a matter of choice."







Re: [Pharo-users] Force headless mode

2017-09-27 Thread Cyril Ferlicot
On Wed, Sep 27, 2017 at 9:21 AM, Stephane Ducasse
 wrote:
> What is important is to understand the ratio attacker vs. defense.
> It is important not to be paranoid.
> - against who are you protect yourself?
> - if you do not ship source code (or if you ofuscate it)
> - you can try remove the decompiler I do not think that people will do much.
> Now again how much time and for what?
>
> Stef
>

We are taking this into consideration.

We have several solutions and we will implement te one with the best
implementation time/protection ratio.

Thank you for the pointers.

-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France



Re: [Pharo-users] Force headless mode

2017-09-27 Thread Cyril Ferlicot
On Tue, Sep 26, 2017 at 8:03 PM, Peter Uhnák  wrote:
> Out of curiosity... how does enforcing headlessness protects code? Wouldn't
> it be still accessible via e.g. TelePharo, or startup script override, or
> anything?
>
> Peter
>
>

This is a first step. This is not all we will do but it is a step
making it hard for people who do not know Pharo to access the code.
There is no solution that would protect us at 100%, so we want a list
of solutions fast to implement and covering a large part of the way to
access to the code.



-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France



Re: [Pharo-users] Force headless mode

2017-09-27 Thread Cyril Ferlicot
On Tue, Sep 26, 2017 at 7:04 PM, Sven Van Caekenberghe  wrote:
>
>
> Why not do as follows:
>
> (1) add some startup code inside the image that tests if the image is running 
> headless, if not exit
> (2) remove some of the command line handlers (especially the ones that 
> execute or load code)
>
> Problem is that you will lock yourself out as well ;-)
>
>

Thank you Sven.

We used your solution (1) and it is indeed a good solution.

Solution (2) was already in our todo list :)

-- 
Cyril Ferlicot
https://ferlicot.fr

http://www.synectique.eu
2 rue Jacques Prévert 01,
59650 Villeneuve d'ascq France



Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Thierry Goubier
Hi Hernán,

I think what is happening is you're not including completely the
DeployUtils baseline. You need to write something like:

spec baseline: 'DeployUtils' with: [
spec repository: 'github://fstephany/DeployUtils/repository'];
import: 'DeployUtils'.

And have one of the packages (or groups?) of DeployUtils listed as
dependency of one of your packages.

Regards,

Thierry

2017-09-25 20:19 GMT+02:00 Hernán Morales Durand :

> I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
> following instructions at:
>
> https://github.com/fstephany/DeployUtils
>
> If I include the dependency as suggested:
>
> spec baseline: 'DeployUtils' with: [
> spec repository: 'github://fstephany/DeployUtils/repository'].
>
> then when I load the configuration I get:
>
> Error: Unable to resolve project package for 'DeployUtils'. It is
> likely that that the configuration referencing this project will not
> validate properly (see MetacelloToolBox
> class>>validateConfiguration:).
>
> If I include the dependency as:
>
> spec
> project: 'DeployUtils' with: [
> spec
> className: #DeployUtils;
> versionString: 'baseline';
> repository: 'github://fstephany/DeployUtils/repository'
> ];
>
> Then I get DU multiple missing dependencies:
>
> This package depends on the following classes:
>   StringStreamLogger
>   Log
>   StdoutStreamLogger
> You must resolve these dependencies before you will be able to load
> these definitions:
>   DUFileLogger
>   DUFileLogger>>#withFileLocator:
>   DUFileLogger>>#addLogHook:
>   DUFileLogger>>#defaultFormatter
>   DUFileLogger>>#defaultStream
>   DUFileLogger>>#fileLocator:
>   DUStdoutStreamLogger
>   DUStdoutStreamLogger>>#addLogHook:
>   Log>>#debug:tag:
>   Log>>#info:tag:
>   Log>>#warning:tag:
>
> And finally a MNU with
>
> #loader: was sent to nil
>
> (also when I try to inspect I got a #gtInspectorProjectsIn: was sent to
> nil)
> Any ideas?
> Cheers,
>
> Hernán
>
>


Re: [Pharo-users] How to find if a method is being executed in a given process

2017-09-27 Thread Stephane Ducasse
Ah ok So you should look at what Pablo did because he is handling
this case for code update,
the idea is that he will put on the stack a kind of notifier so that
you get aware when the m is not on the stack anymore.

Stef

On Mon, Sep 25, 2017 at 6:05 PM, Steven Costiou  wrote:
> Le 2017-09-25 17:47, Stephane Ducasse a écrit :
>
> This is exactly my usecase, i need to remove code that may be called
> by a method on the stack - and i know exactly which method. However my
> base hypothesis is that it is in an already running process (maybe a
> loop) and that part i cannot change. Is there an existing Pharo
> implementation of MethodWrappers ?
>
> How can you remove a method if it may be called?
>
> Stef
>
> Lets say i have the following method:
>
> m
>
> ^self m1
>
> I have dynamically changed the code of m for a specific object o by the
> following:
>
> m
>
> self m2.
>
> ^self m1
>
> m2 is behavior that is dynamically added to the object o.
>
> If i want to revert the object o to its original behavior, that will change
> back m and remove m2, i must be sure that the changed m is not on the stack,
> else it could still call m2 that no longer exists.
>
> Actually i tried Ben's suggestion, and it works. I just ask the process to
> run until the method i target is popped out of the stack and then i can
> remoev my code.
>
> Steven.



Re: [Pharo-users] How to include DeployUtils in a Configuration?

2017-09-27 Thread Stephane Ducasse
Hi hernan

Are you creating a configurationOf or a baselineOf?
Do you have the Log and StringStreamLogger in your image? Because I
have the impression that they are not in
the DeployUtils package.
Are the classes coming from the SystemLogger we wrote with Norbert?
Because if this is the case you should add this dependency.

Stef


On Mon, Sep 25, 2017 at 8:19 PM, Hernán Morales Durand
 wrote:
> I am trying to include DeployUtils in a ConfigurationOf (Pharo 6.1)
> following instructions at:
>
> https://github.com/fstephany/DeployUtils
>
> If I include the dependency as suggested:
>
> spec baseline: 'DeployUtils' with: [
> spec repository: 'github://fstephany/DeployUtils/repository'].
>
> then when I load the configuration I get:
>
> Error: Unable to resolve project package for 'DeployUtils'. It is
> likely that that the configuration referencing this project will not
> validate properly (see MetacelloToolBox
> class>>validateConfiguration:).
>
> If I include the dependency as:
>
> spec
> project: 'DeployUtils' with: [
> spec
> className: #DeployUtils;
> versionString: 'baseline';
> repository: 'github://fstephany/DeployUtils/repository' ];
>
> Then I get DU multiple missing dependencies:
>
> This package depends on the following classes:
>   StringStreamLogger
>   Log
>   StdoutStreamLogger
> You must resolve these dependencies before you will be able to load
> these definitions:
>   DUFileLogger
>   DUFileLogger>>#withFileLocator:
>   DUFileLogger>>#addLogHook:
>   DUFileLogger>>#defaultFormatter
>   DUFileLogger>>#defaultStream
>   DUFileLogger>>#fileLocator:
>   DUStdoutStreamLogger
>   DUStdoutStreamLogger>>#addLogHook:
>   Log>>#debug:tag:
>   Log>>#info:tag:
>   Log>>#warning:tag:
>
> And finally a MNU with
>
> #loader: was sent to nil
>
> (also when I try to inspect I got a #gtInspectorProjectsIn: was sent to nil)
> Any ideas?
> Cheers,
>
> Hernán
>



Re: [Pharo-users] X11 options on Ubuntu VM / Athens rendering problems

2017-09-27 Thread Stephane Ducasse
Hi jeff

you should give a try so that you can push esteban in his fight for a
free host and strong SDL2.0

Stef

On Mon, Sep 25, 2017 at 7:51 AM, Clément Bera  wrote:
>
>
> On Mon, Sep 25, 2017 at 2:33 AM, J.F. Rick  wrote:
>>
>> Hi Clement and and Stef,
>>
>> thanks for sharing. The video looks cool and it seems like a
>> high-performance approach. Unfortunately, it doesn't seem to be working in
>> Linux. I'm attaching the Pharo debug file, but it seems like the Handler
>> being OSNullWindowHandle indicates a problem. I'm also not sure that this
>> approach would allow me to do fullscreen apps. I noticed that your video
>> shows a title bar in MacOS.
>>
>
> I've never made the demo work on linux, I am not surprised it doesn't work.
> This demo is based on the Pharo 4 OSWindow version, and more recent versions
> are working fine on linux.
>
> About fullscreen as I said in the previous mail it is possible to enable it,
> I tried it worked, but I did not do it as I don't think it make sense with
> this game.
>
> I will consider in the future making it work on the latest Pharo version on
> multiple OS if it makes sense to show people how to do it. I'm busy with
> other concerns right now.
>
> Anyway, it's just one approach, you can use another one.
>
>>
>> Cheers,
>>
>> Jeff
>>
>>
>>
>>
>>
>> On Sun, Sep 24, 2017 at 7:53 AM Clément Bera 
>> wrote:
>>>
>>> Hi,
>>>
>>> I describe in the next paragraphs what I do to build application with
>>> Pharo at 50 fps. Now I am using a SDL2 window with OSWindow and not the
>>> default Pharo window for rendering. There is a fullscreen option with
>>> OSWindow, I don't use it but I've just tried it works fine.
>>>
>>> To use Athens/Cairo I start the VM headless and I open from the code a
>>> window using the SDL2 binding (OSWindow), then I extract the window surface
>>> as a cairo surface to draw on it using Athens and I use SDL2 to manage
>>> events (mouse, keyboard). That way I don't even start morphic/WorldMorph
>>> which wastes cpu ressources.
>>>
>>> I built this video game that way:
>>>
>>> https://clementbera.wordpress.com/2016/08/29/sdl2-cairo-headless-for-realtime-native-applications/
>>> https://www.youtube.com/watch?v=srPdFgbyS6s
>>>
>>> The game is running in Pharo 4 (pre-Spur). I configured it to run at 50
>>> fps but from time to time some frames are dropped for performance so I would
>>> say it is running at around 48-49 fps in practice. I think it should work on
>>> the latest Pharo but you need to ask on pharo-dev how to use OSWindow. Some
>>> APIs have changed since Pharo 4. Since the latest Pharo version is now using
>>> Spur I expect the performance to be way better and I think 50 fps is
>>> definitely manageable on a laptop.
>>>
>>> Note that this is still Pharo so if you want something which looks
>>> real-time you need to be careful about you object allocation rate in-between
>>> frame rendering.
>>>
>>> I hope this can help.
>>>
>>> Regards
>>>
>>>
>>>
>>> On Sun, Sep 24, 2017 at 9:43 AM, Stephane Ducasse
>>>  wrote:

 Hi jeff

 let us know if this is working. the start.sh script is not working on
 my machine. but clement made it worked on his machine and he should
 publish a zip.

 Stef



 On Sun, Sep 24, 2017 at 9:39 AM, Stephane Ducasse
  wrote:
 > Yes I will share a dropbox with you for now.
 >
 > On Sat, Sep 23, 2017 at 9:44 PM, J.F. Rick  wrote:
 >> Hi Stef,
 >>
 >> since I'm only doing Athens rendering, it might be possible to do a
 >> native
 >> window implementation. That said, I don't know how to get started
 >> with that.
 >> Documentation seems to be hard to find. The last time I saw any work
 >> on that
 >> it was too early to be usable. I'm also not sure if it solves my "it
 >> needs
 >> to run in fullscreen at full speed" problem. If someone like Clement
 >> could
 >> get me started, that would be awesome.
 >>
 >> Cheers,
 >>
 >> Jeff
 >>
 >> On Fri, Sep 22, 2017 at 12:27 PM Stephane Ducasse
 >> 
 >> wrote:
 >>>
 >>> Hi Jeff
 >>>
 >>> Nice to see you. I do not know anybody running on X11. Esteban is
 >>> working on better SDL20 integration.
 >>> Did you try having a native window? I asked clement if he could
 >>> release the Wizard Battle Arena because it was a game he did in a
 >>> couple of days (yes he is good this guy) and that use cairo athens
 >>> based for drawing on native window.
 >>>
 >>> stef
 >>>
 >>> On Fri, Sep 22, 2017 at 3:11 PM, J.F. Rick  wrote:
 >>> > I'm running a fullscreen Pharo application on Ubuntu and I've
 >>> > noticed
 >>> > that
 >>> > Athens rendering gets way worse (maybe 10 updates per second) when
 >>> > I
 >>> > 

Re: [Pharo-users] Force headless mode

2017-09-27 Thread Stephane Ducasse
What is important is to understand the ratio attacker vs. defense.
It is important not to be paranoid.
- against who are you protect yourself?
- if you do not ship source code (or if you ofuscate it)
- you can try remove the decompiler I do not think that people will do much.
Now again how much time and for what?

Stef

On Tue, Sep 26, 2017 at 8:03 PM, Peter Uhnák  wrote:
> Out of curiosity... how does enforcing headlessness protects code? Wouldn't
> it be still accessible via e.g. TelePharo, or startup script override, or
> anything?
>
> Peter
>
> On Tue, Sep 26, 2017 at 7:04 PM, Sven Van Caekenberghe  wrote:
>>
>>
>> > On 26 Sep 2017, at 18:06, Cyril Ferlicot 
>> > wrote:
>> >
>> > On Tue, Sep 26, 2017 at 5:59 PM, Esteban Lorenzano 
>> > wrote:
>> >>
>> >>
>> >> it is not.
>> >> specially on windows.
>> >>
>> >> vm handles the creation of host window and you will always have one.
>> >>
>> >> now… if you wait one week, I will have ready the (experimental) real
>> >> headless VMs. In my tests, they are working fine but we will still need to
>> >> work when we want to actually start a world window… but that’s another 
>> >> story
>> >> ;)
>> >>
>> >
>> > I don't think we can wait Pharo 7 before doing this task. But I can
>> > still try it when you're done.
>> >
>> > With this, will it be possible to totally disable the non headless
>> > mode in production?
>>
>> Why not do as follows:
>>
>> (1) add some startup code inside the image that tests if the image is
>> running headless, if not exit
>> (2) remove some of the command line handlers (especially the ones that
>> execute or load code)
>>
>> Problem is that you will lock yourself out as well ;-)
>>
>> >> Esteban
>> >>
>> >>
>> >>
>> >
>> >
>> >
>> > --
>> > Cyril Ferlicot
>> > https://ferlicot.fr
>> >
>> > http://www.synectique.eu
>> > 2 rue Jacques Prévert 01,
>> > 59650 Villeneuve d'ascq France
>> >
>>
>>
>