-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Map "chip" Python imports as first-party #37138
base: master
Are you sure you want to change the base?
Conversation
PR #37138: Size comparison from 8370039 to e8405c5 Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #37138: Size comparison from f3202b1 to 3f2fc0c Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
PR #37138: Size comparison from 22cd392 to 385212c Full report (71 builds for bl602, bl702, bl702l, cc13x4_26x4, cc32xx, cyw30739, efr32, esp32, linux, nrfconnect, nxp, psoc6, qpg, stm32, telink, tizen)
|
@@ -12,12 +12,12 @@ | |||
# See the License for the specific language governing permissions and | |||
# limitations under the License. | |||
|
|||
from matter_idl.matter_idl_types import Idl |
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.
Does is make sense to include other things like matter_idl
in known first party? I don't know one way or another just asking
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 think that it would be better to change the namespace of that module. But now the question might be whether it would be worth of changing it to chip
? Since, the entire project is going to be renamed, maybe we can "correct" the Python module name as well and name it matter.idl
?
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.
It seems that we could "claim" the matter
namespace and release the chip
: https://pypi.org/search/?q=matter
@@ -46,13 +46,14 @@ | |||
__ALL__ = (matter_idl_types) | |||
|
|||
|
|||
import click | |||
from matter_yamltests.definitions import SpecDefinitionsFromPaths | |||
from matter_yamltests.parser import PostProcessCheckStatus, TestParser, TestParserConfig |
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.
same with matter_yamltests
, should it be considered first party?
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.
Same as above. Maybe it should be matter.yamltests
?
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 think matter.*
would be better. Unsure if we used the current naming to satisfy our build rules ... if we do not have to fight it very hard, I prefer matter.testing
and matter.yamltests
and such.
Problem
CHIP imports are intermixed with 3rd party imports. Since,
chip
is "reserved" namespace for CHIP project, we can mark it as first-party from our point of view. This should improve imports readability.Commit 0d3c003 was created by running
isort
on entire codebase.Changes
Testing
CI should catch any issues with this PR