Skip to content

Commit d42bc35

Browse files
committed
Fix formatting issues
1 parent cb691fb commit d42bc35

File tree

4 files changed

+14
-17
lines changed

4 files changed

+14
-17
lines changed

docs/user/Interoperability.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -200,7 +200,8 @@ and these try to "do the right thing" based on the interop type (or raise an exc
200200
201201
Types not listed in the table below have no special interpretation in Python.
202202
203-
| Interop Type | Python Interpretation |
203+
| Interop Type | Python Interpretation |
204+
|:--------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
204205
| `null` | `null` is like `None`. Important to know: interop `null` values are all identical to `None`. JavaScript defines two "null-like" values; `undefined` and `null`, which are *not* identical, but when passed to Python, they are treated so. |
205206
| `boolean` | `boolean` behaves like Python booleans, including the fact that in Python, all booleans are also integers (1 and 0 for true and false, respectively). |
206207
| `number` | `number` Behaves like Python numbers. Python only has one integer and one floating point type, but ranges are imported in some places such as typed arrays. |
@@ -214,12 +215,12 @@ Types not listed in the table below have no special interpretation in Python.
214215
| `exception` | An `exception` can be caught in a generic `except` clause. |
215216
| `MetaObject` | Meta objects can be used in subtype and `isinstance` checks. |
216217
| `executable` | An `executable` object can be executed as a function, but never with keyword arguments. |
217-
| `instantiable` | An `instantiable` object can be called just like a Python type, but never with keyword arguments. |
218-
| | |
218+
| `instantiable` | An `instantiable` object can be called just like a Python type, but never with keyword arguments. |
219219

220220
### Python to Interop Types
221221

222-
| Interop Type | Python Interpretation |
222+
| Interop Type | Python Interpretation |
223+
|:--------------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
223224
| `null` | Only `None`. |
224225
| `boolean` | Only subtypes of Python `bool`. Note that in contrast to Python semantics, Python `bool` is *never* also an interop number. |
225226
| `number` | Only subtypes of `int` and `float`. |
@@ -233,6 +234,7 @@ Types not listed in the table below have no special interpretation in Python.
233234
| `MetaObject` | Any Python `type`. |
234235
| `executable` | Any Python object with a `__call__` method. |
235236
| `instantiable` | Any Python `type`. |
237+
236238
## The Interoperability Extension API
237239

238240
It is possible to extend the interoperability protocol directly from Python via a simple API defined in the `polyglot` module.

docs/user/Python-Runtime.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,9 @@ GraalPy provides the following capabilities:
2222

2323
### GraalPy Distributions
2424

25-
GraalPy is available as **Oracle GraalPy** and **GraalPy Community**.
25+
GraalPy is available as **GraalPy built on Oracle GraalVM** and **GraalPy Community**.
2626

27-
* Oracle GraalPy provides the best experience: it comes with additional optimizations, is significantly faster and more memory-efficient.
28-
Oracle GraalPy is built on top of Oracle GraalVM, and is licensed under the [GraalVM Free Terms and Conditions (GFTC)](https://www.oracle.com/downloads/licenses/graal-free-license.html) license, which permits use by any user including commercial and production use.
27+
* GraalPy built on top of Oracle GraalVM provides the best experience: it comes with additional optimizations, is significantly faster and more memory-efficient. It is licensed under the [GraalVM Free Terms and Conditions (GFTC)](https://www.oracle.com/downloads/licenses/graal-free-license.html) license, same as Oracle GraalVM, which permits use by any user including commercial and production use.
2928
Redistribution is permitted as long as it is not for a fee.
3029

3130
* GraalPy Community is built on top of GraalVM Community Edition, and is fully open-source.
@@ -157,10 +156,7 @@ This generates wrapper scripts and makes the implementation usable from a shell
157156
158157
Multiple executables are available in the virtual environment, including: `python`, `python3`, and `graalpy`.
159158
160-
> Note: To deactivate the Python environment (and return to your shell), use the following command:
161-
```bash
162-
deactivate
163-
```
159+
> Note: To deactivate the Python environment (and return to your shell), run `deactivate`.
164160
165161
The `pip` package installer is available when using a virtual environment.
166162
The GraalPy implementation of `pip` may choose package versions other than the latest in cases where it ships patches to make these work better.

docs/user/Python-Standalone-Applications.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ The [Truffle framework](https://github.com/oracle/graal/tree/master/truffle) on
1414
GraalPy includes a module named `standalone` to create a Python binary for Linux, macOS, and Windows.
1515
The modules bundles all your application's resources into a single file.
1616

17-
> Note: **Prerequisite** GraalPy distribution beginning with version 23.1.0. See [GraalPy releases](https://github.com/oracle/graalpython/releases).
17+
> Prerequisite: GraalPy distribution beginning with version 23.1.0. See [GraalPy releases](https://github.com/oracle/graalpython/releases).
1818
1919
For example, if you want to produce a native executable from a Python file named _my\_script.py_ along with packages you have installed in a virtual environment named _my\_venv_, run the following command:
2020

docs/user/README.md

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -67,18 +67,19 @@ The Java code and the _pom.xml_ file are heavily documented and the generated co
6767

6868
2. Open your project configuration file, _app/build.gradle_, and modify it as follows.
6969
- Include the GraalPy support and the [GraalVM SDK Polyglot API](https://www.graalvm.org/sdk/javadoc/org/graalvm/polyglot/package-summary.html) in the `dependencies` section:
70-
```kotlin
70+
71+
```
7172
implementation("org.graalvm.polyglot:polyglot:23.1.2")
7273
implementation("org.graalvm.polyglot:python:23.1.2")
7374
```
7475

7576
- We recommend you use the Java modules build. Add the appropriate plugin to the `plugins` section:
76-
```kotlin
77+
```
7778
id("org.javamodularity.moduleplugin") version "1.8.12"
7879
```
7980

8081
- To run the application as a module rather than from the classpath, edit the `application` section to look like this:
81-
```kotlin
82+
```
8283
application {
8384
mainClass.set("interop.App")
8485
mainModule.set("interop")
@@ -113,8 +114,6 @@ The Java code and the _pom.xml_ file are heavily documented and the generated co
113114
```
114115
The application prints "Hello Python!" to the console.
115116
116-
<br>
117-
118117
> Note: The performance of the GraalPy runtime depends on the JDK in which you embed it. For more information, see [Runtime Optimization Support](https://www.graalvm.org/latest/reference-manual/embed-languages/#runtime-optimization-support).
119118
120119
#### Related Documentation

0 commit comments

Comments
 (0)