-
-
Notifications
You must be signed in to change notification settings - Fork 367
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Feature/slots #35
Feature/slots #35
Conversation
Current coverage is
|
foo = None | ||
|
||
|
||
@attr.s() |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
On a first scroll a few nits to keep you busy until I have actual time for a review :): Please:
|
Fix docstrings. Fix missing parens in a test.
OK one more fluff wish: could you please make all asserts to be |
Just so we don’t forget:
|
cl_dict = dict(cl.__dict__) | ||
cl_dict['__slots__'] = tuple(ca_list) | ||
for ca_name in ca_list: | ||
# It might not actually be in there, f.e. if using 'these'. |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
all in all this is exciting :) |
Pasting the answer link to a review question here so it doesn't get hidden by GitHub: |
A question? Wrong link? Seemed more like a statement of facts. :) |
Ok, a clarification then. :) |
Are you waiting for anything from me? |
Er no, I'm at work currently. Will fix the parametrization decorators tonight. That's all for now right? |
That and docs. :) FWIW, you can also use hypothesis for the decorators thing. I tend to introduce it into most of my current projects. |
Ok, about the docs. Obviously we need to document the slots argument to attr.s() and make_class, but we should probably have a small section somewhere on the benefits and drawbacks of slot classes. Any preference where? |
I’d say examples. Bring an example and explain a bit. But you don’t have to explain slots completely. Only what’s special about our slots. Feel free to link a general description. |
Ok, I've added hypothesis in. The tests for py27 and pypy are actually failing for me currently, since hypothesis conditionally depends on enum34, and tox creates virtualenvs with ancient pip versions (1.5.6) which don't know to actually install enum34 for hypothesis. I will admit to not knowing how to fix this, and getting a little pissed off at tox for not having a mechanism to deal with this (or at least a discoverable mechanism). I'll ping here when there's something to show for the docs, might be a few days. |
You mean local? Because Travis passes just fine? Try |
I did try recreating, no dice. I guess my virtualenv package is just obsolete. Still frustrating to not be able to precisely tailor the test environment without hacks :/ |
I use pipsi for tox and keep my virtualenv/pip up2date, yeah. :) |
Just pushed some docs, for your inspection. Out of curiosity, do you get automatic notifications when I push new stuff? |
Nope, always ping tickets when you do something. Getting a notification for each push would result in a lot of mails I guess but it would be nice if there’d be a button “notify maintainers” or something. :-/ |
Please do semantic new lines. :) |
Alright, am I doing it right? :) |
I'll give more detailed feedback tomorrow but you slightly over-did it. :) No line feeds after commas please. :) |
https://raw.githubusercontent.com/brandon-rhodes/blog/master/texts/brandon/2012/one-sentence-per-line.rst seems to use line feeds after commas liberally. ¯_(ツ)_/¯ |
|
||
By default, instances of classes have a dictionary for attribute storage. | ||
This wastes space for objects having very few instance variables. | ||
The space consumption can become acute |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
Getting there! 🎉 |
* capitalize bullet items * replace bullet asterisks with dashes * indent bullet code fragments * join some lines
Alright, I've incorporated your feedback to the best of my abilities :) |
Change log entry and I think we can merge. :) |
Nevermind, I’ll do it myself. Thanks for all the work! |
My pleasure, thanks for the reviews. |
I just saw this land in a release. Once upon a time, @fijal told me that |
No description provided.