Extracting a method creates methods that take functions as arguments
We have written the needed data into your clipboard because it was too large to send. Please paste. Type: Bug
Behaviour
The refactor --> extract method assumes that methods called within the newly created method should be taken as arguments.
An example:
def add(a, b):
return a+b
if __name__=="__main__":
d = 5
for i in range(10):
add(i,d)
Selecting the for loop, right clicking, refactor --> extract method yields the following:
def add(a, b):
return a+b
def new_func(add, d):
for i in range(10):
add(i,d)
if __name__=="__main__":
d = 5
new_func(add, d)
The behaviour I would expect would be this:
def add(a, b):
return a+b
def new_func(d):
for i in range(10):
add(i,d)
if __name__=="__main__":
d = 5
new_func(d)
Steps to reproduce:
- See above
Diagnostic data
Output for Python in the Output panel (View→Output, change the drop-down the upper-right of the Output panel to Python)
Python output:
2024-11-08 11:23:45.844 [info] (Client) Pylance async client (2024.11.1) started with python extension (2024.18.1)
2024-11-08 11:23:46.195 [info] [Info - 11:23:46 AM] (1075311) Server root directory: file:///home/ben/.vscode/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 11:23:46.196 [info] [Info - 11:23:46 AM] (1075311) Pylance language server 2024.11.1 (pyright version 1.1.386, commit 4180fa21) starting
2024-11-08 11:23:46.211 [info] [Info - 11:23:46 AM] (1075311) Starting service instance "<default>"
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) Setting environmentName for service "<default>": "3.12.3 (global)"
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) Setting pythonPath for service "<default>": "/bin/python3"
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) No include entries specified; assuming /<default workspace root>
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/node_modules
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/__pycache__
2024-11-08 11:23:46.230 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/.*
2024-11-08 11:23:46.246 [info] [Info - 11:23:46 AM] (1075311) Assuming Python version 3.12.3.final.0
2024-11-08 11:23:46.295 [info] [Error - 11:23:46 AM] (1075311) File or directory "/<default workspace root>" does not exist.
2024-11-08 11:23:46.295 [info] [Info - 11:23:46 AM] (1075311) No source files found.
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) Setting environmentName for service "<default>": "3.12.3 (global)"
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) Setting pythonPath for service "<default>": "/bin/python3"
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) No include entries specified; assuming /<default workspace root>
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/node_modules
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/__pycache__
2024-11-08 11:23:46.321 [info] [Info - 11:23:46 AM] (1075311) Auto-excluding **/.*
2024-11-08 11:23:46.337 [info] [Info - 11:23:46 AM] (1075311) Assuming Python version 3.12.3.final.0
2024-11-08 11:23:46.361 [info] [Error - 11:23:46 AM] (1075311) File or directory "/<default workspace root>" does not exist.
2024-11-08 11:23:46.361 [info] [Info - 11:23:46 AM] (1075311) No source files found.
2024-11-08 11:23:46.591 [info] [Info - 11:23:46 AM] (1075311) Background analysis(1) root directory: file:///home/ben/.vscode/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 11:23:46.593 [info] [Info - 11:23:46 AM] (1075311) Background analysis(1) started
Python language server output:
2024-11-08 01:56:27.763 [info] (Client) Pylance async client (2024.11.1) started with python extension (2024.18.0)
2024-11-08 01:56:28.039 [info] [Info - 1:56:28 AM] (1817) Server root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.039 [info] [Info - 1:56:28 AM] (1817) Pylance language server 2024.11.1 (pyright version 1.1.386, commit 4180fa21) starting
2024-11-08 01:56:28.043 [info] [Info - 1:56:28 AM] (1817) Starting service instance "bendev"
2024-11-08 01:56:28.045 [info] [Info - 1:56:28 AM] (1817) Starting service instance "part-recognition"
2024-11-08 01:56:28.046 [info] [Info - 1:56:28 AM] (1817) Starting service instance "camcal_investigation_scripts"
2024-11-08 01:56:28.046 [info] [Info - 1:56:28 AM] (1817) Starting service instance "apera_robot_services"
2024-11-08 01:56:28.046 [info] [Info - 1:56:28 AM] (1817) Starting service instance "camcal_error_analysis"
2024-11-08 01:56:28.046 [info] [Info - 1:56:28 AM] (1817) Starting service instance "nissan"
2024-11-08 01:56:28.047 [info] [Info - 1:56:28 AM] (1817) Starting service instance "megaset"
2024-11-08 01:56:28.047 [info] [Info - 1:56:28 AM] (1817) Starting service instance "calibration_testing_data"
2024-11-08 01:56:28.125 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "camcal_investigation_scripts": "3.11.10 (global)"
2024-11-08 01:56:28.125 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "camcal_investigation_scripts": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.125 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/camcal_investigation_scripts
2024-11-08 01:56:28.126 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.126 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.126 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.132 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.166 [info] [Info - 1:56:28 AM] (1817) Found 8 source files
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "bendev": "3.11.10 (global)"
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "bendev": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/bendev
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.183 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.198 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.224 [info] [Info - 1:56:28 AM] (1817) Found 4 source files
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "part-recognition": "3.11.10 (global)"
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "part-recognition": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/part-recognition
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.232 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.249 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.391 [info] [Info - 1:56:28 AM] (1817) Found 88 source files
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "apera_robot_services": "3.11.10 (global)"
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "apera_robot_services": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/apera_robot_services
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.398 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.416 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.463 [info] [Info - 1:56:28 AM] (1817) Found 2 source files
2024-11-08 01:56:28.469 [info] [Info - 1:56:28 AM] (1817) Background analysis(1) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.469 [info] [Info - 1:56:28 AM] (1817) Background analysis(1) started
2024-11-08 01:56:28.470 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "camcal_error_analysis": "3.11.10 (global)"
2024-11-08 01:56:28.471 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "camcal_error_analysis": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.471 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/camcal_error_analysis
2024-11-08 01:56:28.471 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.471 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.471 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.493 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.516 [info] [Error - 1:56:28 AM] (1817) File or directory "/workspaces/camcal_error_analysis" does not exist.
2024-11-08 01:56:28.516 [info] [Info - 1:56:28 AM] (1817) No source files found.
2024-11-08 01:56:28.523 [info] [Info - 1:56:28 AM] (1817) Background analysis(2) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "nissan": "3.11.10 (global)"
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "nissan": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/nissan
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.524 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.546 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.577 [info] [Error - 1:56:28 AM] (1817) File or directory "/workspaces/nissan" does not exist.
2024-11-08 01:56:28.577 [info] [Info - 1:56:28 AM] (1817) No source files found.
2024-11-08 01:56:28.585 [info] [Info - 1:56:28 AM] (1817) Background analysis(2) started
2024-11-08 01:56:28.585 [info] [Info - 1:56:28 AM] (1817) Background analysis(3) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "megaset": "3.11.10 (global)"
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "megaset": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /workspaces/megaset
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.586 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.608 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.641 [info] [Info - 1:56:28 AM] (1817) Found 5 source files
2024-11-08 01:56:28.648 [info] [Info - 1:56:28 AM] (1817) Background analysis(3) started
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) Setting environmentName for service "calibration_testing_data": "3.11.10 (global)"
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) Setting pythonPath for service "calibration_testing_data": "/usr/local/bin/python3.11"
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) No include entries specified; assuming /host_home/calibration_testing_data
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/node_modules
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/__pycache__
2024-11-08 01:56:28.649 [info] [Info - 1:56:28 AM] (1817) Auto-excluding **/.*
2024-11-08 01:56:28.669 [info] [Info - 1:56:28 AM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 01:56:28.802 [info] [Info - 1:56:28 AM] (1817) No source files found.
2024-11-08 01:56:28.804 [info] [Info - 1:56:28 AM] (1817) Background analysis(4) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.804 [info] [Info - 1:56:28 AM] (1817) Background analysis(4) started
2024-11-08 01:56:28.887 [info] [Info - 1:56:28 AM] (1817) Background analysis(5) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.888 [info] [Info - 1:56:28 AM] (1817) Background analysis(5) started
2024-11-08 01:56:28.920 [info] [Info - 1:56:28 AM] (1817) Background analysis(6) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.923 [info] [Info - 1:56:28 AM] (1817) Background analysis(6) started
2024-11-08 01:56:28.954 [info] [Info - 1:56:28 AM] (1817) Background analysis(7) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:28.956 [info] [Info - 1:56:28 AM] (1817) Background analysis(7) started
2024-11-08 01:56:29.027 [info] [Info - 1:56:29 AM] (1817) Background analysis(8) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 01:56:29.029 [info] [Info - 1:56:29 AM] (1817) Background analysis(8) started
2024-11-08 01:57:53.146 [info] [Info - 1:57:53 AM] (1817) Indexer background runner(9) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist (index)
2024-11-08 01:57:53.146 [info] [Info - 1:57:53 AM] (1817) Indexing(9) started
2024-11-08 01:57:53.499 [info] [Info - 1:57:53 AM] (1817) scanned(9) 185 files over 1 exec env
2024-11-08 01:57:55.252 [info] [Info - 1:57:55 AM] (1817) indexed(9) 185 files over 1 exec env
2024-11-08 01:57:55.286 [info] [Info - 1:57:55 AM] (1817) Indexing finished(9).
2024-11-08 02:21:18.560 [info] [Info - 2:21:18 AM] (1817) Indexer background runner(10) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist (index)
2024-11-08 02:21:18.560 [info] [Info - 2:21:18 AM] (1817) Indexing(10) started
2024-11-08 02:21:18.742 [info] [Info - 2:21:18 AM] (1817) scanned(10) 185 files over 1 exec env
2024-11-08 02:21:19.530 [info] [Info - 2:21:19 AM] (1817) indexed(10) 185 files over 1 exec env
2024-11-08 02:21:19.556 [info] [Info - 2:21:19 AM] (1817) Indexing finished(10).
2024-11-08 18:41:32.681 [info] [Info - 6:41:32 PM] (1817) Starting service instance "<default>"
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) Setting environmentName for service "<default>": "3.11.10 (global)"
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) Setting pythonPath for service "<default>": "/usr/local/bin/python3.11"
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) No include entries specified; assuming /<default workspace root>
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) Auto-excluding **/node_modules
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) Auto-excluding **/__pycache__
2024-11-08 18:41:32.704 [info] [Info - 6:41:32 PM] (1817) Auto-excluding **/.*
2024-11-08 18:41:32.726 [info] [Info - 6:41:32 PM] (1817) Assuming Python version 3.11.10.final.0
2024-11-08 18:41:32.756 [info] [Error - 6:41:32 PM] (1817) File or directory "/<default workspace root>" does not exist.
2024-11-08 18:41:32.756 [info] [Info - 6:41:32 PM] (1817) No source files found.
2024-11-08 18:41:33.001 [info] [Info - 6:41:33 PM] (1817) Background analysis(11) root directory: file:///home/user/.vscode-server/extensions/ms-python.vscode-pylance-2024.11.1/dist
2024-11-08 18:41:33.003 [info] [Info - 6:41:33 PM] (1817) Background analysis(11) started
2024-11-08 19:19:44.527 [info] [Info - 7:19:44 PM] (1817) Found 9 source files
Extension version: 2024.18.0 VS Code version: Code 1.94.2 (384ff7382de624fb94dbaf6da11977bba1ecd427, 2024-10-09T16:08:44.566Z) OS version: Linux x64 6.8.0-47-generic Modes: Remote OS version: Linux x64 6.8.0-47-generic
- Python version (& distribution if applicable, e.g. Anaconda): 3.11.10
- Type of virtual environment used (e.g. conda, venv, virtualenv, etc.): Global
- Value of the
python.languageServersetting: Default
User Settings
Multiroot scenario, following user settings may not apply:
languageServer: "Pylance"
Installed Extensions
| Extension Name | Extension Id | Version |
|---|---|---|
| Black Formatter | ms-python.black-formatter | 2024.4.0 |
| C/C++ | ms-vscode.cpptools | 1.22.11 |
| C/C++ Extension Pack | ms-vscode.cpptools-extension-pack | 1.3.0 |
| clangd | llvm-vs-code-extensions.vscode-clangd | 0.1.29 |
| CMake | twxs.cmake | 0.0.17 |
| CMake Tools | ms-vscode.cmake-tools | 1.19.52 |
| cpplint | mine.cpplint | 0.1.3 |
| Docker | ms-azuretools.vscode-docker | 1.29.3 |
| Doxygen Documentation Generator | cschlosser.doxdocgen | 1.4.0 |
| Doxygen Documentation Generator - With Parameter Direction | zatkins-dev.doxdocgen-with-direction | 1.5.3 |
| Git Graph | mhutchie.git-graph | 1.30.0 |
| GitLens — Git supercharged | eamodio.gitlens | 15.6.3 |
| JavaScript Debugger | ms-vscode.js-debug | 1.94.0 |
| Line Note | tkrkt.linenote | 1.2.1 |
| LLDB DAP | llvm-vs-code-extensions.lldb-dap | 0.2.6 |
| Markdown All in One | yzhang.markdown-all-in-one | 3.6.2 |
| Open In Default Browser | peakchen90.open-html-in-browser | 2.1.10 |
| Pylance | ms-python.vscode-pylance | 2024.11.1 |
| Python | ms-python.python | 2024.18.0 |
| Python Debugger | ms-python.debugpy | 2024.12.0 |
| Table Visualizer for JavaScript Profiles | ms-vscode.vscode-js-profile-table | 1.0.10 |
System Info
| Item | Value |
|---|---|
| CPUs | 12th Gen Intel(R) Core(TM) i7-12700 (20 x 4224) |
| GPU Status | 2d_canvas: unavailable_software canvas_oop_rasterization: disabled_off direct_rendering_display_compositor: disabled_off_ok gpu_compositing: disabled_software multiple_raster_threads: enabled_on opengl: disabled_off rasterization: disabled_software raw_draw: disabled_off_ok skia_graphite: disabled_off video_decode: disabled_software video_encode: disabled_software vulkan: disabled_off webgl: unavailable_software webgl2: unavailable_software webgpu: disabled_off webnn: disabled_off |
| Load (avg) | 2, 2, 2 |
| Memory (System) | 31.04GB (17.96GB free) |
| Process Argv | --crash-reporter-id 6a1fee61-71a9-4108-a863-b8548607adc9 |
| Screen Reader | no |
| VM | 0% |
| DESKTOP_SESSION | ubuntu |
| XDG_CURRENT_DESKTOP | Unity |
| XDG_SESSION_DESKTOP | ubuntu |
| XDG_SESSION_TYPE | x11 |
| Item | Value |
|---|---|
| Remote | Dev Container: Existing Docker Compose (Extend) |
| OS | Linux x64 6.8.0-47-generic |
| CPUs | 12th Gen Intel(R) Core(TM) i7-12700 (20 x 4500) |
| Memory (System) | 31.04GB (17.96GB free) |
| VM | 0% |
A/B Experiments
vsliv368cf:30146710
vspor879:30202332
vspor708:30202333
vspor363:30204092
vscod805:30301674
binariesv615:30325510
vsaa593:30376534
py29gd2263:31024239
c4g48928:30535728
azure-dev_surveyone:30548225
962ge761:30959799
pythongtdpath:30769146
pythonnoceb:30805159
asynctok:30898717
pythonmypyd1:30879173
h48ei257:31000450
pythontbext0:30879054
cppperfnew:31000557
dsvsc020:30976470
pythonait:31006305
dsvsc021:30996838
da93g388:31013173
dvdeprecation:31068756
dwnewjupyter:31046869
impr_priority:31102340
nativerepl1:31139838
refactort:31108082
pythonrstrctxt:31112756
nativeloc2:31134642
cf971741:31144450
iacca1:31171482
notype1:31157159
5fd0e150:31155592
dwcopilot:31170013
happens to me too, super annoying, each time I refactor something I then have to manually delete all the unwanted arguments it created (twice - once from the decleration, once from the call). I will also state that in python there's no need for that - you can call global functions in other functions. If someone has nested functions and tries calling them outside their scope, that someone will find out that it doesn't work through the NameError, so this is an unnecessary precaution.