Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reintroduce deprecated support for old-style container args #340

Merged
merged 1 commit into from
Nov 23, 2016

Conversation

minrk
Copy link
Member

@minrk minrk commented Oct 25, 2016

alternative to #338, we should only pick one.

The old, undocumented (I think?) way of specifying containers on the command-line continues to work with a deprecation message.

The way I've implemented deprecations here prevents new-style args that pass the 'looks like a literal' test. That means there would be no way to properly specify the list ["[1]"] on the command-line. I'm not too concerned about it, but it's a theoretical issue. The alternative to that is to keep the logic here for warnings, but don't try to support the old-style args. That way you can specify anything in the new-style, and users will get a pointer if they use the old-style, but attempts to use the old-style will generally result in errors.

I have a slight inclination toward deprecate-and-keep-working over break-with-informative-message, but if someone can point to a more serious problem that the deprecation will break, I'm happy to change.

closes #338

@ankostis
Copy link
Contributor

But if the old behavior was undocumented, and problematic, why should we keep it around?
Probably would cause more problems in the future if people start really (ab)using it.

@minrk
Copy link
Member Author

minrk commented Nov 22, 2016

@ankostis while rare, people used it. Deprecations, where feasible, are always nicer than breaking things.

old-style args continue to work, producing a warning when seen.

This prevents new-style args from ever supporting length-one items that pass the 'looks-like a literal' tests,
which seem rather unlikely.
@minrk minrk added this to the 5.0 milestone Nov 22, 2016
@minrk minrk changed the title [proposal] reintroduce deprecated support for old-style container args reintroduce deprecated support for old-style container args Nov 22, 2016
@Carreau
Copy link
Member

Carreau commented Nov 22, 2016

+1

@minrk
Copy link
Member Author

minrk commented Nov 23, 2016

Thanks, @Carreau!

@minrk minrk merged commit c3b785c into ipython:master Nov 23, 2016
@minrk minrk deleted the deprecated-cli-2 branch November 23, 2016 15:09
@Carreau Carreau added 5.0-re-review Need to re-review for potential API impact changes. 5.0-major Major change in 5.0 need proper documentation and removed 5.0-re-review Need to re-review for potential API impact changes. labels Jun 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
5.0-major Major change in 5.0 need proper documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants