Skip to content

zeniko/PythonBridge

This branch is up to date with feenkcom/PythonBridge:main.

Folders and files

NameName
Last commit message
Last commit date
Oct 4, 2019
Jan 29, 2025
Apr 21, 2020
May 6, 2024
Mar 5, 2025
Nov 21, 2019
Dec 12, 2023
Feb 5, 2024
Dec 2, 2018
Jan 4, 2019
May 3, 2024
Dec 2, 2018
Mar 27, 2020

Repository files navigation

PythonBridge

Bridge that allows executing arbitrary pieces of Python code directly from Pharo.

The official webpage and documentation is https://objectprofile.github.io/PythonBridge/.

Requirements

This project depends on Python3.6 (or Python3.7) and Pipenv.

Installation

To install PythonBridge on Pharo just run the following script in a Pharo Playground:

Metacello new
    baseline: 'PythonBridge';
    repository: 'github://ObjectProfile/PythonBridge/src';
    load.

The first part of the script is responsible of downloading the PythonBridge code and loading it in the image. The second part of the script is responsible of creating a pipenv environment for isolating the python libraries used by the bridge.

Depending on the internet connection, the script could take a couple of minutes to run.

A more in depth guide is present on the official website of this project https://objectprofile.github.io/PythonBridge/.

Video installation for VisualWorks

Simple test

Evaluating the following code in a playground should return 3:

PBApplication do: [ 
	PBCF << (P3GBinaryOperator new
						left: 1;
						right: 2;
						operator: $+;
						yourself).
	PBCF send waitForValue
	 ]

About

Bridge between smalltalk and python

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Smalltalk 66.5%
  • Python 32.8%
  • Shell 0.7%