File tree 2 files changed +9
-1
lines changed
src/pip/_internal/commands
2 files changed +9
-1
lines changed Original file line number Diff line number Diff line change
1
+ import logging
1
2
from optparse import Values
2
3
from typing import Any , Dict , List
3
4
12
13
from pip ._internal .utils .compat import stdlib_pkgs
13
14
from pip ._internal .utils .urls import path_to_url
14
15
16
+ logger = logging .getLogger (__name__ )
17
+
15
18
16
19
class InspectCommand (Command ):
17
20
"""
@@ -44,6 +47,11 @@ def add_options(self) -> None:
44
47
self .parser .insert_option_group (0 , self .cmd_opts )
45
48
46
49
def run (self , options : Values , args : List [str ]) -> int :
50
+ logger .warning (
51
+ "pip inspect is currently an experimental command. "
52
+ "The output format may change in a future release without prior warning."
53
+ )
54
+
47
55
cmdoptions .check_list_path_option (options )
48
56
dists = get_environment (options .path ).iter_installed_distributions (
49
57
local_only = options .local ,
Original file line number Diff line number Diff line change @@ -28,7 +28,7 @@ def test_inspect_basic(simple_script: PipTestEnvironment) -> None:
28
28
"""
29
29
Test default behavior of inspect command.
30
30
"""
31
- result = simple_script .pip ("inspect" )
31
+ result = simple_script .pip ("inspect" , allow_stderr_warning = True )
32
32
report = json .loads (result .stdout )
33
33
installed = report ["installed" ]
34
34
assert len (installed ) == 4
You can’t perform that action at this time.
0 commit comments