8000 Restyle [python/mdns] Add "discover" command for operational discovery by restyled-io[bot] · Pull Request #5144 · project-chip/connectedhomeip · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Restyle [python/mdns] Add "discover" command for operational discovery #5144

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

Closed
wants to merge 6 commits into from

Conversation

restyled-io[bot]
Copy link
Contributor
@restyled-io restyled-io bot commented Mar 4, 2021

A duplicate of #5025 with additional commits that automatically address
incorrect style, created by Restyled.

Since the original Pull Request was opened as a fork in a contributor's
repository, we are unable to create a Pull Request branching from it with only
the style fixes.

The following Restylers made fixes:

  • whitespace
  • clang-format

To incorporate these changes, you can either:

  1. Merge this Pull Request instead of the original, or

  2. Ask your contributor to locally incorporate these commits and push them to
    the original Pull Request

    Expand for example instructions
    ```console
    git remote add upstream https://github.com/project-chip/connectedhomeip.git
    git fetch upstream pull/<this PR number>/head
    git merge --ff-only FETCH_HEAD
    git push
    ```
    

NOTE: As work continues on the original Pull Request, this process will
re-run and update (force-push) this Pull Request with updated style fixes as
necessary. If the style is fixed manually at any point (i.e. this process finds
no fixes to make), this Pull Request will be closed automatically.

Sorry if this was unexpected. To disable it, see our documentation.

8000
Damian-Nordic and others added 6 commits March 4, 2021 00:25
Expose the mDNS resolver functionality implemented for
Avahi/Linux using a new Resolver interface.
Add DeviceAddressUpdater class which updates device
addresses in the device controller based on responses from
mDNS resolver. A result of an update/resolution request
can be passed to an optional DeviceAddressUpdateDelegate.

Add "resolve <fabricid> <nodeid>" command to the Python
CHIP controller. Usage:
1. Build CHIP with chip_mdns_advertiser="platform" argument.
2. Start Python CHIP controller.
3. Pair a CHIP device using "connect -ble" command.
4. Resolve the node ID using "resolve <fabricid> <nodeid>".

Note that Thread devices currently don't support the DNS-SD
service registration, but one can still test the new command
by registering the necessary services manually, e.g.

avahi-publish-address test-host.local. fd11:22::1 &
avahi-publish-publish-service -H test-host.local \
    <fabricid-hex>-<nodeid-hex> _chip._tcp 11097
On Linux, DiscoveryImplPlatform constructor refers to
MdnsAvahi global object which may not yet be initialized.
Some refactoring in the code is required to come up with
a better solution, but for now make sure that
DiscoveryImplPlatform is not initialized prior to MdnsAvahi.
@restyled-io restyled-io bot added the restyled label Mar 4, 2021
@todo
Copy link
todo bot commented Mar 4, 2021

Clean Mdns initialization order

// TODO: Clean Mdns initialization order
// Previously sManager was a global object, but DiscoveryImplPlatform constructor calls
// platform-specific ChipMdnsInit() which for Linux initializes MdnsAvahi global object
// and that may lead to improper initialization, since the order in which global objects'
// constructors are called is undefined.
static DiscoveryImplPlatform sManager;
return sManager;
}
ServiceAdvertiser & chip::Mdns::ServiceAdvertiser::Instance()


This comment was generated by todo based on a TODO comment in 4ebe5a5 in #5144. cc @project-chip.

@github-actions
Copy link
github-actions bot commented Mar 4, 2021

Size increase report for "esp32-example-build" from 57cd563

File Section File VM
chip-all-clusters-app.elf .dram0.bss 0 8
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-all-clusters-app.elf and ./pull_artifact/chip-all-clusters-app.elf:

sections,vmsize,filesize
.xt.lit._ZN4chip11DeviceLayer8Internal26GenericPlatformManagerImplINS0_19PlatformManagerImplEE26DispatchEventToSystemLayerEPKNS0_15ChipDeviceEventE,0,40
.dram0.bss,8,0
.xt.prop._ZN4chip11DeviceLayer8Internal26GenericPlatformManagerImplINS0_19PlatformManagerImplEE16_AddEventHandlerEPFvPKNS0_15ChipDeviceEventEiEi,0,-12
.xt.lit._ZN4chip11DeviceLayer8Internal26GenericPlatformManagerImplINS0_19PlatformManagerImplEE16_AddEventHandlerEPFvPKNS0_15ChipDeviceEventEiEi,0,-48

Comparing ./master_artifact/chip-pigweed-app.elf and ./pull_artifact/chip-pigweed-app.elf:

sections,vmsize,filesize


@github-actions
Copy link
github-actions bot commented Mar 4, 2021

Size increase report for "nrfconnect-example-build" from 57cd563

File Section File VM
chip-lock.elf [LOAD #3 [RW]] 0 23
chip-lock.elf datas 4 4
chip-lock.elf devices -4 -4
chip-lock.elf bss 0 -855
chip-lock.elf rodata -1624 -1620
chip-lock.elf text -9792 -9792
chip-lighting.elf [LOAD #3 [RW]] 0 31
chip-lighting.elf datas 4 4
chip-lighting.elf devices -4 -4
chip-lighting.elf bss 0 -863
chip-lighting.elf rodata -1616 -1620
chip-lighting.elf text -9792 -9792
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-lock.elf and ./pull_artifact/chip-lock.elf:

sections,vmsize,filesize
[LOAD #3 [RW]],23,0
datas,4,4
.shstrtab,0,-3
devices,-4,-4
bss,-855,0
.debug_aranges,0,-1368
rodata,-1620,-1624
.debug_frame,0,-4384
.symtab,0,-6416
text,-9792,-9792
.strtab,0,-10869
.debug_ranges,0,-13856
.debug_abbrev,0,-29368
.debug_str,0,-31547
.debug_loc,0,-39897
.debug_line,0,-50665
.debug_info,0,-300883

Comparing ./master_artifact/chip-lighting.elf and ./pull_artifact/chip-lighting.elf:

sections,vmsize,filesize
[LOAD #3 [RW]],31,0
datas,4,4
.shstrtab,0,-3
devices,-4,-4
bss,-863,0
.debug_aranges,0,-1368
rodata,-1620,-1616
.debug_frame,0,-4384
.symtab,0,-6416
text,-9792,-9792
.strtab,0,-10869
.debug_ranges,0,-13856
.debug_abbrev,0,-29368
.debug_str,0,-31547
.debug_loc,0,-39893
.debug_line,0,-50693
.debug_info,0,-300955

Comparing ./master_artifact/chip-shell.elf and ./pull_artifact/chip-shell.elf:

sections,vmsize,filesize


@github-actions
Copy link
github-actions bot commented Mar 4, 2021

Size increase report for "gn_qpg6100-example-build" from 57cd563

File Section File VM
chip-qpg6100-lock-example.out .heap 0 840
chip-qpg6100-lock-example.out .data 4 4
chip-qpg6100-lock-example.out .bss 0 -848
chip-qpg6100-lock-example.out .text -16516 -16516
Full report output
BLOAT REPORT

Files found only in the build output:
    report.csv

Comparing ./master_artifact/chip-qpg6100-lock-example.out and ./pull_artifact/chip-qpg6100-lock-example.out:

sections,vmsize,filesize
[Unmapped],0,16484
.heap,840,0
[ELF Headers],0,32
.data,4,4
.shstrtab,0,3
.bss,-848,0
.debug_aranges,0,-1136
.debug_frame,0,-3744
.symtab,0,-6208
.strtab,0,-9187
.debug_ranges,0,-11584
.text,-16516,-16516
.debug_abbrev,0,-27559
.debug_str,0,-31991
.debug_line,0,-54644
.debug_loc,0,-57255
.debug_info,0,-287751


@restyled-io restyled-io bot closed this Mar 4, 2021
@restyled-io restyled-io bot deleted the restyled/pull-5025 branch March 4, 2021 08:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0