-
-
Notifications
You must be signed in to change notification settings - Fork 5.2k
Add a table to summarize the modes #10067
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
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -200,6 +200,26 @@ the ``vendors`` directory will make the test suite fail, while deprecations | |
triggered from a library inside it will not, giving you the best of both | ||
worlds. | ||
|
||
Here is a summary that should help you pick the right mode: | ||
|
||
+----------------+-----------------------------------------------------+ | ||
| Mode | Recommended situation | | ||
+================+=====================================================+ | ||
| strict | Recommended for actively maintained projects | | ||
| | with little to no dependencies | | ||
+----------------+-----------------------------------------------------+ | ||
| <some integer> | Recommended for projects that you cannot | | ||
| | immediately fix but don't want to make worse. | | ||
| | Can be used to transition from one mode to another. | | ||
+----------------+-----------------------------------------------------+ | ||
| weak_vendors | Recommended for libraries that use | | ||
| | the deprecation system themselves and | | ||
| | cannot afford to use one of the modes above. | | ||
+----------------+-----------------------------------------------------+ | ||
| weak | Not recommended; will probably lead to | | ||
| | a big refactoring. | | ||
+----------------+-----------------------------------------------------+ | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I like this new table! But, which mode should I use in my project? Most projects either: A) Have deprecations & know about them... and just want to report them at the bottom of their tests (but not cause failures) B) Do not have deprecations and want to keep it that way. New deprecations should cause the tests to fail. What should I have for (A)? And is (B) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Right now, |
||
|
||
Disabling the Deprecation Helper | ||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ | ||
|
||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we have a bit more information about what integers you can use here? ie. What's the min/max? Is a lower number more strict or less strict?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This column shows no description, even for other modes. It only shows a recommendation. That particular mode is already documented above.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah fair enough. As long as it's documented somewhere 👍