show deprecation warning for options given in env and config

Review Request #4272 — Created Sept. 30, 2016 and submitted

yujiec
pants
3896, 3918
pants-reviews
benjyw, nhoward_tw

Currently, if a deprecating option is provided through environment variable or config file, no warnings will be printed.
It will result in errors when that option is eventually deprecated.

This change makes Pants spit out a warning in those cases and adds test cases.

https://travis-ci.org/pantsbuild/pants/builds/164089994

  • 0
  • 0
  • 1
  • 0
  • 1
Description From Last Updated
ST
  1. Thanks!

  2. tests/python/pants_test/option/test_options.py (Diff revision 1)
     
     
     
     

    Since you've gone through the trouble to separate these, maybe break them into different methods?

  3. 
      
BE
  1. 
      
  2. I don't love the ascii-art lines (here and below), and we don't use them anywhere else. A regular comment line, with a single empty line above and below it, is fine.

    Even better - break this method up.

    1. Have broken this into 3 methods.

  3. 
      
YU
ST
  1. Ship It!
  2. 
      
BE
  1. Ship It!
  2. 
      
YU
Review request changed

Status: Closed (submitted)

Change Summary:

Merged in https://github.com/pantsbuild/pants/commit/89f1eb2a9cc1aeebbb30a487c633fc154c8f29b8
Thanks Stu and Benjy!

Loading...