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

pantsbuild / pants / 4825
0%
main: 93%

Build:
Build:
LAST BUILD BRANCH: fix_uv_lockfile_sync
DEFAULT BRANCH: main
Ran 11 May 2015 02:42PM UTC
Jobs 10
Files 325
Run time 15min
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

pending completion
4825

push

travis-ci

jsirois
Handle warnings in BUILD file context.

Previously, deprecation warnings encountered parsing BUILD files did not
include BUILD file context making it harder to track down deprecated
constructs than it had to be.

Testing Done:
There are actually 2 fixes here.

One added a missing newline.  I'm not sure how this worked before, but for a standard BUILD file SyntaxError:
Before:
```console
$ PANTS_DEV=1 ./pants list src/python/pants/java:
...
Exception message: Error parsing FilesystemBuildFile(/home/jsirois/dev/3rdparty/jsirois-pants4/src/python/pants/java/BUILD):
    9:     '3rdparty/python/twitter/commons:twitter.common.collections',   10:     'src/python/pants/base:build_environment',   11:     'src/python/pants/java/distribution:distribution',*  12:     'src/python/pants/util:contextutil',}                                               ^ SyntaxError: invalid syntax (BUILD, line 12)

   13:     'src/python/pants/util:dirutil',   14:     'src/python/pants/util:meta',   15:   ]   16: )
 Loading addresses from 'src/python/pants/java' failed.
```

After:
```console
$ PANTS_DEV=1 ./pants list src/python/pants/java:
...
Exception message: While parsing FilesystemBuildFile(/home/jsirois/dev/3rdparty/jsirois-pants4/src/python/pants/java/BUILD):
    9:     '3rdparty/python/twitter/commons:twitter.common.collections',
   10:     'src/python/pants/base:build_environment',
   11:     'src/python/pants/java/distribution:distribution',
*  12:     'src/python/pants/util:contextutil',}
                                               ^ SyntaxError: invalid syntax (BUILD, line 12)

   13:     'src/python/pants/util:dirutil',
   14:     'src/python/pants/util:meta',
   15:   ]
   16: )

 Loading addresses from 'src/python/pants/java' failed.
```

And the new handling looks like so when encountering deprecated constructs in BUILD parsing:
Before:
```console
$ PANTS_DEV=1 ./pants list src::
*** Running pants in dev mode from /home/jsirois/dev/3rdparty/jsirois-pants4/src/python/pants/bin/pants_exe.py ***
WARN] <string>:6: DeprecationWarning:
pants.backend.core.wrapped_globs.__sub__ is deprecated and will be removed in version 0.0.35:
Instead of glob arithmetic, use glob(..., exclude=[...])

INFO] Detected git repository at /home/jsirois/dev/3rdparty/jsirois-pants4 on branch jsirois/build_file_parser/handle_warnings
src/python/pants/java/distribution:distribution
src/python/pants/docs:export
...
```

After:
```console
$ PANTS_DEV=1 ./pants list src::
*** Running pants in dev mode from /home/jsirois/dev/3rdparty/jsirois-pants4/src/python/pants/bin/pants_exe.py ***
WARN] While parsing FilesystemBuildFile(/home/jsirois/dev/3rdparty/jsirois-pants4/src/python/pants/option/BUILD):
    3:
    4: python_library(
    5:   name = 'option',
*   6:   sources = globs('*.py') - ['migrate_config.py'],
        DeprecationWarning:
pants.backend.core.wrapped_globs.__sub__ is deprecated and will be removed in version 0.0.35:
Instead of glob arithmetic, use glob(..., exclude=[...])

    7:   dependencies = [
    8:     '3rdparty/python/twitter/commons:twitter.common.collections',
    9:     'src/python/pants/base:build_environment',
   10:     'src/python/pants/base:config',

INFO] Detected git repository at /home/jsirois/dev/3rdparty/jsirois-pants4 on branch jsirois/build_file_parser/handle_warnings
src/python/pants/java/distribution:distribution
src/python/pants/docs:export
...
```

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

Bugs closed: 1174, 1521

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

13380 of 19335 relevant lines covered (69.2%)

0.69 hits per line

Jobs
ID Job ID Ran Files Coverage
1 4825.1 (CI_FLAGS="-cjlpnet 'Various pants self checks'") 11 May 2015 02:54PM UTC 0
Travis Job 4825.1
2 4825.2 (CI_FLAGS="-fkmsrcjlpn 'Test examples and testprojects'") 11 May 2015 02:44PM UTC 0
Travis Job 4825.2
3 4825.3 (CI_FLAGS="-fkmsrcnet 'Unit tests for pants and pants-plugins'") 11 May 2015 02:49PM UTC 0
69.2
Travis Job 4825.3
4 4825.4 (CI_FLAGS="-fkmsrcjlpet 'Python contrib tests'") 11 May 2015 02:42PM UTC 0
Travis Job 4825.4
5 4825.5 (CI_FLAGS="-fkmsrjlpnet -i 6:0 'Python integration tests for pants - shard 1'") 11 May 2015 02:43PM UTC 0
Travis Job 4825.5
6 4825.6 (CI_FLAGS="-fkmsrjlpnet -i 6:1 'Python integration tests for pants - shard 2'") 11 May 2015 02:50PM UTC 0
Travis Job 4825.6
7 4825.7 (CI_FLAGS="-fkmsrjlpnet -i 6:2 'Python integration tests for pants - shard 3'") 11 May 2015 02:53PM UTC 0
Travis Job 4825.7
8 4825.8 (CI_FLAGS="-fkmsrjlpnet -i 6:3 'Python integration tests for pants - shard 4'") 11 May 2015 02:56PM UTC 0
Travis Job 4825.8
9 4825.9 (CI_FLAGS="-fkmsrjlpnet -i 6:4 'Python integration tests for pants - shard 5'") 11 May 2015 02:57PM UTC 0
Travis Job 4825.9
10 4825.10 (CI_FLAGS="-fkmsrjlpnet -i 6:5 'Python integration tests for pants - shard 6'") 11 May 2015 02:58PM UTC 0
Travis Job 4825.10
Source Files on build 4825
Detailed source file information is not available for this build.
  • Back to Repo
  • Travis Build #4825
  • ab2d326a on github
  • Prev Build on master (#4820)
  • Next Build on master (#4832)
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