Skip to content

build: adding sdist to build scripts #433

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

Closed

Conversation

toumorokoshi
Copy link
Member

Some operating systems (such as SUSE with py2pack) have an easier time
packaging source distributions.

Adding a check for the setup.py before attempting to build
distributions.

Addressing part of #427

Some operating systems (such as SUSE with py2pack) have an easier time
packaging source distributions.

Adding a check for the setup.py before attempting to build
distributions.
@toumorokoshi toumorokoshi requested review from c24t and a team February 19, 2020 05:40
@codecov-io
Copy link

codecov-io commented Feb 19, 2020

Codecov Report

Merging #433 into master will decrease coverage by 0.08%.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #433      +/-   ##
==========================================
- Coverage   88.19%   88.11%   -0.09%     
==========================================
  Files          41       41              
  Lines        2042     2078      +36     
  Branches      234      238       +4     
==========================================
+ Hits         1801     1831      +30     
- Misses        170      173       +3     
- Partials       71       74       +3
Impacted Files Coverage Δ
.../src/opentelemetry/sdk/metrics/export/aggregate.py 88.46% <0%> (-11.54%) ⬇️
...elemetry-api/src/opentelemetry/context/__init__.py 63.04% <0%> (-4.35%) ⬇️
...emetry-sdk/src/opentelemetry/sdk/trace/__init__.py 90.84% <0%> (-0.37%) ⬇️
...ntelemetry-api/src/opentelemetry/trace/__init__.py 85.62% <0%> (+1.06%) ⬆️
...dk/src/opentelemetry/sdk/metrics/export/batcher.py 97.36% <0%> (+5.7%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 120ae29...2c96fd5. Read the comment docs.

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.

Using sdist LGTM, but why the user install?

scripts/build.sh Outdated
@@ -6,7 +6,7 @@
set -ev

# Get the latest versions of packaging tools
python3 -m pip install --upgrade pip setuptools wheel
python3 -m pip install --user --upgrade pip setuptools wheel
Copy link
Member

Choose a reason for hiding this comment

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

Why this change?

scripts/build.sh Outdated
@@ -6,7 +6,7 @@
set -ev

# Get the latest versions of packaging tools
python3 -m pip install --upgrade pip setuptools wheel
python3 -m pip install --user --upgrade pip setuptools wheel
Copy link
Member

Choose a reason for hiding this comment

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

Note that this conflicts with virtualenvs:

ERROR: Can not perform a '--user' install. User site-packages are not visible in this virtualenv.

Copy link
Member Author

Choose a reason for hiding this comment

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

ah ok. I guess this is just a how-you-run-it kind of thing. For me the --user helps because I don't use a virtualenv, and I don't like to install these to the root environment.

But I'll try not to break workflows, I'll remove --user.

python3 setup.py --verbose bdist_wheel --dist-dir "$BASEDIR/dist/"
# some ext directories (such as docker tests)
# are not intended to be packaged. Verify the
# intent by looking for a setup.py
Copy link
Member

Choose a reason for hiding this comment

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

Note that this still builds opentelemetry-ext-testutil-0.4.dev0.tar.gz.

Copy link
Member Author

Choose a reason for hiding this comment

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

should we not publish testutil? I'm not sure the right market to set in that case, although maybe we should just move to a separate directory?

Copy link
Member Author

Choose a reason for hiding this comment

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

Actually it seems like we should publish it, as the extensions need it to run tests, and it'd be frustrating I think to not be able to not be able to run tests without installing a package that only exists in a source tree.

The script was intended to be run under a virtualenv, where user
packages do not exist, and are not needed.
Copy link
Contributor

@codeboten codeboten left a comment

Choose a reason for hiding this comment

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

LGTM

@c24t
Copy link
Member

c24t commented Feb 20, 2020

Closing in favor of #437.

@c24t c24t closed this Feb 20, 2020
srikanthccv pushed a commit to srikanthccv/opentelemetry-python that referenced this pull request Nov 1, 2020
…er (open-telemetry#433)

* feat(plugin-document-load): new plugin for document load for web tracer

* chore: lint

* chore: removing unused dependency

* chore: adding prepare script

* chore: cleanup of not used span processor

* chore: merging exporter-console into tracing

* chore: fixing timeOrigin when browser is using older version of performance (safari for example)

* chore: removing @Private

* chore: cleaning the docs

* chore: using stubs on public instead of private

* chore: added explanation when span can be undefined

* chore: adding unit test for case when passed "performanceNow" is equal to 0

* chore: adding unit test for case when passed "performanceNow" is null or undefined

* chore: fixing unit test with null

* chore: bump version

* chore: after changing enum keys to capitals I had to use values to align them with performance metric in type "PerformanceEntries"

* chore: adding comments for interfaces

* feat: adding possibility of setting start time for event

* chore: refactoring document load to use events instead of new spans

* chore: reformatting

* chore: updating loop

* chore: changing type for time

* chore: refactoring loop, updating jsdoc

* chore: splitting events into 2 spans

* chore: adding possibility of calling addEvent with 2nd param as time

* chore: updating the last event to be "load end"

* chore: updating the name for attributes

* chore: fixing test

* chore: cleanups

* chore: adding isTimeInput function with unit tests

* chore: adding component name

* chore: adding license and readme

* chore: updating lint and docs jobs to use node12 image in circleci
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.

4 participants