@@ -122,6 +122,15 @@ def _call_signature(
122
122
)
123
123
if deprecated_plugin :
124
124
deprecation_warnings .append (deprecated_plugin .short_message )
125
+ warnings .warn (
126
+ f"""Plugin '{ plugin_name } ' has been deprecated.
127
+ ------------------------
128
+ { deprecated_plugin .short_message }
129
+ ===
130
+ { deprecated_plugin .long_message }
131
+ """ ,
132
+ FutureWarning ,
133
+ )
125
134
126
135
deprecations = _ds .DEPRECATION_STORE .get_stored_plugin_argument_deprecations (
127
136
getattr (webviz_config .plugins , plugin_name ).__init__
@@ -137,16 +146,15 @@ def _call_signature(
137
146
if deprecation .argument_name in kwargs_including_defaults .keys ():
138
147
deprecation_warnings .append (deprecation .short_message )
139
148
warnings .warn (
140
- """Deprecated Argument: {} with value '{}' in method {} in module {}
149
+ """Deprecated Argument: '{}' with value '{}' in plugin '{}'
141
150
------------------------
142
151
{}
143
152
===
144
153
{}
145
154
""" .format (
146
155
deprecation .argument_name ,
147
156
kwargs_including_defaults [deprecation .argument_name ],
148
- deprecation .method_name ,
149
- getattr (deprecation .method_reference , "__module__" ),
157
+ plugin_name ,
150
158
deprecation .short_message ,
151
159
deprecation .long_message ,
152
160
),
@@ -164,7 +172,7 @@ def _call_signature(
164
172
if result :
165
173
deprecation_warnings .append (result [0 ])
166
174
warnings .warn (
167
- """Deprecated Argument(s): {} with value '{}' in method {} in module {}
175
+ """Deprecated Argument(s): '{}' with value(s) '{}' in plugin '{}'
168
176
------------------------
169
177
{}
170
178
===
@@ -176,8 +184,7 @@ def _call_signature(
176
184
for key , value in kwargs_including_defaults .items ()
177
185
if key in deprecation .argument_names
178
186
],
179
- deprecation .method_name ,
180
- getattr (deprecation .method_reference , "__module__" ),
187
+ plugin_name ,
181
188
result [0 ],
182
189
result [1 ],
183
190
),
0 commit comments