WrongOptionsDoctypeLinkError: Item: Options must be a valid DocType for field Manufacturers in row 130

Executing erpnext.patches.v11_0.ewaybill_fields_gst_india #2018-11-13 #2019-01-09 #2019-04-01 #2019-04-26 #2019-05-03 in promoterz_erp (_13b2ee6e61f4830c)
Traceback (most recent call last):
File “/usr/lib/python2.7/runpy.py”, line 174, in _run_module_as_main
main”, fname, loader, pkg_name)
File “/usr/lib/python2.7/runpy.py”, line 72, in _run_code
exec code in run_globals
File “/opt/bench/erpnext/apps/frappe/frappe/utils/bench_helper.py”, line 97, in
main()
File “/opt/bench/erpnext/apps/frappe/frappe/utils/bench_helper.py”, line 18, in main
click.Group(commands=commands)(prog_name=‘bench’)
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 764, in call
return self.main(*args, **kwargs)
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 717, in main
rv = self.invoke(ctx)
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 1137, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 956, in invoke
return ctx.invoke(self.callback, **ctx.params)
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/core.py”, line 555, in invoke
return callback(*args, **kwargs)
File “/opt/bench/erpnext/env/local/lib/python2.7/site-packages/click/decorators.py”, line 17, in new_func
return f(get_current_context(), *args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/commands/init.py”, line 25, in _func
ret = f(frappe._dict(ctx.obj), *args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/commands/site.py”, line 229, in migrate
migrate(context.verbose, rebuild_website=rebuild_website)
File “/opt/bench/erpnext/apps/frappe/frappe/migrate.py”, line 48, in migrate
frappe.modules.patch_handler.run_all()
File “/opt/bench/erpnext/apps/frappe/frappe/modules/patch_handler.py”, line 29, in run_all
if not run_single(patchmodule = patch):
File “/opt/bench/erpnext/apps/frappe/frappe/modules/patch_handler.py”, line 63, in run_single
return execute_patch(patchmodule, method, methodargs)
File “/opt/bench/erpnext/apps/frappe/frappe/modules/patch_handler.py”, line 83, in execute_patch
frappe.get_attr(patchmodule.split()[0] + “.execute”)()
File “/opt/bench/erpnext/apps/erpnext/erpnext/patches/v11_0/ewaybill_fields_gst_india.py”, line 10, in execute
make_custom_fields()
File “/opt/bench/erpnext/apps/erpnext/erpnext/regional/india/setup.py”, line 483, in make_custom_fields
create_custom_fields(custom_fields, update=update)
File “/opt/bench/erpnext/apps/frappe/frappe/custom/doctype/custom_field/custom_field.py”, line 147, in create_custom_fields
custom_field.save()
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 271, in save
return self._save(*args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 324, in save
self.run_post_save_methods()
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 917, in run_post_save_methods
self.run_method(“on_update”)
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 786, in run_method
out = Document.hook(fn)(self, *args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 1055, in composer
return composed(self, method, *args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 1038, in runner
add_to_return_value(self, fn(self, *args, **kwargs))
File “/opt/bench/erpnext/apps/frappe/frappe/model/document.py”, line 780, in
fn = lambda self, *args, **kwargs: getattr(self, method)(*args, **kwargs)
File “/opt/bench/erpnext/apps/frappe/frappe/custom/doctype/custom_field/custom_field.py”, line 61, in on_update
validate_fields_for_doctype(self.dt)
File “/opt/bench/erpnext/apps/frappe/frappe/core/doctype/doctype/doctype.py”, line 562, in validate_fields_for_doctype
validate_fields(frappe.get_meta(doctype, cached=False))
File “/opt/bench/erpnext/apps/frappe/frappe/core/doctype/doctype/doctype.py”, line 823, in validate_fields
check_link_table_options(meta.get(“name”), d)
File “/opt/bench/erpnext/apps/frappe/frappe/core/doctype/doctype/doctype.py”, line 607, in check_link_table_options
frappe.throw(
(“{0}: Options must be a valid DocType for field {1} in row {2}”).format(docname, d.label, d.idx), WrongOptionsDoctypeLinkError)
File “/opt/bench/erpnext/apps/frappe/frappe/init.py”, line 360, in throw
msgprint(msg, raise_exception=exc, title=title, indicator=‘red’)
File “/opt/bench/erpnext/apps/frappe/frappe/init.py”, line 346, in msgprint
_raise_exception()
File “/opt/bench/erpnext/apps/frappe/frappe/init.py”, line 315, in _raise_exception
raise raise_exception(msg)
frappe.core.doctype.doctype.doctype.WrongOptionsDoctypeLinkError: Item: Options must be a valid DocType for field Manufacturers in row 130

Here’s a similar but apparently unresolved error How to migrate v10.1.26 database to v11.x.x - v11_0.ewaybill_fields_gst_india patch WrongOptionsDoctypeLinkError

I have tried doing this. But it did’t work. I can’t find any doctype in my folder called manufacturers. Please do help us with a solution

You seem to have added your own doctype Manufacturers, so try this -

Start up a bench console and run this:

frappe.reload_doc('manufacturing', 'doctype', 'manufacturers')

Here’s an example console session