Skip to content

Conversation

@zccrs
Copy link
Member

@zccrs zccrs commented Feb 25, 2025

The DConfig is a sync IO API, call it's API maybe block the GUI thread on the DConfigWrapper, so we need use the DConfig in a new thread.

@zccrs zccrs requested a review from 18202781743 February 25, 2025 03:09
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Feb 25, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
@zccrs zccrs mentioned this pull request Feb 25, 2025
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Feb 25, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Feb 25, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
@zccrs
Copy link
Member Author

zccrs commented Feb 25, 2025

@18202781743 你试一下功能是否ok, 另外可以模拟一下dconfig service卡死的情况(用gdb attach上去暂停它),看会不会影响GUI

@18202781743
Copy link
Contributor

@18202781743 你试一下功能是否ok, 另外可以模拟一下dconfig service卡死的情况(用gdb attach上去暂停它),看会不会影响GUI

好的,

@18202781743
Copy link
Contributor

18202781743 commented Feb 27, 2025

@18202781743 你试一下功能是否ok, 另外可以模拟一下dconfig service卡死的情况(用gdb attach上去暂停它),看会不会影响GUI

deepin-music的设置,用到的Config, 用此pr会提示以下错误,正常情况下,是能够保存设置,并且可以重置,

image

入口是,
image
image

@deepin-bot
Copy link
Contributor

deepin-bot bot commented Feb 27, 2025

TAG Bot

New tag: 5.7.11
DISTRIBUTION: unstable
Suggest: synchronizing this PR through rebase #470

deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 3, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 5, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
@deepin-ci-robot
Copy link
Contributor

deepin pr auto review

关键摘要:

  • DConfigWrapper::componentComplete方法中,initializeConfigs的初始化应该放在impl对象创建之前,以确保在DConfig初始化之前获取QML中定义的属性和值。
  • DConfigWrapper::initializeProperties方法中,impl对象的创建应该放在Q_ASSERT(!impl);之后,以确保impl对象在Q_ASSERT检查通过后创建。
  • DConfigWrapper::initializeProperties方法中,callInGuiThread函数的使用应该确保在主线程中设置成员变量,以避免线程安全问题。
  • DConfigWrapper::initializeProperties方法中,connect信号槽连接应该使用Qt::DirectConnection,以确保在impl->setValue可能发射的同步信号时能够及时更新UI。
  • DConfigWrapper::setAsync方法中,应该检查mo是否为空,以避免在对象初始化之前修改异步设置。

是否建议立即修改:

deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 6, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 6, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 6, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
The DConfig is a sync IO API, call it's API maybe block the GUI thread
on the DConfigWrapper, so we need use the DConfig in a new thread.
deepin-ci-robot added a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 6, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
@zccrs
Copy link
Member Author

zccrs commented Mar 6, 2025

@18202781743 你试一下功能是否ok, 另外可以模拟一下dconfig service卡死的情况(用gdb attach上去暂停它),看会不会影响GUI

deepin-music的设置,用到的Config, 用此pr会提示以下错误,正常情况下,是能够保存设置,并且可以重置,

image

入口是, image image

Fix

@deepin-ci-robot
Copy link
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: 18202781743, zccrs

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@18202781743
Copy link
Contributor

18202781743 commented Mar 6, 2025

@18202781743 你试一下功能是否ok, 另外可以模拟一下dconfig service卡死的情况(用gdb attach上去暂停它),看会不会影响GUI

deepin-music的设置,用到的Config, 用此pr会提示以下错误,正常情况下,是能够保存设置,并且可以重置,
image
入口是, image image

Fix

测试过,deepin-music功能是正常的,异步不阻塞gui,

@zccrs zccrs merged commit 7d37100 into linuxdeepin:master Mar 6, 2025
19 of 21 checks passed
18202781743 pushed a commit to linuxdeepin/dtk6declarative that referenced this pull request Mar 6, 2025
Synchronize source files from linuxdeepin/dtkdeclarative.

Source-pull-request: linuxdeepin/dtkdeclarative#464
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants