adsharma
adsharma
> py2many isnt a Python code bug detector. We shouldnt have code for invalid Python. It is unreachable by any half-sane test code. py2many is a transpiler. A transpiler is...
A couple of other things I missed: * py2many expects to perform static dispatch, possibly multiple-dispatch like Julia. So the code in the example above is not supported. So we...
> My goal wrt the removal of these range/read/write exceptions is to not have dead code. Thank you that's helpful. ``` - if not 0 < len(node.args) < 4: raise...
> It has no body; only a string which is statically checked. It has test coverage. This is a great example of metrics not improving quality. The two lines do...
> I would prefer that the assert wasnt included either, as it also breaks parsing of valid Python I think this is a separate orthogonal topic. We could certainly have...
The "C" reliability rating seems to be coming from two workarounds to silence pyflakes. Which brings up the question of why not use flake8, which runs pyflakes internally and offers...
bool(1) seems easy to implement. The other variants could be written as: is_empty = mylist.len() > 0 is_empty = mydict.keys().len() > 0 aggressive coercion adds some conveniences, but become a...
This is a very reasonable thing to implement. Even existing type checkers such as pyright infer that a is List[str] and show an error in the IDE if I pass...
Might be a good test case for typpete. Here's what it produces right now: ``` from typing import Dict def infer_arg_str(b: object) -> bool: a: object = 'a' return (b...
I've been playing with typpete a bit more. ``` def foo(a): a[10] = "foo" ``` produces: ``` from typing import Dict def foo(a: Dict[(int, str)]) -> None: a[10]: str =...