Skip to content

Ensure that type info is picked up from installed package. #124

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

Merged

Conversation

Oberon00
Copy link
Member

@Oberon00 Oberon00 commented Sep 6, 2019

Ensure that type info is picked up from installed package.

This required moving all top-level modules to a sub-package, to not
create collisions with py.typed marker files.

See https://www.python.org/dev/peps/pep-0561/#packaging-type-information

@Oberon00
Copy link
Member Author

Oberon00 commented Sep 6, 2019

Actually I'm not ensuring anything here anymore, I just hope for the best 😟 I guess I'll need to amend this to test that another package can pick up the type information if opentelemetry-api is installed.

@Oberon00 Oberon00 added the WIP Work in progress label Sep 6, 2019
@Oberon00 Oberon00 removed the WIP Work in progress label Sep 12, 2019
@Oberon00
Copy link
Member Author

Now, the py.typed installation is checked and even works due to adding MANIFEST.in. 😄 Removing WIP label, as this is now ready for review.

@Oberon00 Oberon00 force-pushed the typeinfo-packaging branch 2 times, most recently from 29fdf42 to f1af9ff Compare September 12, 2019 14:54
Copy link
Member

@c24t c24t left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but no manifest for the SDK?

@Oberon00
Copy link
Member Author

We don't type-annotate the SDK (yet 😉) but I can add a MANIFEST.in there too to be future-proof.

This required moving all top-level modules to a sub-package, to not
create collisions with py.typed marker files.

See https://www.python.org/dev/peps/pep-0561/#packaging-type-information
@Oberon00 Oberon00 merged commit 531d0b1 into open-telemetry:master Sep 16, 2019
opentelemetry.metrics
opentelemetry.trace
opentelemetry.util.loader
Copy link
Member Author

@Oberon00 Oberon00 Sep 16, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Argh, sorry for the mismerge. --> #138

Oberon00 added a commit to dynatrace-oss-contrib/opentelemetry-python that referenced this pull request Sep 16, 2019
Oberon00 added a commit to dynatrace-oss-contrib/opentelemetry-python that referenced this pull request Sep 16, 2019
reyang pushed a commit that referenced this pull request Sep 16, 2019
srikanthccv pushed a commit to srikanthccv/opentelemetry-python that referenced this pull request Nov 1, 2020
Change return type "unknow" to HttpTextFormat for getHttpTextFormat
Change return type "unknow" to BinaryFormat for getBinaryFormat
Close open-telemetry#124 open-telemetry#123

Signed-off-by: Olivier Albertini <olivier.albertini@montreal.ca>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants