mirror of
https://github.com/inventree/InvenTree.git
synced 2025-07-03 04:00:57 +00:00
[Pricing] Add option to convert received items currency (#8970)
* Add new global setting * Convert to base currency on receipt * Fix total price rendering in PO table * Fix for tasks.py * Update .gitignore - Ignore auto-generated files * Update docs Improved documentation for pricing/currency support * Updates * Fix caching for default currency - Now managed better by session caching * Add unit test for new feature * Playwright test fixes * Validate copying of media files * Validate media files * Adjust playwright setup * Allow multiple attempts to fetch release information * Tweak unit tests * Revert changes to .gitignore file - Just trying stuff at this point * Add debug msg * Try hard-coded paths * Remove debug prints * Abs path for database * More debug * Fix typos * Revert change to db name * Remove debug statements (again) * Cleanup playwright tests * More test tweaks --------- Co-authored-by: Matthias Mair <code@mjmair.com>
This commit is contained in:
@ -113,8 +113,18 @@ def get_release_data():
|
||||
while 1:
|
||||
url = f'https://api.github.com/repos/inventree/inventree/releases?page={page}&per_page=150'
|
||||
|
||||
response = requests.get(url, timeout=30)
|
||||
assert response.status_code == 200
|
||||
attempts = 5
|
||||
|
||||
while attempts > 0:
|
||||
attempts -= 1
|
||||
|
||||
response = requests.get(url, timeout=30)
|
||||
if response.status_code == 200:
|
||||
break
|
||||
|
||||
assert response.status_code == 200, (
|
||||
f'Failed to fetch release data: {response.status_code} - {url}'
|
||||
)
|
||||
|
||||
data = json.loads(response.text)
|
||||
|
||||
|
Reference in New Issue
Block a user