Skip to content

luci-app-frps: avoid saving the same form twice - #9012

Open
WROIATE wants to merge 1 commit into
openwrt:masterfrom
WROIATE:fix/frps-duplicate-form-save
Open

luci-app-frps: avoid saving the same form twice#9012
WROIATE wants to merge 1 commit into
openwrt:masterfrom
WROIATE:fix/frps-duplicate-form-save

Conversation

@WROIATE

@WROIATE WROIATE commented Sep 7, 2026

Copy link
Copy Markdown

The status section renders a nested cbi-map without a bound form instance. LuCI resolves it to the enclosing map, so save and reset invoke that map twice. Concurrent saves can submit duplicate UCI delete requests and report resource not found.

Pull request details

Description

Remove the form marker from the status wrapper while retaining its fieldset and polling. This addresses the duplicate-save cause of issue #7679.

Screenshot or video of changes (if applicable)

Related with issue #7679.

Maintainer (preferred)

Cannot find it in the Makefile, maybe ask @ysc3839 for help?

Tested on

OpenWrt version: ImmortalWrt 25.12.1 (OpenWrt downstream)
LuCI version: ImmortalWrt branch openwrt-25.12 26.187.07797~ed7692c (OpenWrt downstream)
Web browser(s): Edge 152.0.4191.53


Checklist

  • (Nice to have) Includes what Issue it closes (e.g. openwrt/luci#issue-number).
  • (Nice to have) Includes what it depends on (e.g. openwrt/packages#pr-number in sister repo).

@openwrt openwrt Bot added the not following guidelines Pull request does not follow formatting guidelines label Sep 7, 2026
The status section renders a nested cbi-map without a bound form
instance. LuCI resolves it to the enclosing map, so save and reset
invoke that map twice. Concurrent saves can submit duplicate UCI delete
requests and report resource not found.

Remove the form marker from the status wrapper while retaining its
fieldset and polling. This addresses the duplicate-save cause of
issue openwrt#7679.

Signed-off-by: Javen Li <j.wroiate@gmail.com>
@WROIATE
WROIATE force-pushed the fix/frps-duplicate-form-save branch from 3c92e31 to 4ca8719 Compare September 7, 2026 03:22
@openwrt openwrt Bot removed the not following guidelines Pull request does not follow formatting guidelines label Sep 7, 2026

@openwrt-ai openwrt-ai left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed 1 new commit; no new issues found.


Generated by Claude Code

});

return E('div', { class: 'cbi-map' },
return E('div', {},

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: the sibling client app has the identical nested-cbi-map status wrapper at frpc.js:1415 and is left unchanged here, so frpc still double-saves. Is leaving it out intentional, or should the same one-line change land there too?


Generated by Claude Code

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the solution should be the same.

@laipeng668

Copy link
Copy Markdown
Contributor

The current LuCI master branch is a completely redesigned version that I developed with AI assistance. The issue you mentioned is from the older LuCI 25.12 branch ; it does not exist in the new version.

The code in the master branch is likely intentionally written this way to address a different issue. If this is an issue specific to the 25.12 branch, it should not be submitted to the master branch.

现在这个LuCI的master分支,是我用AI设计的全新版本,你那个问题是老LuCI的25.12分支的问题,新版本没有这个问题。

这行master分支的代码应该是为了解决其他问题故意这样的,如果是25.12分支的问题,不应该提交到master分支。

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