GithubHelp home page GithubHelp logo

bitranox / lib_shopware6_api Goto Github PK

View Code? Open in Web Editor NEW
5.0 5.0 0.0 266 KB

higher level functions for shopware6 based on lib_shopware6_api_base

License: MIT License

Makefile 0.94% Python 85.04% Jupyter Notebook 1.01% Shell 12.34% Batchfile 0.67%

lib_shopware6_api's People

Contributors

bitranox avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

lib_shopware6_api's Issues

401 Client Error: Unauthorized for Access token - Access token could not be verified

  • **I'm submitting a ... **

    • bug report
    • feature request
    • support request
  • What is the current behavior?
    Traceback (most recent call last):
    File "...\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api_base\lib_shopware6_api_base.py", line 753, in _request
    response.raise_for_status()
    File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\requests\models.py", line 960, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
    requests.exceptions.HTTPError: 401 Client Error: Unauthorized for url: XXX/api/search/product-media

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\click\core.py", line 1055, in main
rv = self.invoke(ctx)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\click\core.py", line 1404, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\click\core.py", line 760, in invoke
return __callback(*args, **kwargs)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\typer\main.py", line 500, in wrapper
return callback(**use_params) # type: ignore
File ".../shopware_automation/main.py", line 39, in main
product_media = api.product.search_product_medias(payload=filter)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api\sub_product.py", line 533, in search_product_medias
response_dict = self._admin_client.request_post_paginated("search/product-media", payload)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api_base\lib_shopware6_api_base.py", line 538, in request_post_paginated
response_dict = self._request_paginated(http_method="post", request_url=request_url, payload=payload, junk_size=junk_size)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api_base\lib_shopware6_api_base.py", line 633, in _request_paginated
partial_data = self._make_request(http_method=http_method, request_url=request_url, payload=payload_dict)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api_base\lib_shopware6_api_base.py", line 698, in _make_request
response = self._request(http_method=http_method, request_url=request_url, payload=payload_dict)
File "...\Cache\virtualenvs\shopware-automation-OzY02_Lq-py3.10\lib\site-packages\lib_shopware6_api_base\lib_shopware6_api_base.py", line 759, in _request
raise ShopwareAPIError(f"{exc}{detailed_error}")
lib_shopware6_api_base.conf_shopware6_api_base_classes.ShopwareAPIError: 401 Client Error: Unauthorized for url: XXX/api/search/product-media : {"errors":[{"code":"9","status":"401","title":"The resource owner or authorization server denied the request.","detail":"Access token could not be verified"}]}

  • **If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    After arround 10 minutes the server error occure. Sometimes the error occure, sometimes not.
    Looks like Server API Error. If you catch exeption and retry the request the API get a new token.

  • What is the expected behavior?
    get refresh token without error

  • Please tell us about your environment:

  • Release Number of the Repository used : 2.0.2
  • Python Version : 3.10
  • OS, OS Version : Win11

Create template item + variant PropertyGroupOptions in browser not showing up

  • **I'm submitting a ... **

    • [X ] bug report
    • feature request
    • support request
  • Do you want to request a feature or report a bug?
    report a bug

  • What is the current behavior?
    [Could be also a shopware API / shopware core issue - when i do it by POSTMAN i get same result]
    Creating a template item with product.upsert_product_payload is working
    Creating a variant item with product.upsert_product_payload is working
    When you browse after creating the product you will not see the PropertyGroupOptions

grafik

When you navigate to the product in Backend Storefront display is loading unlimited

grafik

When you generate the variants via backend you can see after generate the PropertyGroupOptions

  • **If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem
    see above

  • What is the expected behavior?
    PropertyGroupOptions are visible

  • What is the motivation / use case for changing the behavior?

  • Please tell us about your environment:

  • Release Number of the Repository used : latest
  • Python Version : 3.10
  • OS, OS Version : 6.4.11.1
  • Other information (e.g. detailed explanation, stack traces, related issues, suggestions how to fix, links for us to have context, eg. stackoverflow
    , gitter, etc)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.