question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Support creating stub-only packages

See original GitHub issue
  • I have searched the issues of this repo and believe that this is not a duplicate.

Issue

MyPy documentation explains how to create stub-only packages. It would be nice if Poetry supported stub-only packages. Current behaviour:

$ fd
ordered_set-stubs
pyproject.toml
LICENSE
README.md
ordered_set-stubs/__init__.pyi
$ poetry build
Skipping virtualenv creation, as specified in config file.
Building ordered_set-stubs (0.1.0)
                                                      
[ValueError]                           
No file/folder found for package ordered-set-stubs  
                                                      
build [-f|--format FORMAT]

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
fsenartcommented, Jan 27, 2020

@sdispater right after version 1.0.0, in version 1.0.1, stub-only packages are no longer supported. One gets an ... is not a package. error. @rominf this issue should be reopened.

1reaction
sdispatercommented, Oct 6, 2018

It’s already supported. Just add the following to the [tool.poetry] section.

[tool.poetry]
# Basic package information

packages = [
    {include = "ordered_set-stubs"}
]

Then, if you run poetry build you should have stub-only distributions.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Support creating stub-only packages · Issue #475 - GitHub
Issue MyPy documentation explains how to create stub-only packages. It would be nice if Poetry supported stub-only packages.
Read more >
Using installed packages - mypy 0.991 documentation
If you want to create a stub-only package for an existing library, the simplest way is to contribute stubs to the typeshed repository,...
Read more >
PEP 561 – Distributing and Packaging Type Information
This PEP aims to support all three scenarios and make them simple to ... Note that for stub-only packages adding a py.typed marker...
Read more >
MockSettings (Mockito 4.2.0 API) - javadoc.io
//Creates mock with different default answer & name Foo mock ... A stub-only mock does not record method invocations, thus saving memory but...
Read more >
How to test software: mocking, stubbing, and contract testing
Mocking means creating a fake version of an external or internal service ... means creating a stand-in, but a stub only mocks the...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found