Patch built-in python objects
a framework for building 2D games using html5 canvas and javascript
my dotfiles :)
Chrome pixel perfect - An extension to compare a page with its original design.
Transforms Javascript code that uses ES6's destructuring feature into code that runs on today's browsers.
fabiomcosta/arquiteturas_aplicacoes_web 3
Codigo e apresentacao para arquiteturas de aplicacoes web
Plug & play JavaScript-framework adapter, code like PrototypeJS with any framework.
Real event simulator for browsers
vector drawing for buttons, icons, widgets and all that stuff
Give your JS App some Backbone with Models, Views, Collections, and Events
startedoutline/outline
started time in 9 hours
startedtorchbox/buckup
started time in 11 hours
startedtibdex/auto-update
started time in 12 hours
started99designs/aws-vault
started time in 14 hours
startedhashicorp/terraform-cdk
started time in 14 hours
startedjotego/jtframe
started time in 15 hours
startedMayaPosch/NymphCast
started time in a day
created repositoryungap/is-connected
An `Element.prototype.isConnected` polyfill.
created time in a day
startedWSWhitehouse/Unity-Tag-Selector
started time in a day
issue openedclarete/forbiddenfruit
Crash on Windows if dunder methods cursed into `ctypes.c_int` raises an exception
In addition to #56, if the dunder method is cursed into ctypes' integer types, an raised exception caused Python to crash on Windows.
Proof of concept:
#!/usr/bin/env python3
from ctypes import c_int
from forbiddenfruit import curse
def c_int_add(self: c_int, other: int) -> c_int:
raise TypeError('This exception should be caught')
curse(c_int, '__add__', c_int_add)
try:
print(c_int(1) + 1) # TypeError (correct) then crash on Windows (wrong)
except TypeError:
print('TypeError caught')
print('If this gets printed then nothing has crashed')
Test result on Windows (version 10.0.19043.1052, Python 3.8.6, both 64-bit):
(venv) C:\dev\test> python bug2.py
Exception ignored on calling ctypes callback function: <function c_int_add at 0x000001E12AC1FDC0>
Traceback (most recent call last):
File "E:\src\pytrickz\venv\lib\site-packages\forbiddenfruit\__init__.py", line 328, in wrapper
return func(*args, **kwargs)
File "bug2.py", line 7, in c_int_add
raise TypeError('This exception should be caught')
TypeError: This exception should be caught
(venv) C:\dev\test> echo %=ExitCode%
C0000005
(venv) C:\dev\test>
created time in a day
issue openedclarete/forbiddenfruit
Exceptions raised in cursed-in dunder methods are not raised to calling code
Proof of concept:
#!/usr/bin/env python3
from forbiddenfruit import curse
class foo(object):
def __init__(self): pass
def foo_add(self: foo, other: int) -> foo:
raise TypeError('This exception should be caught')
curse(foo, '__add__', foo_add)
try:
print(foo() + 1) # <class '__main__.foo'> (on Windows), __main__ (on Linux)
except TypeError:
print('AttributeError caught') # Not caught (wrong)
Test result:
(venv) C:\dev\test> python bug.py
Exception ignored on calling ctypes callback function: <function foo_add at 0x0000026EC623FEE0>
Traceback (most recent call last):
File "E:\src\pytrickz\venv\lib\site-packages\forbiddenfruit\__init__.py", line 328, in wrapper
return func(*args, **kwargs)
File "bug.py", line 13, in foo_add
raise TypeError('This exception should be caught')
TypeError: This exception should be caught
<class '__main__.foo'>
(venv) C:\dev\test>
The exception is printed to the screen (presumably by ctypes?) but not raised, except TypeError not triggered, print() receives a garbage result that depends on Python version and class structure (for example, if I remove foo.__init__ from code the result becomes None on Windows).
created time in a day
startedawslabs/aws-lc
started time in a day
startedgcanti/fp-ts-local-storage
started time in 2 days
startedrxhanson/Rectangle
started time in 2 days
startedGetPublii/Publii
started time in 2 days
startedkingoflolz/mesh-transformer-jax
started time in 2 days