-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
🌱 Enforce import restrictions in all API packages #9461
🌱 Enforce import restrictions in all API packages #9461
Conversation
8ce2bca
to
3bafcc9
Compare
/area api |
3bafcc9
to
80d9979
Compare
Thx! /hold |
80d9979
to
15e4f99
Compare
15e4f99
to
a108edd
Compare
/hold cancel All other PRs should be merged now |
a108edd
to
0d3874d
Compare
0d3874d
to
bc2bab2
Compare
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.
changes seem reasonable 👍
nice work
@@ -25,6 +25,16 @@ set -o pipefail | |||
|
|||
sub_packages=( |
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.
Wondering if we can say to run it just anywhere and respect the config files? Or determine the paths to test by find -name ".import-restrictions"
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.
Let's maybe try to optimize this in a follow up
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.
Wondering if we can say to run it just anywhere and respect the config files?
I have not tested it by removing the sub package, I can see how it behaves.
Or determine the paths to test by find -name ".import-restrictions"
Otherwise it is ok to do this as well.
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.
I'm fine with optimizing if we find a safe way to do it and if we think it's worth the effort. I would just like to have the restrictions in place :) (so I don't want to wait on finalizing the scripting :))
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.
Yeah a follow up PR sounds good. I don't have much idea about this myself 😅
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.
I would say it's fine as is. @chrischdi feel free to open a follow-up PR if you want to improve it :)
@Ankitasw I realized that this might be a bit confusing :). So here is the summary what restrictions we should have:
|
bc2bab2
to
471f2b5
Compare
import-restrictions look good. Last one: #9461 (comment) Would be great if you can clean these up as well :) |
471f2b5
to
615b5e6
Compare
@Ankitasw: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
Thank you very much!! /lgtm |
LGTM label has been added. Git tree hash: 7d31de2d46af047f2c8b6f106fe71f0df509957c
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: sbueringer The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
What this PR does / why we need it:
This PR enforces import restrictions on API packages to prevent regression mentioned in #9011.
Which issue(s) this PR fixes (optional, in fixes #(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #