i am getting error in odoo13 i setup new odooo i am try to install new custom modules - python-3.7

odoo/odoo/addons/base/models/ir_ui_view.py", line 592, in raise_view_error
raise ValueError(message)
ValueError: Field `invoice_is_snailmail` does not exist
Error context:
View `n/a`
[view_id: n/a, xml_id: n/a, model: n/a, parent_id: n/a]
I check in my code invoice_is_snailmail this files written in files but still odoo though an error
I am beginner in odoo developer. can you please answer.

The field invoice_is_snailmail is a field in standard Odoo module snailmail_account. If you want to use this field in your custom module, you need to install snailmail_account module first.
Best practice is to list the dependent module snailmail_account as a dependency in your module so that Odoo will install it automatically. More info on module definition and depends can be found here: https://www.odoo.com/documentation/13.0/reference/module.html, see manifest field depends.
If this does not help you, you need to provide more information in your question, e.g your source code for your custom module. Without your exact code it is hard to help more, see question guidelines at https://stackoverflow.com/help/how-to-ask.

Please Provide Code Screenshots or check fields define in py and xml in same module or field for xml in child module.

Related

distilbert model is not working at ktrain

I tried to use distilbert classifier. but I am getting the following error.
This is my code
(X_train,y_train),(X_test,y_test),prepro
=text.texts_from_df(train_df=data_train,text_column="Cleaned",label_columns=col
,val_df=data_test,maxlen=500,preprocess_mode="distilbert")
and here is the error
OSError: Model name 'distilbert-base-uncased' was not found in tokenizers model name list (distilbert-base-uncased, distilbert-base-uncased-distilled-squad, distilbert-base-cased, distilbert-base-cased-distilled-squad, distilbert-base-german-cased, distilbert-base-multilingual-cased). We assumed 'distilbert-base-uncased' was a path, a model identifier, or url to a directory containing vocabulary files named ['vocab.txt'] but couldn't find such vocabulary files at this path or url._
Due to my office current environmental issue, I can only work on tf 2.2 and python 3.8. Right now I am using 0.19.
Do you think it will affect my current environment if I downgrade it to 0.16?
This error may happen if there is a network or firewall issue preventing download of the tokenizer files. See this FAQ entry for remedies.
Also, when you use preprocess_mode='distilbert', texts_from* functions return TransformerDataset instances, not arrays. You'll need to replace (X_train, y_train) with train_data, for example. See this example notebook.

Kettle getStepMetaInterface() function error in Modified Script with MongoDB Output step

Using pentaho 5.3, Modified Java Script Value step to inject those data.
I want to dynamically set path and names in the MongoDB Output step. Here is my code
var meta = new org.pentaho.di.trans.TransMeta( source_path );
var mongoStep = meta.findStep("MongoDB Output");
mongoStep.setDescription('This is MongoDB Output by Ray');
Alert(mongoStep.getName()); // code is ok until here.
var mongoStepMeta = mongoStep.getStepMetaInterface() // error occurs here
When I want to get the getStepMetaInterface() to use step functions, the error occurs.
java.lang.LinkageError: loader constraint violation: loader (instance of org/pentaho/di/core/plugins/KettleURLClassLoader) previously initiated loading for a different type with name "org/pentaho/metastore/api/IMetaStore"
This error seems to be generated by the violation of .jar.
But when I use those original steps, like "Microsoft Access Input", I can successfully get getStepMetaInterface(). In this way, I can use all the functions defined in AccessInputMeta.java.
From my point of view, this problem may have a relation to the MongoDB Output step, because this is a plugin for kettle, but I am not sure.
Any response is appreciated!!
Yep, it's because of the plugin system. The Modified Java Script step and the Access Input step (among many others) are all in the Kettle engine and share a classloader. External plugins (like MongoDB Input/Output) have their own isolated classloaders. You have to do some voodoo with thread context classloaders and reflection in order to get at the Meta classes for those steps.
Here's an example of the hoops you have to jump through to get at external plugins (the Big Data plugin in this example) from the Modified Java Script step:
https://github.com/brosander/pentaho-hadoop-shims/blob/verification-2/test/verification/jobs/dependencies/ForceHiveToConnectRemotely.ktr
First, thanks to Mass who solves the problem.
Here is his advice:
This problem is caused by jar file conflict.
In pentaho installation there are two jar files:
-lib/metastore-5.3.0.0-213.jar
-plugins/pentaho-mongodb-plugin/lib/metastore-5.3.0.0-213.jar
Just remove the last jar file, this error will disappear.

Birt Multi Sheet report using SpudSoft

I´m having some problems to create reports in my server without default export engine.
I´m using SpudSoft to create it. I have the following configuration:
Tomcat 7
Birt 4.2.2
uk.co.spudsoft.birt.emitters.excel_0.8.0.201310230652.jar
And i followed this tutorial:
spudsoft-birt-excel-emitters
I haven´t include this file
lib/slf4j-api-1.6.2.jar
because it´s not included in the *.jar file
and either wrote this code:
'if( "XLS".equalsIgnoreCase( outputFileFormat ) ) {
renderOption.setEmitterID( "uk.co.spudsoft.birt.emitters.excel.XlsEmitter" );
} else if( "XLSX".equalsIgnoreCase( outputFileFormat ) ) {
renderOption.setEmitterID( "uk.co.spudsoft.birt.emitters.excel.XlsxEmitter" );
}'
Because I dont really know where to use it.
to run my report i use the following URL
http://127.0.0.1:8090/birt-viewer/frameset?__format=xls&__report=informes/myReport.rptdesign&__emitterid=uk.co.spudsoft.birt.emitters.excel.XlsEmitter
and i get the following message:
org.eclipse.birt.report.service.api.ReportServiceException: EmitterID uk.co.spudsoft.birt.emitters.excel for render option is invalid.
What can i do to run SpudSoft report? I've been reading for a week and I haven´t found any solution!
Thanks a lot for all!
#Dominique,
I recommend upgrading from the emitter included with BIRT 4.3 (and given the lack of responses from the BIRT team I regret letting them put it in there).
Also, you don't need to use a specific IRenderOption type - they are all the same really anyway.
#Jota,
If you are getting that error it means that BIRT hasn't picked up the emitter correctly (you do have the correct emitter ID).
I don't use the BIRT war file, so my instructions aren't aimed at that approach (I just use the report engine in my own service).
The code snippet is no use for you, it's just a way to specify the emitter ID, which you are doing on the query string.
slf4j shouldn't be needed with the version of the emitter that you have - it uses JUL instead (I hate JUL, but it's one fewer dependency).
Can you post a complete listing of the jar files in your war?
It seems because you make use of a generic IRenderOption. With spudsoft emitter you should instantiate your render options like this:
EXCELRenderOption excelOptions = new EXCELRenderOption();
Note if you upgrade to BIRT 4.3 you don't have to set the emitter anymore, it is embedded

Magento - Error after disabling modules

I've disabled the Rss and Newsletter modules of my Magento 1.7 instance following the instructions of this post:
http://inchoo.net/ecommerce/magento/how-to-fully-disable-turn-off-magento-module/comment-page-1/#comment-65853
I just edited the app\etc\modules\Mage_All.xml file by changing to <active>false</active> in both Mage_Rss and Mage_Newsletter modules.
The problem is that when I try to load a customer page through admin panel, I get the following error:
Fatal error: Call to a member function loadByCustomer() on a
non-object in app\code\core\Mage\Newsletter\Model\Subscriber.php on
line 267
Why is it happening? Why is this code being executing even though I've disabled such module?
Thanks!
First step after disabling a module through its <active> entry. Always clear cache and if you use the compiler, recompile so you don't have code referencing classes in the disabled module.
Often the problem is not with code executing after the module is shut off through the app/etc/modules/mod_name.xml by setting <active> to false, but with other modules, templates or layouts attempting to call code in the disabled module.
Where issues come in are if another module lists the module just turned off in its dependency list. Always check all the other module xml files dependency lists for mention of the module you are deactivating.
Also, you have to check for template .phtml files that reference classes in the disabled module. This can throw the dreaded call to a non-object type exception errors. As an example, one module that provides custom cart attributes asks you to add entries to your cart templates. Shutting off the module does not get rid of the references.
Make sure no layouts are attempting to load anything referencing this module as well (custom layout local.xml).
You also might want to go to System Config, Advanced and shut the Newsletter module output off there in case the Magento Customer Account is depending on testing for the module being disabled by calling that entry instead of actually checking to see if the Module is loaded. Sometimes Magento programmers forget to do proper error trapping, which has thrown me for a loop before.
I believe I could solve the problem (not sure if generated any side effect):
Just edited the file app\code\core\Mage\Adminhtml\Block\Customer\Edit\Tabs.php around line 90 by adding the external if clause:
if (Mage::helper('core')->isModuleEnabled('Mage_Newsletter')) {
if (Mage::getSingleton('admin/session')->isAllowed('newsletter/subscriber')) {
$this->addTab('newsletter', array(
'label' => Mage::helper('customer')->__('Newsletter'),
'content' => $this->getLayout()->createBlock('adminhtml/customer_edit_tab_newsletter')->initForm()->toHtml()
));
}
}
+1 if I saved your day and please let me know if you noticed and possible impact :D

Data.c file generation

i'm very new to matlab, i'm working on a software which needs the following files as input model.c,model.h,model_data.c for a particular simulink model. I have a model for which i can't generate model_data file using RTW, i have tried to get some information on the files generated by RTW, but i didnt get sufficient info. If there anybody who knows about the RTW please let me know the blocks which are required to generate model_data.c
thank you
model_data.c is a conditionally created file (i.e. it is only created if it is needed, which depends on the way the model is set up for code generation).
For a discussion of the Simulink Coder build process, and what files get generated when, search the doc for the section titled "Files and Folders Created by Build Process".
For others who need help in future.
Open the Configuration Parameters pane. Go to Code Generation -> Optimization and make sure that Default parameter behavior is set to Tunable.