barredterra
d67066dfae
fix: switch to ruff
2024-02-18 16:42:41 +01:00
barredterra
7e5dd21cba
Merge remote-tracking branch 'upstream/develop' into copy-config-to-new-app
2024-02-18 16:30:00 +01:00
scdanieli
a1cb19c820
fix: ensure has_value_changed works for datetime, date and timedelta fields
2024-02-18 16:05:31 +01:00
Raffael Meyer
fc64e8a0fb
feat: pass doctype as context when translating label ( #24903 )
2024-02-18 19:42:15 +05:30
barredterra
1aae576b1a
Merge branch 'develop' into copy-config-to-new-app
2024-02-16 14:36:58 +01:00
barredterra
30d63b165b
refactor: split into multiple methods
2024-02-13 11:44:50 +01:00
barredterra
2a85c4c5d9
refactor: no inline if-statement
...
Co-authored-by: Akhil Narang <me@akhilnarang.dev>
2024-02-13 11:29:30 +01:00
barredterra
2e4dd1ba77
refactor: setup_backup_tables
2024-02-12 18:16:47 +01:00
Ankush Menat
4c925e0325
refactor: Reset password flow
...
- Hash one time reset tokens instead of storing them as is
- Up the perm level
- Use better source of randomness for generating token
- minor code cleanup here and there
2024-02-11 14:25:26 +05:30
Nihalroshan55
c21935ba9e
fix: added prefix none as default in export_fixtures ( #24816 )
...
* added prefix none as default in export_fixtures
* refactor: declare prefix default later later
---------
Co-authored-by: Ankush Menat <ankush@frappe.io>
2024-02-10 08:21:56 +00:00
Raffael Meyer
b3b02c809f
Merge pull request #24684 from barredterra/label-in-link-to-form
2024-02-09 21:03:07 +01:00
barredterra
51743e5952
feat: frapp.model.can_submit (JS)
2024-02-09 16:19:12 +01:00
Akhil Narang
26ae0f3460
fix: ruff fixes
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-02-07 17:04:31 +05:30
Ankush Menat
7753ed28fb
fix(DX): show user who modified in diff view ( #24790 )
2024-02-06 13:00:31 +00:00
barredterra
c282103867
fix: make get_url_to_form accept single doctype
2024-02-06 12:49:31 +01:00
Ankush Menat
2c19e846df
refactor: simplify code
...
Co-authored-by: Akhil Narang <me@akhilnarang.dev>
2024-02-06 13:02:45 +05:30
Ankush Menat
d616341ad4
fix: Auto delete very old document locks
...
locks older than 12 hours are most likely from dead processes. They can be (mostly) safely ignored.
2024-02-06 12:28:05 +05:30
Ankush Menat
de9ac89748
style: re-format with ruff
2024-02-05 18:53:33 +05:30
Ankush Menat
7487df22c9
refactor: use frappe.get_system_settings
...
because it's cached and doesn't hit frappe.db at all.
2024-02-02 18:43:43 +05:30
David Arnold
c09f48f5d7
feat: comply trackers with utm and add utm_content for a/b testing ( #24521 )
...
* feat: comply trackers with utm and add utm_content for a/b testing
* fix: make all other than source optional
this is plausible.io best practice
* fix: medium is not specified to be lowercase
* fix: ensure proper parameter quoting
2024-02-02 11:33:22 +05:30
barredterra
9e851aa0cc
fix: allow name to be missing
...
for single doctypes
2024-02-01 18:16:05 +01:00
barredterra
5b6f05442e
fix: translate label in link to form
...
When a single doctype is passed to `get_link_to_form`, use the translated doctype as the label.
2024-02-01 18:15:46 +01:00
Maharshi Patel
3fb418f28f
Merge pull request #23907 from marination/dynamic-header-footer-develop
...
feat: Letterhead Scripts & fix disappearing header in pdf
2024-02-01 17:43:12 +05:30
Akhil Narang
ea65d86d72
Merge pull request #24625 from blaggacao/fix/shell-escaping
...
fix: shell escaping on external commands
2024-02-01 12:45:21 +05:30
marination
4d2c4f020b
fix: Check if header/footer html exists before trying to extract
...
- issue: AttributeError: 'NoneType' object has no attribute 'extract', when no letterhead html was present
2024-01-31 12:54:20 +01:00
Ankush Menat
a25e68a763
fix: make rate_limiter respect multitenancy ( #24634 )
...
* fix: make rate_limiter respect multitenancy
* fix: lower rate limit window for password reset
* refactor: Use redis_wrapper
2024-01-31 09:16:27 +00:00
Ankush Menat
dedadbb0d9
perf: optional faster perm check for files
2024-01-31 10:49:18 +05:30
David Arnold
3abbde3284
fix: shell escaping on external commands
2024-01-30 18:23:05 +01:00
Ankush Menat
d838da51dd
fix: short circuit private files perm check
...
For guest users there's no point in checking permissions, they'll eventually fail... instead just fail immediately.
2024-01-30 20:31:28 +05:30
barredterra
ce50162213
Merge branch 'develop' into copy-config-to-new-app
2024-01-29 15:07:13 +01:00
marination
bcca1da8d8
fix: Extract header/footer html into content to simplify things
...
- Extract header/footer html into `content` first, then remove any instances from the main content since it is already rendered via the extracted header/footer html
2024-01-29 13:25:45 +01:00
Corentin Flr
dde34f9402
fix(money_in_words)!: Don't translate the result of num2words
...
It's unlikely that a translation for the results of num2words exists, because it should return a string that is already translated in the target language. If there are some numbers that have a specific translation, then it should already be handled in the num2words library. A domain-specific library is surely better at this hypothetical task than Frappe's generic translation system.
In French, 100 is called Cent. But in English, Cent is 1/100th of a dollar, which is called Centime in French.
Expected: num2words(200).title() == "Cent"
Actual: _(num2words(200).title()) == _("Cent") == "Centime"
2024-01-26 15:49:18 +01:00
barredterra
9d6cbd0c15
fix: typos
2024-01-24 02:41:03 +01:00
barredterra
61a72b1803
fix: improve translatability of money in words
2024-01-23 19:24:12 +01:00
marination
f77b99396e
fix: Custom Script runs twice
...
- `frappe.get_print` calls `get_response_content("printview")` which calls `www/printview` that adds header and footer scripts
- Now it gets added again via `pdf_header_footer.html` which causes the script to run twice
- Header and Footer html are also added twice but then removed and handled in pdf.py (because printview + wkhtml processing)
- Misc: Use walrus operator
- Remove passed `letterhead` to insert script via pdf.py, printview handles it
2024-01-22 22:42:13 +01:00
Akhil Narang
8d001e530c
Merge pull request #24448 from akhilnarang/fix-failed-decryption-file-name
...
fix(decrypt): wrap the yield and cleanup code in try-finally
2024-01-19 15:51:14 +05:30
mergify[bot]
483fcf89c3
Merge pull request #24428 from blaggacao/chore/cleanup-frappe-connect
...
chore: cleanup frappe connect (I/II)
2024-01-18 12:15:42 +00:00
Akhil Narang
39be50c773
fix(decrypt): wrap the yield and cleanup code in try-finally
...
Without this, the cleanup code won't run after if `sys.exit()` is called when we yield
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-18 17:37:23 +05:30
Ankush Menat
ee6743c26b
fix: avoid mutating list while iterating over it ( #24438 )
2024-01-18 05:44:30 +00:00
Ankush Menat
f36a753c5a
refactor: Start sentry before freezing gc and use in pool ( #24436 )
...
- Workerpool wasn't using sentry
- Sentry was started after freezing GC which causes sentry imports to
not be shared. Freeze GC after most memory intensive work is done.
2024-01-18 05:34:34 +00:00
David Arnold
d87092936f
chore: simplify frappe.connect & require explicit site initialization
2024-01-17 16:53:30 +01:00
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
Ankush Menat
307da3097f
Merge pull request #23329 from akhilnarang/allow-setting-db-username
...
refactor: allow setting a db user name different from the database name
2024-01-16 17:46:03 +05:30
Akhil Narang
92326d143d
fix(sentry): set scope for background jobs
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-16 16:26:48 +05:30
Akhil Narang
3ccdbfbde0
fix: drop a fallback
...
Had some issues earlier - seems to be resolved now
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-16 13:01:13 +05:30
Akhil Narang
c721fcf8c4
refactor: allow setting a db user name different from the database name
...
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-16 12:35:01 +05:30
Akhil Narang
235be44d7a
fix: add a check for gpg existing
...
Encrypted backup/restores just fail without a clear error message if gpg is missing
Signed-off-by: Akhil Narang <me@akhilnarang.dev>
2024-01-15 17:52:51 +05:30
barredterra
95d0fb57cd
feat: linter workflow for new apps
2024-01-14 17:36:47 +01:00
barredterra
52f6c24982
refactor: check latest github release
2024-01-14 16:46:07 +01:00
barredterra
8213ad25ed
Merge branch 'develop' into copy-config-to-new-app
2024-01-14 14:55:16 +01:00