📚 the "own service" example in docs/services/index.rst cannot be registered
Maintainers usually reply within 1 day
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 85/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- python
- Domain
- documentation, testing
Research direction
Read the own-service example in docs/services/index.rst around lines 116–171, then inspect service registration and the existing service tests to see how examples are built. Update the example’s options, fields, and super().__init__(...) call, and add a test that builds it. Done when the example registers and its my_config datum is available to the need.
Written by the indexing model from the issue text.
Description
What happens
The example of a service of your own in docs/services/index.rst (around lines 116-171 at master 9feaba74) does not work when copied:
- The class declares no
options, so registration refuses it:needs_services entry 'my-service' is not registered: its 'class' 'MyService' has no 'options' [needs.config]. - Its
__init__callssuper(GithubService, self)in a class that does not derive fromGithubService, which would raise aNameError(orTypeError) once registered. - The datum key it returns (
my_config) reaches the need only if it is a registered field.
What to do
Make the example runnable: declare options (and, once services declare their data fields separately, fields), call super().__init__(...), and add a test that builds it.
- Dominant language
- Python
- Stars
- 309
- Forks
- 103
- Avg merge
- 4h 40m
- Merged PRs (30d)
- 154
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from useblocks/sphinx-needs
-
documentation pkg: sphinx-needs
Difficulty 1/5 1-3 hours Newbie friendliness 82/100
useblocks/sphinx-needs#2379 ·
Maintainers usually reply within 1 day
-
bug pkg: sphinx-needs
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
useblocks/sphinx-needs#2338 ·
Maintainers usually reply within 1 day
-
bug pkg: sphinx-needs
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
useblocks/sphinx-needs#2335 ·
Maintainers usually reply within 1 day
-
bug pkg: sphinx-needs
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
useblocks/sphinx-needs#2332 ·
Maintainers usually reply within 1 day
-
bug pkg: sphinx-needs
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
useblocks/sphinx-needs#2325 ·
Maintainers usually reply within 1 day
All issues in useblocks/sphinx-needs
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 66/100
suitenumerique/accounts#160 ·
Maintainers usually reply within 1 day
-
Restoring an exhausted flatmap checkpoint can replay consumed recordsPossibly taken @salma2vec claimed this today. Opentype:bug
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
Maintainers usually reply within 1 day
-
`ingest` fails with pynndescent 0.7Possibly taken @eroell claimed this today. OpenTriage 🩺
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Maintainers usually reply within 1 day