Skip to content

Wiki Document route gets replaced with random hash #590

@federicocalvo

Description

@federicocalvo

Description:

When saving a Wiki Document from the Desk (form view), the route field gets overwritten with a random hash, losing the original meaningful route.

Steps to reproduce:

  1. Install Frappe + Wiki alongside other apps (ERPNext, Frappe CRM, Frappe Helpdesk)
  2. Open a Wiki Document from the Desk
  3. Set or confirm a meaningful route (e.g. docs/my-page)
  4. Save the document
  5. The route field is replaced with a random hash

Expected behavior: The route should remain unchanged on save if it was already set.

Actual behavior: The route is replaced with a seemingly random hash value on every save.

Environment:

  • Branch: develop
  • Works correctly: Frappe + Wiki only (clean install)
  • Fails: Frappe + ERPNext + Payments + Frappe CRM + Frappe Helpdesk + Builder + Drive + Telephony +Wiki

Possible cause:

The Wiki Document DocType does not define an autoname property in its JSON definition, and the set_route() method only runs when self.route is falsy. This suggests another installed app may have a global doc_events hook (e.g. on "*" > validate or before_save) that clears or overwrites the route field before Wiki's own validate() runs. Since the issue only occurs when additional apps are installed alongside Wiki, a hook from ERPNext, Frappe CRM, or Frappe Helpdesk is likely interfering.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions