Akhil Narang
6ca4d4d167
refactor(treewide): ruff format
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2025-09-26 13:16:43 +05:30
Hussain Nagaria
6644159440
fix: gracefully handle missing from header in email ( #33996 )
2025-09-16 05:36:26 +00:00
barredterra
b1c7821911
feat: validate IBAN in backend
2025-08-29 15:21:56 +02:00
Vehbi Unal
c6a2e6595a
fix(utils): convert phone numbers passed into validate_phone_number to strings
2025-07-24 13:02:55 +00:00
Ankush Menat
afb720e003
refactor: move stuff away from init.py ( #33283 )
...
* chore: Drop unused imports
* refactor: split translation utils from init.py
* refactor: move sendmail from init.py
* refactor: move prints to attach_print
2025-07-11 07:18:16 +00:00
Sagar Vora
2e5c8bea03
feat: frappe.utils.orjson_dumps
2025-06-26 17:37:51 +05:30
Sagar Vora
cda7699187
perf: use orjson in utils
2025-06-26 17:37:51 +05:30
Sagar Vora
b3e1eda4c8
feat: global frappe.in_test flag ( #32960 )
...
* feat: global `frappe.in_test` flag
* feat: helper utility to toggle `frappe.in_test`
* fix: use `toggle_test_mode` util
* fix: use `frappe.in_test`
* chore: add comment explaining global `in_test`
* chore: ignore commit replacing flag usage
* test: temporarily disable `frappe.in_test`
this worked earlier because flag was set in werkzeug.local which was separate for API test client
* test: add comment explaining change
2025-06-17 19:19:31 +05:30
Ankush Menat
a278ff2356
chore: remove invalid return type
2025-06-05 21:38:14 +05:30
Ankush Menat
051aba3049
fix(DX): Fix type annotations for custom cached_property ( #32785 )
...
+ Avoid custom implementation on newer python versions entirely.
2025-06-04 16:37:35 +00:00
rohitwaghchaure
5c6b2b5bec
refactor: track completed app setup wizards and re-run the setup wizard upon new app installation. ( #32640 )
2025-06-03 12:36:22 +05:30
Ankush Menat
85f8ccadf7
Revert "feat: support reraising with error cause" ( #32523 )
...
This reverts commit 153d7cb7a3 .
2025-05-15 17:35:18 +05:30
Sagar Vora
ac39749929
Merge pull request #32082 from sagarvora/cached-prop
...
feat: use `cached_property` without locks on all supported Python versions
2025-04-11 13:49:49 +05:30
Sagar Vora
7421ffa79a
feat: use cached_property without locks on all supported Python versions
2025-04-11 13:21:27 +05:30
Henning Wendtland
b59a94a523
fix: improve url validation ( #32052 )
2025-04-11 11:51:08 +05:30
Sagar Vora
bd844579d2
refactor: trim frappe.__init__
2025-04-06 10:30:23 +05:30
Ankush Menat
ae4e2ede1a
refactor: move init.py utils to utils/*
2025-03-10 21:01:14 +05:30
Ankush Menat
cde1662791
perf: use client side cache for assets.json
...
Single shared key, worth the costs.
2025-01-14 13:57:41 +05:30
David Arnold
2f559e0fa9
chore: make the type clear ( #28524 )
2024-11-19 22:40:26 +00:00
David Arnold
8d6f8bce01
chore(typing): add some more typing to frappe.__init__ ( #28215 )
2024-10-21 11:30:11 +00:00
David Arnold
8cfeb156df
devx: add deprecation dumpster ( #27887 )
...
* feat: Add deprecation_dumpster.py file
* docs: add jovial and jocose docstring for frappe/deprecation_dumpster.py
* refactor: fill the dumpster with its own kind
* refactor: move to the deprecation dumpster
* chore: color coding class
* fix: only check import error when import errors
2024-10-08 18:56:10 +02:00
David
0aa652a565
fix: back compat
2024-06-24 10:16:51 +02:00
David
153d7cb7a3
feat: support reraising with error cause
2024-06-01 14:57:07 +02:00
Akhil Narang
45ffcf606e
Merge pull request #26462 from akhilnarang/tar-ignore-file-changed-as-we-read-it
...
feat: ignore `tar: file changed as we read it` during backups
2024-05-21 11:46:05 +05:30
Ankush Menat
025727674f
fix: scheduled type syncing ( #26490 )
...
- Scheduled Job sync when type was changed from scheduled to some other
type didn't work.
- It updates on every save with message, bad DX IMO (can't save script
and edit without dismissing)
- This was because of complex walrus which was triggering rest of code
even when nothing changed. Maybe walrus opponents were onto something.
- `Truthy` couples two different operations and hence makes code
complicated. In most cases where these checks are required it's not
performance critical, we can do 1 more function call to avoid this
coupling of change + actual value.
2024-05-20 13:43:20 +00:00
Akhil Narang
e3e6834b5d
fix: add errors=replace to decode() call
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-05-17 15:03:32 +05:30
Akhil Narang
803b45b9fa
feat: ignore tar: file changed as we read it during backups
...
This seems to occur when new files are being created as we're archiving
the files on a site. Doesn't make sense to fail the entire backup
because of that.
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-05-17 11:39:41 +05:30
gavin
665a18b063
fix: Implement Truthy.__eq __
...
Implement equality check, compare with True rather than self for a Truthy instance
Co-authored-by: Ankush Menat <ankushmenat@gmail.com>
2024-05-13 14:17:40 +02:00
Gavin D'souza
36c80b77a4
fix: Set value default True for Truthy cls
2024-05-07 17:43:19 +02:00
Gavin D'souza
ffbf7fb9d1
fix!: Document.has_value_changed returns Truthy or False
...
- Return changed value to avoid re-accessing previous object & it's
attribute
- Wrap returned value as Truthy to avoid breaking change in API
2024-05-07 17:29:48 +02:00
Ankush Menat
d40b2a2517
fix(UX): help links and relative URLs
...
also closes https://github.com/frappe/frappe/issues/23020
2024-04-22 12:10:28 +05:30
Akhil Narang
1847e9cae8
fix: pass function as lambda
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-03-29 12:00:25 +05:30
Suraj Shetty
ec4261bd77
fix: Do not check for email validation on empty string
2024-03-02 21:20:51 +05:30
Akhil Narang
3f1e19de85
refactor(treewide): enable RUF rules
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-02-21 16:20:28 +05:30
Akhil Narang
26ae0f3460
fix: ruff fixes
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-02-07 17:04:31 +05:30
Ankush Menat
de9ac89748
style: re-format with ruff
2024-02-05 18:53:33 +05:30
Ankush Menat
afef4b8f30
fix: add short timeout to gravatar ( #24414 )
...
closes https://github.com/frappe/frappe/issues/24377
2024-01-17 09:08:00 +00:00
Akhil Narang
9586b5f18a
fix(execute_in_shell): run explicitly in bash
...
`pipefail` isn't supported in sh, bash is common enough to be installed nearly everywhere
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-04 19:07:28 +05:30
Hussain Nagaria
4d20ef9200
docs: get_gravatar and get_gravatar_url
2023-12-19 12:08:50 +05:30
Hussain Nagaria
8d2137c265
docs: consistent doc strings
2023-12-18 18:27:39 +05:30
Ankush Menat
1e20820846
refactor: Indicate that weak hash functions are not usedforsecurity ( #23540 )
...
[skip ci]
2023-12-01 16:04:37 +05:30
David Arnold
9228cd70f8
fix: code style
2023-11-17 09:30:53 +01:00
David Arnold
5b33608fe3
fix: shell escaping in execute_in_shell helper
2023-11-16 10:52:11 +01:00
Ankush Menat
c69b043527
fix: send correct username in userinfo ( #23177 )
2023-11-11 08:08:39 +00:00
Akhil Narang
1119919971
refactor: use gzip library's compress() and decompress() methods directly
...
The util methods were added for python2.7 compat, mark them as deprecated
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2023-10-20 21:17:35 +05:30
Sambasiva Suda
7165f94148
fix: validate_email_addr should return email id as it is if it is valid ( #22613 )
2023-10-11 12:37:48 +05:30
Ankush Menat
e9a6c4ab13
fix: user info error when name case mismatches
2023-09-23 15:26:31 +05:30
Ankush Menat
d20e436e0f
perf: fetch user info in one query
2023-09-18 11:16:20 +05:30
Ankush Menat
970a740164
revert: #22308 ( #22389 )
...
* Revert "chore: move function to correct file"
This reverts commit ebfdfa283b .
* Revert "refactor!: merge get_site_url into get_url (#22308 )"
This reverts commit 2001bc278f .
2023-09-13 14:34:52 +05:30
Ankush Menat
ebfdfa283b
chore: move function to correct file
2023-09-11 19:02:34 +05:30