`%pastebin` arguments get silently dropped if they are out of order
Author: MrMinoCreated Jul 14, 2021Updated Aug 16, 2026
Labelsbugmagics
%pastebin 1 -d "This is a test"Intuitively, the above should result in either:
- An error, since
-d "This is a test"should come first. - A dpaste.org entry where the description is set to "This is a test".
Instead, it silently drops the arguments.
- Find which builtin magics do this sort of thing (
Magics.parse_optionsis used for the arguments in%pastebin- look for the ones that use it). - Fix them - preferably by enabling unordered arguments, whenever possible.
Found out during the review of #13056.
Source: ipython/ipython