Merge lp://staging/~adiroiban/pydoctor/1282458-apilinks-anchor into lp://staging/~mwhudson/pydoctor/dev

Proposed by Adi Roiban
Status: Needs review
Proposed branch: lp://staging/~adiroiban/pydoctor/1282458-apilinks-anchor
Merge into: lp://staging/~mwhudson/pydoctor/dev
Diff against target: 170 lines (+117/-5)
4 files modified
CONTRIBUTING.txt (+5/-0)
pydoctor/apilinks_sphinxext.py (+17/-5)
pydoctor/test/test_apilinks_sphinxext.py (+91/-0)
test-requirements.txt (+4/-0)
To merge this branch: bzr merge lp://staging/~adiroiban/pydoctor/1282458-apilinks-anchor
Reviewer Review Type Date Requested Status
Michael Hudson-Doyle Pending
Review via email: mp+207392@code.staging.launchpad.net

Description of the change

This is the branch which add anchor support for apilink Sphinx extension.

I have created CONTRIBUTING.txt file since as a first time contributor it
was not obvious that py.test is required together with 'py' packages.

I have created test-requirements.txt file to list all packages requried
for running the tests.

I have also added docutils since the following test was failing
`pydoctor/test/test_templatewriter.py:55: AssertionError`

Also my new test will fail without docutils.

I have moved apilinks_sphinxext.py inside pydoctor package to make it
easier to test.. but maybe it is a stupid change.

I am not sure how you want to distribute the exentsion. Maybe create a separate package.

bunch was added as a minimal mock tool.

flake8 was added as a minimum tool for keeping code formatting consistent.

I added an initial set of tests for happy case.

Let me know if more tests are required.

Let me know if something needs changes.

Thanks!

To post a comment you must log in.
Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Hi. Thanks for proposing this branch!

It would probably have been better to do the different things in different branches maybe?

I don't use py.test any more to run the tests, but generally use nose instead. I'm not super happy about either tbh, and would like to convert them all to something more standardly-pyUnitish but well.

I don't know how apilinks_sphinxext.py is used at all -- if it is still useful when part of the pydoctor package, then it makes sense for it to be there rather than at top level.

Revision history for this message
Adi Roiban (adiroiban) wrote :

I can split this review... but considering that this is the only branch in the review queue I don't know what splitting it will make things easier.

I use nose and I am happy with it. Much better than standard pyunit.

I tried to use, but test were failing so I did not dig deeper and just went to install py.test, since I saw that tests required 'py' package which was talking about pytest.

apilinks_sphinxext.py is used in Twisted, but is not used as part of pydoctor package, but instead there is a copy of this file.

Thanks!

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Adi Roiban <email address hidden> writes:

> I can split this review... but considering that this is the only
> branch in the review queue I don't know what splitting it will make
> things easier.

Well I find it helps to talk about one thing at once but you make a fair
point.

> I use nose and I am happy with it. Much better than standard pyunit.

OK, so...

> I tried to use, but test were failing so I did not dig deeper and just
> went to install py.test, since I saw that tests required 'py' package
> which was talking about pytest.

Can you try again? I think I just deleted the last remnants of the py
imports.

> apilinks_sphinxext.py is used in Twisted, but is not used as part of
> pydoctor package, but instead there is a copy of this file.

Right, I think we should be moving towards only having one copy of the
file but I don't know what's involved in that.

Cheers,
mwh

Revision history for this message
Adi Roiban (adiroiban) wrote :

I tried nosetests on trunk and there are still errors: https://gist.github.com/adiroiban/9125421

I like nosetests and so I would like to use it instead of py.test. That all :)

I will ask over twisted mailing list and try to get some feedback about how apilinks_sphinxext.py should be distributed.

My initial but report/patch was on Twisted Trac and there I was asked to send patch here... feels like bad communication.

Thanks!

Revision history for this message
Michael Hudson-Doyle (mwhudson) wrote :

Adi Roiban <email address hidden> writes:

> I tried nosetests on trunk and there are still errors: https://gist.github.com/adiroiban/9125421

Argh, I think I've fixed the final final import of py...

> I like nosetests and so I would like to use it instead of py.test. That all :)

Good!

> I will ask over twisted mailing list and try to get some feedback about how apilinks_sphinxext.py should be distributed.

That'd be great.

> My initial but report/patch was on Twisted Trac and there I was asked
> to send patch here... feels like bad communication.

Well, if you'd just sent me the change to apilinks_sphinxext, it'd have
been merged by now. I'm sorry there was no CONTRIBUTING.txt and thanks
for trying to write one, but it's not surprising that it was hard for
you to guess what should be in there!

Cheers,
mwh

614. By Adi Roiban

Merge trunk.

615. By Adi Roiban

Update test requirements and contributing page.

Revision history for this message
Adi Roiban (adiroiban) wrote :

All good now. I have updated requirements. I will wait for feedback from Twisted developers. I am not in a hurry to have this merged.

While this code is in a single branch, I think that you can always pick some files from here, changed them as you like and commit them in trunk.

As long as you can just push a commit in trunk without a bug report and a review request, I feel that is unfair to ask contributors to spend extra effort for creating bugs and review requests for such simple things.
No hard feelings, just sincere feedback!

Thanks!

Unmerged revisions

615. By Adi Roiban

Update test requirements and contributing page.

614. By Adi Roiban

Merge trunk.

613. By Adi Roiban

Initial code for anchor support and tests.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
The diff is not available at this time. You can reload the page or download it.

Subscribers

People subscribed via source and target branches

to all changes:
to status/vote changes: