Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
pygolang
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
pygolang
Commits
7b72d418
Commit
7b72d418
authored
Jan 26, 2022
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
pygolang v0.1
parent
08dc5d10
Pipeline
#19472
passed with stage
in 0 seconds
Changes
5
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
45 additions
and
6 deletions
+45
-6
CHANGELOG.rst
CHANGELOG.rst
+33
-1
README.rst
README.rst
+7
-0
golang/__init__.py
golang/__init__.py
+2
-2
golang/_context.pyx
golang/_context.pyx
+2
-2
golang/runtime/_runtime_thread.pyx
golang/runtime/_runtime_thread.pyx
+1
-1
No files found.
CHANGELOG.rst
View file @
7b72d418
Pygolang
change
history
Pygolang
change
history
-----------------------
-----------------------
0.1
(
2022
-
01
-
26
)
~~~~~~~~~~~~~~~~
-
Add
`
os
.
signal
`
package
that
provides
signal
handing
via
nogil
channels
.
This
allows
to
build
concurrent
systems
without
limitation
of
Python
's standard
`signal` module: signal delivery is not delayed, potentially indefinitely, if
main thread is blocked or is busy doing any non-Python work (`commit 1`__, 2__, 3__, `example usage`__).
__ https://lab.nexedi.com/nexedi/pygolang/commit/1fad944d
__ https://lab.nexedi.com/nexedi/pygolang/commit/ce507f4e
__ https://lab.nexedi.com/nexedi/pygolang/commit/e18adbab
__ https://lab.nexedi.com/nexedi/nxdtest/merge_requests/16
- Add C++ API for IO. (`commit 1`__, 2__, 3__, 4__, 5__, 6__).
__ https://lab.nexedi.com/nexedi/pygolang/commit/3a838d24
__ https://lab.nexedi.com/nexedi/pygolang/commit/3a131a51
__ https://lab.nexedi.com/nexedi/pygolang/commit/c2471014
__ https://lab.nexedi.com/nexedi/pygolang/commit/d358fa75
__ https://lab.nexedi.com/nexedi/pygolang/commit/4690460b
__ https://lab.nexedi.com/nexedi/pygolang/commit/2a35ef5b
- Fix segmentation-fault crashes on unhandled panic with gevent backend (commit__, `greenlet bug`__).
__ https://lab.nexedi.com/nexedi/pygolang/commit/07cae4e9
__ https://github.com/python-greenlet/greenlet/pull/285
- Fix `print(qq(·))` crash on Python2 (commit__).
__ https://lab.nexedi.com/nexedi/pygolang/commit/08dc5d10
0.0.9 (2021-12-08)
0.0.9 (2021-12-08)
~~~~~~~~~~~~~~~~~~
~~~~~~~~~~~~~~~~~~
...
@@ -21,7 +53,7 @@ Pygolang change history
...
@@ -21,7 +53,7 @@ Pygolang change history
__ https://lab.nexedi.com/nexedi/pygolang/commit/78b4b41c
__ https://lab.nexedi.com/nexedi/pygolang/commit/78b4b41c
- More fixes for `gpython` to be compatible with CPython in how it handles
- More fixes for `gpython` to be compatible with CPython in how it handles
program
on
stdin
,
interactive
session
and
__main__
module
setup
(`
commit
1
`
__
,
2
__
,
3
__
,
4
__
,
5
__
).
program on stdin, interactive session and
`__main__`
module setup (`commit 1`__, 2__, 3__, 4__, 5__).
__ https://lab.nexedi.com/nexedi/pygolang/commit/6cc4bf32
__ https://lab.nexedi.com/nexedi/pygolang/commit/6cc4bf32
__ https://lab.nexedi.com/nexedi/pygolang/commit/22fb559a
__ https://lab.nexedi.com/nexedi/pygolang/commit/22fb559a
...
...
README.rst
View file @
7b72d418
...
@@ -445,6 +445,13 @@ handle concurrency in structured ways:
...
@@ -445,6 +445,13 @@ handle concurrency in structured ways:
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/time.py
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/time.py
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/_time.pxd
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/_time.pxd
- |golang.os.signal|_ (py__, pyx__) provides signal handling via channels.
.. |golang.os.signal| replace:: `golang.os.signal`
.. _golang.os.signal: https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/os/signal.h
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/os/signal.py
__ https://lab.nexedi.com/nexedi/pygolang/tree/master/golang/os/_signal.pxd
.. [*] See `Go Concurrency Patterns: Context`__ for overview.
.. [*] See `Go Concurrency Patterns: Context`__ for overview.
...
...
golang/__init__.py
View file @
7b72d418
# -*- coding: utf-8 -*-
# -*- coding: utf-8 -*-
# Copyright (C) 2018-202
0
Nexedi SA and Contributors.
# Copyright (C) 2018-202
2
Nexedi SA and Contributors.
# Kirill Smelkov <kirr@nexedi.com>
# Kirill Smelkov <kirr@nexedi.com>
#
#
# This program is free software: you can Use, Study, Modify and Redistribute
# This program is free software: you can Use, Study, Modify and Redistribute
...
@@ -33,7 +33,7 @@ See also package golang.pyx which provides similar functionality for Cython nogi
...
@@ -33,7 +33,7 @@ See also package golang.pyx which provides similar functionality for Cython nogi
from
__future__
import
print_function
,
absolute_import
from
__future__
import
print_function
,
absolute_import
__version__
=
"0.
0.9
"
__version__
=
"0.
1
"
__all__
=
[
'go'
,
'chan'
,
'select'
,
'default'
,
'nilchan'
,
'defer'
,
'panic'
,
__all__
=
[
'go'
,
'chan'
,
'select'
,
'default'
,
'nilchan'
,
'defer'
,
'panic'
,
'recover'
,
'func'
,
'error'
,
'b'
,
'u'
,
'gimport'
]
'recover'
,
'func'
,
'error'
,
'b'
,
'u'
,
'gimport'
]
...
...
golang/_context.pyx
View file @
7b72d418
# -*- coding: utf-8 -*-
# -*- coding: utf-8 -*-
# cython: language_level=2
# cython: language_level=2
# Copyright (C) 2019-202
0
Nexedi SA and Contributors.
# Copyright (C) 2019-202
2
Nexedi SA and Contributors.
# Kirill Smelkov <kirr@nexedi.com>
# Kirill Smelkov <kirr@nexedi.com>
#
#
# This program is free software: you can Use, Study, Modify and Redistribute
# This program is free software: you can Use, Study, Modify and Redistribute
...
@@ -32,7 +32,7 @@ from cpython cimport PyObject, Py_INCREF, Py_DECREF
...
@@ -32,7 +32,7 @@ from cpython cimport PyObject, Py_INCREF, Py_DECREF
from
libcpp.cast
cimport
static_cast
,
dynamic_cast
from
libcpp.cast
cimport
static_cast
,
dynamic_cast
# _frompyx indicates that a construct
u
r is called from pyx code
# _frompyx indicates that a construct
o
r is called from pyx code
cdef
object
_frompyx
=
object
()
cdef
object
_frompyx
=
object
()
# _newPyCtx creates new PyContext wrapping ctx.
# _newPyCtx creates new PyContext wrapping ctx.
...
...
golang/runtime/_runtime_thread.pyx
View file @
7b72d418
...
@@ -27,7 +27,7 @@ from __future__ import print_function, absolute_import
...
@@ -27,7 +27,7 @@ from __future__ import print_function, absolute_import
#
#
# On POSIX, for example, Python uses sem_init(process-private) + sem_post/sem_wait.
# On POSIX, for example, Python uses sem_init(process-private) + sem_post/sem_wait.
#
#
# Similarly PyThread_start_new_thread - Python's C function
function
to create
# Similarly PyThread_start_new_thread - Python's C function to create
# new thread - does not depend on GIL. On POSIX, for example, it is small
# new thread - does not depend on GIL. On POSIX, for example, it is small
# wrapper around pthread_create.
# wrapper around pthread_create.
#
#
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment