Monthly Archives: February 2017

Consortium action 13 / 17 Feb

17 February 2017:
—————–

* I spent sometime working on UFFI and 64bits.

Sometime ago I started this and found a problem that I talked with Eliot, you can found the rational [here](http://forum.world.st/Support-for-LP64-amp-LLP64-in-FFI-Kernel-td4929946.html) (we need to model in some way the fact that longs have different sizes in different platforms, notably LP64 and LLP64).

In that discussion, with Eliot we proposed to add a new FFI type, a +platformLong+ who will behave as expected. I started to implement but didn’t have the time to finish it and I needed to jump to other  stuff. In the mean time, Ronie found a different workaround: instead adding support in the VM, just map  in image the type to correct size.

This is how it will work:

|===
|Platform
|type
|size
|FFI type
|

|i386
|long
|4
|long
|

|LP64
|long
|8
|long long
|

|LLP64
|long
|4
|long
|
|===

I guess I need to work on the exporter for tables 😉

Ensuring this mappings happens when compiling an UFFI method (and a structure, etc.) we can workaround the plugin limitation.

So I worked taking Ronie’s work, extended it to structures and added my own work on mapping structures  in a ‘platform-agnostic’ way: the idea is to take values by ‘offset’ instead the constant value as it was done up to now. On ‘structure-compilation time’ (it happens first time structure is used on a session), it calculates also the correct field access offsets and structure size.

This is mostly working, it just lacks some testing and pushing it to image… then I can start prepare Athens, SDL2 and libgit2 bindings to work both in 32 and 64 bits 🙂
16 February 2017:
—————–

* I continue enhancing [iceberg](https://github.com/npasserini/iceberg/pull/277) as much as I can, waiting to +0.4 release+ (that should be very soon).

I added a couple of new things:

* capability of plugins to extend “remotes panel” of repositories browser (so we can have options there)
* added a new GitHub option: remove old branches dialog.
* and I started a refactor of GitHub plugin to use a command-pattern hierarchy instead polluting the plugin.

Rationale of plugin action addition is simple: if we receive a lot of bugfixes in the form of a pull request, it means people will be spawning branches all over the place, those branches can stay there a lot of time but eventually, is good to clean up a bit. Now we can do this cleaning from Pharo 🙂

This is not just useful but it shows the power we can achieve by extending iceberg with plugins for different purposes 😉
15 February 2017:
—————–

* I spent some time bringing back some functionality I implemented for [voyage](https://github.com/pharo-nosql/voyage) a lot of time ago (like 4 years) that went missing because of lack of use. This is a “dynamic singleton access strategy”… something like that, more or less…

The idea of this is, sometimes you need to have more than one repository active in an image, but you still want to use the singleton strategy (because is a lot cooler doing something like Person selectOne: [ … ]  instead of myRepository selectOne: Person where: […].

Voyage always allowed different container strategies, even if in master implementation there is just one, VOSingletonContainer. Now I added another called VODynamicContainer and this allow to take the repository from a ‘dynamic variable’ called VOCurrentRepository.

So, for instance, when you have a seaside application where each user works on his own database, you can create a filter of the way:
VoyageFilter>>handleFiltered: aRequestContext
VOCurrentRepository
value: self obtainUserRepository
during: [ self next handleFiltered: aRequestContext ]

VoyageFilter>>obtainUserRepository
^ self session
propertyAt: #voyageRepository
ifAbsentPut: [ VOMongoRepository database: (self session propertyAt: #username) ]

… and you will handle your application as if your repository would be a singleton.

To make this work, the only thing you need is to configure your repository this way:
VORepository repositoryContainer: VODynamicContainer new
14 February 2017:
—————–

* I lost all day digging the problem with FFICallbackTests on windows platforms.

The problem occurs when going back to the image from a callback context ‘when calling the tests’. Is important to remark this because other systems using a lot of callbacks are working fine (notably iceberg, the libgit2 bindings use callbacks as an important part of his design). Also +Athens+ (who uses callbacks to provide some values cairo lib needs) is working correctly too.

So, I’m tempted to think it may be a problem with +MinGW+ implementation of +qsort+ function, and we use it to test the callbacks… anyway, I will keep digging when I find some more time, for now is enough to constate it is not being a problem for windows users (unless, of course, they need to use qsort 😉 )
13 February 2017:
—————–

* I worked on a plugin for iceberg that will take the place of the old “create SLICE”… so far is a very simple plugin that does exactly wjat the slice creator did: takes an issue number and gets the title from it, to conform a branch name called 12345-issue-title-here.

With this change (pull request [here](https://github.com/npasserini/iceberg/pull/277)), all pieces to replace the old fix process are there:

* adding remotes (so you can clone pharo and use your remote as temporal destination)
* creating pull requests (so you can submit your changes in a fancy way)
* creating branches that conforms to our convention (so you can create branches as we like them 😉

… all this in an easy way (at least for me, heh).

It remains, of course, test everything and enhance it with user feedback, but we will be starting that next week.

* I finally finished restoring testing phase to [VM building](https://github.com/pharo-project/pharo-vm).
The purpose of this is, of course, to notice regressions on VMs as soon as we can, and of course, I found
some regressions I needed to fix before being able to have a green build. Most of them were details but:

* there was an important problem with +String+ primitives I needed to dealt with.
* there is a problem on +FFICallback+ for windows who make the test crash (but callbacks works most of the time)

There are, however, still some important problems to fix:

* threaded VM linux cannot be tested because they requiere changing some linux configuration.
* 64bits VMs still cannot be tested because I need to prepare a special image for it.

I will try to fix some of this problems soon, but at least now we are “as we were before” 🙂
cheers!
Esteban

Advertisements

SHA256/512 Password Hashing for Pharo 5

Hi all,

I’ve updated my SHA256/512 password hashing library from NativeBoost to the
Pharo 5 FFI, added an authentication database that uses in-image persistence
and a very simple user interface written in Spec.

GH: https://github.com/PierceNg/PasswordCrypt/
Blog post: http://www.samadhiweb.com/blog/2017.02.18.shacrypt.html

Pierce

Constant enhancements

60397
19715 FastTableModel: Cant enable multiple selection
https://pharo.fogbugz.com/f/cases/19715

19211 sometimes I can not open changesort: receiver of endswith is nil
https://pharo.fogbugz.com/f/cases/19211

19718 Give Random an option to initialize its seed from /dev/random
https://pharo.fogbugz.com/f/cases/19718
60395
19708 When test took too much time while forked processes was failed then TestFailedByForkedProcesses should be signalled
https://pharo.fogbugz.com/f/cases/19708

19714 Force migration of instances of EphemeronLayout and ImmediateLayout
https://pharo.fogbugz.com/f/cases/19714
60394
19010 ImmediateLayout and EphemeronLayout have wrong object format
https://pharo.fogbugz.com/f/cases/19010

60393
19710 Monticello should ignore the class definition of Context
https://pharo.fogbugz.com/f/cases/19710

19711 RPackage should not strongly depend on Monticello
https://pharo.fogbugz.com/f/cases/19711

19709 add example ComputedSlot
https://pharo.fogbugz.com/f/cases/19709

60392
19707 remove Object>>#name hack in the BaselineOfIDE
https://pharo.fogbugz.com/f/cases/19707

19706 remove MBConfigurationInfoTest>>#testInitialization
https://pharo.fogbugz.com/f/cases/19706

19704 [Memory leak] Clipboard can produce memory leaks
https://pharo.fogbugz.com/f/cases/19704
60391
19703 add empty ShortRunArray to Deprecated60
https://pharo.fogbugz.com/f/cases/19703
60390
19698 Scoped button with a more meaningful tooltip
https://pharo.fogbugz.com/f/cases/19698

18760 Failing test: WeakAnnouncerTest>>#testNoDeadWeakSubscriptions
https://pharo.fogbugz.com/f/cases/18760

19183 ZnLogEvent open is broken
https://pharo.fogbugz.com/f/cases/19183

60389
19701 Watchpoint should not ask for name
https://pharo.fogbugz.com/f/cases/19701

19700 testTimeStamp should not use hardcoded timestamp
https://pharo.fogbugz.com/f/cases/19700

19699 testProtocol should not test timestamp
https://pharo.fogbugz.com/f/cases/19699
60388
19695 UUID>>#readHexFrom: accidentally overwrites an inherited method
https://pharo.fogbugz.com/f/cases/19695

19510 Nautilus Hierarchy view of superclasses does not show all the superclasses
https://pharo.fogbugz.com/f/cases/19510

19693 GTEventRecorder should be documented
https://pharo.fogbugz.com/f/cases/19693

19696 Debug world menu still use “Workspace” but open a playgound.
https://pharo.fogbugz.com/f/cases/19696
60387
19689 Add method comments to cool block messages
https://pharo.fogbugz.com/f/cases/19689

19687 Improve UUID documentation, implementation and test coverage
https://pharo.fogbugz.com/f/cases/19687

19691 TabMorph background building animation should be in more priority than building process
https://pharo.fogbugz.com/f/cases/19691

19690 Help on Help includes examples that are not executable
https://pharo.fogbugz.com/f/cases/19690
60386
18778 FileList “View as” does not work
https://pharo.fogbugz.com/f/cases/18778

60385
19670 The tree widget for FastTable jumps to the selected element when expanding or collapsing a node
https://pharo.fogbugz.com/f/cases/19670

19630 Epicea Lost Changes Detector: MNU OmNullReference>>globalName
https://pharo.fogbugz.com/f/cases/19630

19674 Remove UUIDGenerator and rename NeoUUIDGenerator to UUIDGenerator
https://pharo.fogbugz.com/f/cases/19674

19681 #signalerContext should use #method, not #methodNode
https://pharo.fogbugz.com/f/cases/19681

60384
19312 haltIf: should use recursionstopper
https://pharo.fogbugz.com/f/cases/19312

18722 GlobalIdentifier used for system settings persistence
https://pharo.fogbugz.com/f/cases/18722

19659 Tooltips of the class button does not changed
https://pharo.fogbugz.com/f/cases/19659
60383
19677 Cannot parallel trace through same method
https://pharo.fogbugz.com/f/cases/19677

60382
FileExists error in certain cases due to Epiciea vs new UUID

60381
19673 Use NeoUUIDGenerator for UUID generation
https://pharo.fogbugz.com/f/cases/19673

19672 Cleanup some (Neo)UUIDGenerator dependencies
https://pharo.fogbugz.com/f/cases/19672
60380
19680 DNU bug in SLICE 18901
https://pharo.fogbugz.com/f/cases/19680

19679 STON Update Feb 2017
https://pharo.fogbugz.com/f/cases/19679

60379
19678 Zn Update Feb 2017
https://pharo.fogbugz.com/f/cases/19678

19671 The button “Class” stays blue until the cursor leaves it when switching to instance side view
https://pharo.fogbugz.com/f/cases/19671

60378
19664 Removing a package with extensions let the extensions in the system and break their reload
https://pharo.fogbugz.com/f/cases/19664
60376
19661 When coding in the debugger I get an error sourceNodeExecuted
https://pharo.fogbugz.com/f/cases/19661
60375
18271 BaselineOfFileTree is in the old version
https://pharo.fogbugz.com/f/cases/18271

18837 RBParser should not crash when parsing a faulty method node
https://pharo.fogbugz.com/f/cases/18837

19655 Handle events during progressBar usage
https://pharo.fogbugz.com/f/cases/19655

60374
18783 FileList: selected directory is changed after selecting a different folder
https://pharo.fogbugz.com/f/cases/18783

18699 MessageBrowser>>#wrapItem: may send #name to nil, raising Deprecated
https://pharo.fogbugz.com/f/cases/18699

60373
Moose
This version addresses some bug fixes and synchronises those packages integrated using slices with the GToolkit repos. Changes:

– case 19575
– case 19646
– case 19604
– case 19542
– case 19260
– case 19454
– FastTable/List/Tree presentations can set rowHeight.
– Set to the Source presentation of a Context object doItReceiver and doItContext.
60372
19651 showing a progress dialog each time I want to make an expandAll is incorrect
https://pharo.fogbugz.com/f/cases/19651
60370
13159 ListDialogWindow – Grow Width to Fit List
https://pharo.fogbugz.com/f/cases/13159

19620 Unload Tool-TxWorkspace
https://pharo.fogbugz.com/f/cases/19620
60369
18232 Breakpoints cannot be toggled in Nautilus method pane
https://pharo.fogbugz.com/f/cases/18232

19641 CantFindOriginError when Source file is missing on Windows
https://pharo.fogbugz.com/f/cases/19641

19632 TabMorph should defer only notification about ready morph
https://pharo.fogbugz.com/f/cases/19632
60368
19635 DisplayScreen has depth 1 on Linux
https://pharo.fogbugz.com/f/cases/19635
60367
19635 DisplayScreen has depth 1 on Linux
https://pharo.fogbugz.com/f/cases/19635

19634 WriteBarrier mirror methods should be moved to MirrorPrimitives
https://pharo.fogbugz.com/f/cases/19634
60366
17352 DisplayScreen should have a class initialization method
https://pharo.fogbugz.com/f/cases/17352

19544 Better method comment for RubEditingMode>>interactive
https://pharo.fogbugz.com/f/cases/19544

19614 Better names for NoModificationError and friends
https://pharo.fogbugz.com/f/cases/19614

18767 Remove external dependencies from Collection-Tests
https://pharo.fogbugz.com/f/cases/18767

19325 Warning: dependency declared not detected as a dependency
https://pharo.fogbugz.com/f/cases/19325

60365
19624 Wrong deprecated message in ifEmpty:ifNotEmptyDo:
https://pharo.fogbugz.com/f/cases/19624

19625 Catalog: loaded config should not be displayed with white icon
https://pharo.fogbugz.com/f/cases/19625

19129 Deprecation: The method Object>>name called from ClassHierarchyTest>>#testSubclasses has been deprecated.
https://pharo.fogbugz.com/f/cases/19129

Pharo papers

I was mildly curious about how many papers touched on Pharo.

1,110 on google scholar for…
“pharo” “programming”
http://tiny.cc/pharo-scholar

1,630 on normal google for…
“pharo” “programming” “abstract” “introduction” “conclusion”
“references” filetype:pdf
http://tiny.cc/pharo-papers

Probably a lot of overlap between them.
cheers -ben

Consortium action 6 feb/12 feb

Hello!

This is my weekly ChangeLog, from 6 February 2017 to 12 February 2017.
You can see it in a better format by going here: http://log.smallworks.eu/web/search?from=6/2/2017&to=12/2/2017

ChangeLog
=========

9 February 2017:
—————-

* I finished the work started yesterday and now there is a [Pull Request](https://github.com/npasserini/iceberg/pull/276)
enabling the use of SSH for iceberg

8 February 2017:
—————-

* I worked with Pablo on *iceberg*, in [issue 275](https://github.com/npasserini/iceberg/issues/275) (enable
use of ssh-agent). It is very important to provide an easy way to use the tool (otherwise you need to provide
your username/password, and there is people who do not like this).

After one afternoon of hard work, we now have an “almost” working version, as you can see
[here](https://github.com/estebanlm/iceberg/commits/dev-0.4)
This thing in fact should be working, but there are still some UI missing stuff and it is not validated on
other platforms (linux and windows)… ut it ‘should’ work… we’ll see tomorrow

7 February 2017:
—————-

* I’m working on restore the testing of VM builds, and so far linux tests are passing. There are some problems
in macOS (probably due to missing chunks when performing the merge), and windows is still not tested at all.

So, I will work tomorrow on those to see if we can have finished the process this week: I need to have a stable
VM to continue with iceberg development (users will need to have a new VM, so better to have it tested :P)

6 February 2017:
—————-

* Working a bit on VM, I integrated a [pull request](https://github.com/pharo-project/pharo-vm/pull/114) that
will enhance the build process in linux platforms.

This was submited by [Holger](https://github.com/zecke), and is part of his work to create VM package versions.

cheers!
Esteban

Inspector performance improvement

Hi,

Andrei and Alex did a great job at improving the performance and scalability of the inspector.

There are a couple of main improvements:
– Added FastTable support for the Raw presentation for all objects. This implied completing the support for the tree presentation binding to fast table.
– Moved the Items presentation for collections to FastTable.
– Improved the rendering of Glamour to no longer rely on the default Morph>>#adoptPaneColor. It turns out that using adoptPaneColor triggers a relayout of the morph, even if it is not visible. We extended PanelMorph in the context of Glamour with a less needy logic.

I will not tell you how fast it is. I would rather want you to play with it :).

The change is already in the Moose image. It is not yet in Pharo, but it will be soon. In the meantime you can be load it in Pharo 6 like this:

Gofer new
smalltalkhubUser: ‘Moose’ project: ‘GToolkit’;
package: ‘ConfigurationOfGToolkitCore’;
load.
(#ConfigurationOfGToolkitCore asClass project version: #stable) load

To play with it, try this with both the current version and the new one and the Spec Inspector if you want (just make sure you save the image beforehand):

collection := (1 to: 100000000) asArray.
[collection inspect] timeToRun.

collection := (1 to: 100000000).
[collection inspect] timeToRun.

(for these two ones notice that Items do not appear at all in the old implementation)

[World inspect] timeToRun.

There are still a couple of issues open, such as the sorting of the columns. We would need your help with testing this, and report possible missing issues.

Cheers,
Doru


http://www.tudorgirba.com
http://www.feenk.com

“Obvious things are difficult to teach.”

Book Farm back in shape

Hi

https://ci.inria.fr/pharo-contribution/view/Books/

I realised that jenkins dropped the connection to the github repositories of the books and that they were not updated.
You can find my current evening occupation: Learning OOP with Pharo 🙂
I fixed some problems in UnifiedFFI and clean a bit before restarting to work on Pillar.
And we get more green books job.
Stef

Consortium action 30 Jan/5 Feb

Hello!

This is my weekly ChangeLog, from 30 January 2017 to 5 February 2017.
You can see it in a better format by going here: http://log.smallworks.eu/web/search?from=30/1/2017&to=5/2/2017

ChangeLog
=========

3 February 2017:
—————-

*    Still on [iceberg](https://github.com/npasserini/iceberg), this time I addresed two issues:

* [issue 269](https://github.com/npasserini/iceberg/issues/269), which is an improvement on the way we visualise trees (showing just those that have changes, this is very important in big repositories)
* [issue 270](https://github.com/npasserini/iceberg/issues/270), which addreses a problem I left there when working on multi-remotes: it was showing incorrect data between the real outgoing commits and the ones shown in the browser.

I made a couple of pull requests with them (yep, still using the plugin I developed yesterday :P)

2 February 2017:
—————-

*    I spent last two days working on adapt [Iceberg](https://github.com/npasserini/iceberg) infrastructure to accept
plugins.

Well… not totally true. What in fact I made was to *start* to program a way to add plugins, which for now
are just allowed in repositories pane on repositories browser. But well, the rudiments are there.

What actually took most of my time was the development of the first plugin (you know, I do not believe too much
on “developments in abstract”, I need concrete cases to test my ideas): an Pull Request creator. With this, you
can do from iceberg the same kind of work you do in github web page 🙂

So, now you can have a beutiful pull request dialog, along with several validations… Now, you may wonder why
I needed to develop such kind of tool (after all, you can always go to the web page and do the same). And the
answer is that in the new process we are starting to create for Pharo, we need to be able to do things like:

. create a fix
. create a branch from pharo-core sources, named for example issue-12345 (something that would usually belong to a SLICE)
. sends commits to that branch while working on the issue
. send a Pull Request of the issue (what now is to commit the SLICE to inbox and changing status on the bug tracker)

so, to make this process easy, we need to be able to complete the full cycle from Pharo, exactly as we do it now.

Pull Requests are a necessary step to fulfill this requirement.

31 January 2017:
—————-

*    Working on [iceberg](https://github.com/npasserini), I fixed a bug that happened when trying to clone a recently created repository
(without branchs yet).

cheers!
Esteban