Openerp_ Magento Integration/sync Error - magento

Traceback (most recent call last):
File "/opt/openerp/server/openerp/addons/connector/queue/worker.py", line 123, in run_job
job.perform(session)
File "/opt/openerp/server/openerp/addons/connector/queue/job.py", line 492, in perform
self.result = self.func(session, *self.args, **self.kwargs)
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/import_synchronizer.py", line 378, in import_record
importer.run(magento_id, force=force)
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/import_synchroni zer.py", line 221, in run
self._import_dependencies()
File "/opt/openerp/server/openerp/addons/magentoerpconnect/sale.py", line 849, in _import_dependencies
'magento.product.product')
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/import_synchronizer.py", line 124, in _import_dependency
importer.run(magento_id)
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/import_synchronizer.py", line 206, in run
self.magento_record = self._get_magento_data()
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/import_synchronizer.py", line 63, in _get_magento_data
return self.backend_adapter.read(self.magento_id)
File "/opt/openerp/server/openerp/addons/magentoerpconnect/product.py", line 278, in read
[int(id), storeview_id, attributes, 'id'])
File "/opt/openerp/server/openerp/addons/magentoerpconnect/product.py", line 243, in _call
return super(ProductProductAdapter, self)._call(method, arguments)
File "/opt/openerp/server/openerp/addons/magentoerpconnect/unit/backend_adapter.py", line 168, in _call
result = api.call(method, arguments)
File "/usr/local/lib/python2.7/dist-packages/magento-0.4-py2.7.egg/magento/api.py", line 161, in call
return self.client.call(self.session, resource_path, arguments)
File "/usr/lib/python2.7/xmlrpclib.py", line 1224, in __call__
return self.__send(self.__name, args)
File "/usr/lib/python2.7/xmlrpclib.py", line 1578, in __request
verbose=self.__verbose
File "/usr/lib/python2.7/xmlrpclib.py", line 1264, in request
return self.single_request(host, handler, request_body, verbose)
File "/usr/lib/python2.7/xmlrpclib.py", line 1297, in single_request
return self.parse_response(response)
File "/usr/lib/python2.7/xmlrpclib.py", line 1473, in parse_response
return u.close()
File "/usr/lib/python2.7/xmlrpclib.py", line 793, in close
raise Fault(**self._stack[0])
Fault: <Fault 3: 'Invalid api path.'>
I Am Unable To Integrated & Sync My Products From Magento To Openerp,I Have Used The CampToCamp's Add-on In The Openerp & Have Added The Module On Magento. I Have Used My Magento Server Link & Have Added Enough Test Products Yet The Products Aren't Syncing Due To The Above error As In The Jobs Tab In Openerp. Please Help Me Get Through Or Understand What Am I Doing Wrongly.
Thank You In Advance.

The problem was the integration module which was installed on my magento site didn't match the integration module on Openerp so all i needed to do was install both from the same vender and it worked like a charm.
Just remove both the integration modules from openerp & magento,& follow a single vender for me i used the following guide to get the Integration working.
https://openerp-magento-connector.readthedocs.org/en/develop/index.html

Related

Trouble in Installing through pip3

I am trying to install packages through pip3
pip3 install keras
But, the error is as follows:
Collecting keras
Exception:
Traceback (most recent call last):
File "/usr/lib/python3/dist-packages/pip/basecommand.py", line 215, in main
status = self.run(options, args)
File "/usr/lib/python3/dist-packages/pip/commands/install.py", line 353, in run
wb.build(autobuilding=True)
File "/usr/lib/python3/dist-packages/pip/wheel.py", line 749, in build
self.requirement_set.prepare_files(self.finder)
File "/usr/lib/python3/dist-packages/pip/req/req_set.py", line 380, in prepare_files
ignore_dependencies=self.ignore_dependencies))
File "/usr/lib/python3/dist-packages/pip/req/req_set.py", line 554, in _prepare_file
require_hashes
File "/usr/lib/python3/dist-packages/pip/req/req_install.py", line 278, in populate_link
self.link = finder.find_requirement(self, upgrade)
File "/usr/lib/python3/dist-packages/pip/index.py", line 465, in find_requirement
all_candidates = self.find_all_candidates(req.name)
File "/usr/lib/python3/dist-packages/pip/index.py", line 423, in find_all_candidates
for page in self._get_pages(url_locations, project_name):
File "/usr/lib/python3/dist-packages/pip/index.py", line 568, in _get_pages
page = self._get_page(location)
File "/usr/lib/python3/dist-packages/pip/index.py", line 683, in _get_page
return HTMLPage.get_page(link, session=self.session)
File "/usr/lib/python3/dist-packages/pip/index.py", line 792, in get_page
"Cache-Control": "max-age=600",
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/sessions.py", line 521, in get
return self.request('GET', url, **kwargs)
File "/usr/lib/python3/dist-packages/pip/download.py", line 386, in request
return super(PipSession, self).request(method, url, *args, **kwargs)
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/sessions.py", line 508, in request
resp = self.send(prep, **send_kwargs)
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/sessions.py", line 618, in send
r = adapter.send(request, **kwargs)
File "/usr/share/python-wheels/CacheControl-0.11.7-py2.py3-none-any.whl/cachecontrol/adapter.py", line 47, in send
resp = super(CacheControlAdapter, self).send(request, **kw)
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/adapters.py", line 405, in send
conn = self.get_connection(request.url, proxies)
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/adapters.py", line 303, in get_connection
proxy_manager = self.proxy_manager_for(proxy)
File "/usr/share/python-wheels/requests-2.18.4-py2.py3-none-any.whl/requests/adapters.py", line 197, in proxy_manager_for
**proxy_kwargs)
File "/usr/share/python-wheels/urllib3-1.22-py2.py3-none-any.whl/urllib3/poolmanager.py", line 440, in proxy_from_url
return ProxyManager(proxy_url=url, **kw)
File "/usr/share/python-wheels/urllib3-1.22-py2.py3-none-any.whl/urllib3/poolmanager.py", line 391, in __init__
raise ProxySchemeUnknown(proxy.scheme)
urllib3.exceptions.ProxySchemeUnknown: Not supported proxy scheme
My institute needs a proxy and I updated proxy at all places in my system using ProxyMan.
Is it due to proxy? Because I had fresh install of Linux. If because of proxy, where do i need to update proxy?
I had a similar issue and I solved it by adding my proxy settings at the end of /etc/bash.bashrc like this:
export http_proxy="http://<user>:<pass>#<proxy>:<port>
export https_proxy="https://<user>:<pass>#<proxy>:<port>
export ftp_proxy="ftp://<user>:<pass>#<proxy>:<port>
export socks_proxy="socks://<user>:<pass>#<proxy>:<port>
You can try to use easy_install + packagename instead of pip.

When am trying to create a new spot instance through python code am getting this error can any one help me out

Unble to create EC2 Instance due to socket.getaddrinfo info
Traceback (most recent call last):
File "C:\workspace\test1\main.py", line 131, in <module>
main()
File "C:\workspace\test1\main.py", line 101, in main client =create_client()
File "C:\workspace\test1\main.py", line 19, in create_client regions= client.get_all_regions()
File "C:\Python34\lib\site-packages\boto\ec2\connection.py", line 3477, in get_all_regions[('item', RegionInfo)], verb='POST')
File "C:\Python34\lib\site-packages\boto\connection.py", line 1170, in get_list response = self.make_request(action, params, path, verb)
File "C:\Python34\lib\site-packages\boto\connection.py", line 1116, in make_request return self._mexe(http_request)
File "C:\Python34\lib\site-packages\boto\connection.py", line 1030, in _mexe raise ex
File "C:\Python34\lib\site-packages\boto\connection.py", line 943, in _mexe request.body, request.headers)
File "C:\Python34\lib\http\client.py", line 1088, in request self._send_request(method, url, body, headers)
File "C:\Python34\lib\http\client.py", line 1126, in _send_request self.endheaders(body)
File "C:\Python34\lib\http\client.py", line 1084, in endheaders self._send_output(message_body)
File "C:\Python34\lib\http\client.py", line 922, in _send_output self.send(msg)
File "C:\Python34\lib\http\client.py", line 857, in send self.connect()
File "C:\Python34\lib\site-packages\boto\https_connection.py", line 119, in connect sock = socket.create_connection((self.host, self.port), self.timeout)
File "C:\Python34\lib\socket.py", line 494, in create_connection for res in getaddrinfo(host, port, 22, SOCK_STREAM):
File "C:\Python34\lib\socket.py", line 533, in getaddrinfo for res in_socket.getaddrinfo(host, port, family, type, proto, flags):socket.gaierror: [Errno 10047] getaddrinfo failed
gaierror is related to getaddrinfo and your problem is probably due to the hostname. If not yet, you may try to change for the IP address, which doesn't need to be resolved.
If you can post details about your code, may be helpful. (I know this may be not a full answer, but I can't comment yet)

Google Apis Client Generator Python Not Running

I'm trying to execute Google APIs Client Generator to build new ADMIN-SDK for Java Language however I'm stuck in the generator, I've tried step by step using python2.6 and python2.7 both had similar outputs.
$ python $(/bin/pwd)/googleapis/codegen/generate_library.py --api_name=plus --api_version=v1 --language=java --output_dir=/tmp/gen --language=java
Traceback (most recent call last): File
"/Users/alejacquet/Development/git/google-apis-client-generator/src/googleapis/codegen/generate_library.py",
line 245, in
app.run() File "/Library/Python/2.7/site-packages/google_apputils-0.3.0-py2.7.egg/google/apputils/app.py",
line 216, in run
return _actual_start() File "/Library/Python/2.7/site-packages/google_apputils-0.3.0-py2.7.egg/google/apputils/app.py",
line 244, in _actual_start
really_start() File "/Library/Python/2.7/site-packages/google_apputils-0.3.0-py2.7.egg/google/apputils/app.py",
line 203, in really_start
sys.exit(main(argv)) File "/Users/alejacquet/Development/git/google-apis-client-generator/src/googleapis/codegen/generate_library.py",
line 152, in main
language_variant=FLAGS.language_variant) File "/Users/alejacquet/Development/git/google-apis-client-generator/src/googleapis/codegen/generate_library.py",
line 179, in Generate
language_variations = Targets().VariationsForLanguage(language) File
"/Users/alejacquet/Development/git/google-apis-client-generator/src/googleapis/codegen/targets.py",
line 68, in init
files.GetFileContents(self.targets_path)) File "/Users/alejacquet/Development/git/google-apis-client-generator/src/googleapis/codegen/json_with_comments.py",
line 54, in Loads
return json.loads(stripped, **kw) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/init.py",
line 326, in loads
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/decoder.py",
line 366, in decode File
"/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/json/decoder.py",
line 382, in raw_decode ValueError: Expecting property name: line 9
column 9 (char 198)
Any ideas?
You may have to specify --language_variant=XXX, where XXX is one of the directory names under .../templates/java

Remove cell from table

I have created my own Sales / Quotation report caleed sale_order.sxw using OpenOffice Write. From there I generate the sale_order.rml file.
I have two installation of OpenERP, one on Windows and one on Ubuntu.
In OOWriter, I have a 4 columns table that prints out each single order line along with Quantity, "Print this" text and Subtotal.
The third column is printed out only if a specific condition is met, based on the price list name containing "final":
So I expect:
If "final" is not located within the price list
Product A|2|Print this |20
If "final" is located within the price list:
Product A|2|20
To solve this, I have the following code:
(so.partner_id.property_product_pricelist.name.find('final') > 0) and "Print this" or removeParentNode('td')
It works fine from the windows installation.
But when I run the same file from the Ubuntu installation I get an AssertionError message and I can't print out my Sales / Quotation pdf report.
I did some testing specifically with the removeParentNode('td') and the error seems to come from there, but I can't work out why as it works under windows!
Here is the log from the Ubuntu server:
2013-04-15 13:09:07,822 1621 ERROR ? openerp.service.web_services: Exception:
Traceback (most recent call last):
File "/home/download/openerp-6.1-20121008-233119/openerp/service/web_services.py", line 727, in go
(result, format) = obj.create(cr, uid, ids, datas, context)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/report_sxw.py", line 442, in create
fnct_ret = fnct(cr, uid, ids, data, report_xml, context)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/report_sxw.py", line 511, in create_source_pdf
return self.create_single_pdf(cr, uid, ids, data, report_xml, context)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/report_sxw.py", line 533, in create_single_pdf
pdf = create_doc(etree.tostring(processed_rml),rml_parser.localcontext,logo,title.encode('utf8'))
File "/home/download/openerp-6.1-20121008-233119/openerp/report/interface.py", line 207, in create_pdf
obj.render()
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/render.py", line 59, in render
self._result = self._render()
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml.py", line 41, in _render
return rml2pdf.parseNode(self.rml, self.localcontext, images=self.bin_datas, path=self.path,title=self.title)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 1007, in parseNode
r.render(fp)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 314, in render
pt_obj.render(el)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 983, in render
fis += r.render(node_story)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 877, in render
return process_story(node_story)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 870, in process_story
flow = self._flowable(node)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 834, in _flowable
return self.render(node)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 877, in render
return process_story(node_story)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 870, in process_story
flow = self._flowable(node)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 793, in _flowable
return self._table(node)
File "/home/download/openerp-6.1-20121008-233119/openerp/report/render/rml2pdf/trml2pdf.py", line 697, in _table
assert length == len(node.get('colWidths').split(','))
AssertionError
2013-04-15 13:09:07,951 1621 ERROR ? openerp.netsvc:
(<type 'exceptions.AssertionError'>, AssertionError(), <traceback object at 0x7ff558e54b00>)
2013-04-15 13:09:07,953 1621 INFO ? werkzeug: 192.168.2.4 - - [15/Apr/2013 13:09:07] "POST /web/report HTTP/1.1" 500 -
I did a comparison between the trml2pdf.py files used on the server and the one used by windows and they are identical.
This is because of un matching original column.

File permission issue with apache+mod_wsgi with pyramid&pyramid_beaker

I am trying to set up a pyramid app. I am using wsgi and apache2.
I keep getting Internal server error and the contents of the apache log is
mod_wsgi (pid=11200): Exception occurred processing WSGI script '/home/ubuntu/modwsgi/env/pyramid.wsgi'.
Traceback (most recent call last):
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/pyramid-1.3-py2.6.egg/pyramid/router.py", line 191, in __call__
request._process_response_callbacks(response)
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/pyramid-1.3-py2.6.egg/pyramid/request.py", line 243, in _process_response_callbacks
callback(self, response)
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/pyramid_beaker-0.6.1-py2.6.egg/pyramid_beaker/__init__.py", line 26, in session_callback
self.persist()
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/Beaker-1.6.3-py2.6.egg/beaker/session.py", line 706, in persist
self._session().save()
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/Beaker-1.6.3-py2.6.egg/beaker/session.py", line 400, in save
**self.namespace_args)
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/Beaker-1.6.3-py2.6.egg/beaker/container.py", line 622, in __init__
util.verify_directory(self.file_dir)
File "/home/ubuntu/modwsgi/env/lib/python2.6/site-packages/Beaker-1.6.3-py2.6.egg/beaker/util.py", line 85, in verify_directory
os.makedirs(dir)
File "/usr/lib/python2.6/os.py", line 150, in makedirs
makedirs(head, mode)
File "/usr/lib/python2.6/os.py", line 157, in makedirs
mkdir(name, mode)
OSError: [Errno 13] Permission denied: 'beaker_dir'
I can use simple pserve to serve the page and run wget http://localhost:6543/user/form on the terminal. It works well with form getting downloaded. But over the browser I get the 500 error.
I am using EC2 to host the app.
In the app:main stanza I am using the following code:
session.type = file
session.data_dir = beaker_dir
session.key = mvc
session.encrypt_key = mysecretencryptionkey
session.validate_key = mysecretvalidationkey
session.cookie_on_exception = true
Thanks a lot for reading
Supply an absolute path for:
session.data_dir = beaker_dir
The current working directory could be anything, usually '/', and so path will be wrong.

Resources