• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

pantsbuild / pants / 6179 / 3
0%
main: 93%

Build:
Build:
LAST BUILD BRANCH: upgrade_runson_to_ami-0a3c71582153db678
DEFAULT BRANCH: main
Ran 14 Aug 2015 09:37PM UTC
Files 351
Run time 9s
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

14 Aug 2015 08:58PM UTC coverage: 68.814% (-1.1%) from 69.919%
CI_FLAGS="-fkmsrcn -u 1/2 'Unit tests for pants and pants-plugins - shard 2'"

push

travis-ci

jsirois
Support plugins resolution in pants.

Previously, pants could only load plugins already in the working set
(PYTHONPATH).  With this change, pants both resolves (and caches)
plugins as well as loading backends through their entry points.

In order to support this, two small changes were made to the options
system:

 1. OptionsBootstrapper was altered to cache full options per-known
    scope info set.  This allows the work of bootstrapping to be shared
    by the PluginResolver and the main options loading sequence.
 2. Options was refactored to support creating a copy that behaves the
    same as the original except that option values from command line
    flags are ignored.

These changes combine to give the early stage PluginResolver a clean,
performant means of using the configured PythonSetup and PythonRepos
subsystems to resolve plugins from the repos and indices the user has
set up for their pants installation.

Testing Done:
Manual testing as follows:

1. Bump the pants version in another clone and do a local dry run
   release to build the new entry_points carrying plugins (see:
   https://rbcommons.com/s/twitter/r/2615/)

2. Disable the local android backend:
```diff
$ git diff -U1
diff --git a/pants.ini b/pants.ini
index 4756c9b..d7a67a9 100644
--- a/pants.ini
+++ b/pants.ini
@@ -27,3 +27,3 @@ backend_packages: [
     "internal_backend.utilities",
-    "pants.backend.android",
+#    "pants.backend.android",
     "pants.contrib.cpp",
```

3. Run pants using the new plugin resolver/installed mechanism:
```console
$ rm -rf ~/.cache/pants/plugins/
$ PANTS_PLUGINS="['pantsbuild.pants.backend.android==0.0.42']" PANTS_PYTHON_REPOS_REPOS="['/home/jsirois/dev/3rdparty/jsirois-pants3/dist']" ./pants goals --all
INFO:pants.bin.plugin_resolver:Resolving new plugins...:
  pantsbuild.pants.backend.android==0.0.42
INFO] Detected git repository at /home/jsirois/dev/3rdparty/jsirois-pants4 on branch jsirois/plugins/bootstrap
Installed goals:
                    apk: Build an android bundle with compiled code and assets.
...
```

CI went green here:
  https://travis-ci.org/pantsbuild/pants/builds/75655671

Bugs closed: 1976, 1977

Reviewed at https://rbcommons.com/s/twitter/r/2622/

14568 of 21170 relevant lines covered (68.81%)

0.69 hits per line

Source Files on job 6179.3 (CI_FLAGS="-fkmsrcn -u 1/2 'Unit tests for pants and pants-plugins - shard 2'")
  • Tree
  • List 0
  • Changed 151
  • Source Changed 4
  • Coverage Changed 151
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Build 6179
  • Travis Job 6179.3
  • 67b16e6e on github
  • Prev Job for CI_FLAGS="-fkmsrcn -u 1/2 'Unit tests for pants and pants-plugins - shard 2'" on master (#6171.3)
  • Next Job for CI_FLAGS="-fkmsrcn -u 1/2 'Unit tests for pants and pants-plugins - shard 2'" on master (#6182.3)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc