Skip to main content
GoodFirstPicks
DashboardIssuesReposLeaderboard

GoodFirstPicks by Leaveitblank © 2026

CreatorRequest a RepoPrivacy PolicyTerms of Service
All fields are empty after paste doctype json content due to copy_doc not set doctype for child doc | GoodFirstPicks

All fields are empty after paste doctype json content due to copy_doc not set doctype for child doc

frappe/frappe 1 comments 1mo ago
View on GitHub
lowopenScope: somewhat clearSkill match: maybeFrappe / ERPNextPython

Why this is a good first issue

Bug involves incorrect handling of doctype in child documents during paste operation.

AI Summary

The issue occurs when pasting JSON content into ERPNext, where child documents lose their doctype information, leading to empty fields. The fix involves ensuring doctype is correctly set for child documents. The maintainer has requested a PR with a video demonstration.

Issue Description

Description of the issue

Context information (for bug reports)

Output of bench version

(paste here)

Steps to reproduce the issue

  1. drap select any existing doctype json file content and copy (ctrl + c)
  2. in any erpnext screen, paste (ctrl + v)
  3. system auto switch to doctype form view,

Observed result

only empty fields records pasted

Expected result

fields correctly copied

Stacktrace / full error message

(paste here)

Additional information

in the doctype json files, only child table field name is mentioned, in each child record there is no DocType, the copy_doc function relies on the doctype info to correctly copy the child doc.

{

 "doctype": "DocType",
  'name':'dummy'
 "fields": [
  {
   "fieldname": "holiday_date",
   "label": "Date",
  }]
}

the following highlighted line to be added. image

OS version / distribution, Frappe install method, etc.

GitHub Labels

bug

Want to work on this?

Claim this issue to let others know you're working on it. You'll earn 10 points when you complete it!

Risk Flags

  • requires understanding of doctype handling
Loading labels...

Details

Points10 pts
Difficultylow
Scopesomewhat clear
Skill Matchmaybe
Test Focusedno
Assigneestravo1