Y
HN Search
Hacker News Search
new
|
comments
|
top
|
jobs
timothycrosley
searching PlanetScale…
1.
▲
2.
▲
3.
▲
4.
▲
5.
▲
6.
▲
8 ms
·
31.
▲
by
timothycrosley
7y ago
> I think a successful modern language has to have the potential for efficient concurrency baked in I agree with this! > I don't think there is any sort of long-term future in anything "Python". I disagree with this :)
32.
▲
by
timothycrosley
7y ago
> No importing basic type This at least is being solved in Python: https://www.python.org/dev/peps/pep-0563/ > inline interfaces Typed dicts in 3.8 look pretty similar at cursory glance https:/&#x
33.
▲
by
timothycrosley
7y ago
Thank you for sharing! This looks really promising, I'll try to think of ways I can contribute to the project.
34.
▲
by
timothycrosley
7y ago
> TypeScript got typings right. I have not used TypeScript, but looking at it's documentation the syntax for type annotations look identical. Would you be willing to expand on why you think its approach is better / how it'
35.
▲
by
timothycrosley
7y ago
I use Cython a lot! But mostly to speed up existing Python code, and build C-extensions faster. I don't see it as a strict subset of Python or a new language to build a community around. Nuitka I just started experimenting with to buil
36.
▲
by
timothycrosley
7y ago
I've been tracking nim, and would agree it's the most promising so far! I feel though that it's trying to be too flexible in many ways. Examples of this include allowing multiple different garbage collectors and encouraging
37.
▲
by
timothycrosley
7y ago
More and more I want someone to create a new language that amounts to a strict subset of Python, with mypy built-in, and is compilable into machine code. Python has by far my favorite syntax, community, and in my experience leads to the gre
38.
▲
by
timothycrosley
7y ago
As an (unrelated to the Algorithm) Python developer, also named Tim, I've never been able to hear the last of it. Still a great algorithm, though!
39.
▲
Show HN: Cruft – Updatable Project Templates
(timothycrosley.github.io)
1 points
by
timothycrosley
7y ago
|
0 comments
40.
▲
We've Automated Copying and Pasting Code
(timothycrosley.com)
2 points
by
timothycrosley
7y ago
|
0 comments
41.
▲
by
timothycrosley
7y ago
Thoughts behind project: https://timothycrosley.com/project-6-cruft
42.
▲
Show HN: Cruft – Maintainable Project Boilerplate
(timothycrosley.github.io)
1 points
by
timothycrosley
7y ago
|
1 comments
43.
▲
by
timothycrosley
7y ago
Updated in latest release to use trailing underscore: https://timothycrosley.github.io/hypothesis-auto/CHANGELOG/ figured it would be the least painful the earlier I did it :)
44.
▲
by
timothycrosley
7y ago
Similar to parent I bet hard on Python in 2008. That means I've been writing Python for over 10 years. Sure, any programmer can pick up a new language, but I'm able to build (what I believe) are useful projects and release them in
45.
▲
by
timothycrosley
7y ago
I'd use it!
46.
▲
by
timothycrosley
7y ago
That's a great call! I'll update this to use trailing underscore in a later version
47.
▲
by
timothycrosley
7y ago
> I think I would be more comfortable with it generating test files that I could keep beside my other tests. This is a very interesting idea I might explore more! `auto_pytest_magic` is only made available if you have pytest installed. Y
48.
▲
by
timothycrosley
7y ago
You are correct! Thanks for catching this! I'll fix the example later today
49.
▲
by
timothycrosley
7y ago
Yes! A smart one though, that limits itself to the type constraints you've specified to avoid redoing the work of your type checker.
50.
▲
by
timothycrosley
7y ago
It's an extension for hypothesis, and its value is 100% just convenience and accessibility. Really, it's meant to be a sort of gateway to doing full property-based testing, in the least barrier way possible. I wrote a bit more abo
51.
▲
by
timothycrosley
7y ago
While I agree, that `_param` generally means private, it is also a common way to allow parameters to be passed into a function where all other parameters are passed directly along via args and *kwargs to avoid naming collisions. An exampl
52.
▲
by
timothycrosley
7y ago
By default, the biggest value from this is catching unexpected runtime exceptions with certain values (the edge cases you don't think of yourself). To get the most value out of it, you can further specify what you expect from the resul
53.
▲
by
timothycrosley
7y ago
Thoughts behind project creation live here: https://timothycrosley.com/project-5-hypothesis-auto
54.
▲
by
timothycrosley
7y ago
Thoughts behind project creation live here: https://timothycrosley.com/project-5-hypothesis-auto
55.
▲
by
timothycrosley
7y ago
Hi @kburman, For cases like that it would be best combined with a mock: @auto_pytest() def test_add(test_case, mocker): mocker.patch('db.call') test_case() Note that this example utilizes the following pytest
56.
▲
Show HN: Fully Automatic Tests for Python
(timothycrosley.github.io)
1 points
by
timothycrosley
7y ago
|
1 comments
57.
▲
Show HN: Python Tests That Write Themselves
(timothycrosley.github.io)
131 points
by
timothycrosley
7y ago
|
37 comments
58.
▲
by
timothycrosley
7y ago
Been doing this before the typing module was released, using hug: http://www.hug.rest/ FastAPI has a lot of advantages at this point for someone looking to do the same: https://github.com/tiangolo/fasta
59.
▲
Write fewer tests and less documentation. Write more examples
(timothycrosley.github.io)
1 points
by
timothycrosley
7y ago
|
0 comments
60.
▲
Pip Install Examples
(pypi.org)
1 points
by
timothycrosley
7y ago
|
0 comments
More ›