Watchdog isn't used by Frappe, and there wasn't any mechanism to access
it directly either. By default, bench serve (or start) uses
Werkzeug's watchdogreloader
While executing git commands in the shell via Frappe processes, use
context managers to ensure files get closed after usage. This fixes the
ResourceWarning errors due to unclosed files.
* Remove six for PY2 compatability since our dependencies are not, PY2
is legacy.
* Removed usages of utils from future/past libraries since they are
deprecated. This includes 'from __future__ ...' and 'from past...'
statements.
* Removed compatibility imports for PY2, switched from six imports to
standard library imports.
* Removed utils code blocks that handle operations depending on PY2/3
versions.
* Removed 'from __future__ ...' lines from templates/code generators
* Used PY3 syntaxes in place of PY2 compatible blocks. eg: metaclass
cmp was being used from past.builtins library since it was deprecated in
PY2. It's hard to understand behaviour of their usages, so this is an
attempt to replicate behaviour with simpler logic, making this more
readable.
Also, removed usages of iteritems and string_types, compatibility
imports
* Removed /Form from the function get_url
As per issue #12820, I think /Form was causing a problem so I removed it. Now the get_url returns URL in the format: "app/doctype/name".
* fix: Change to f-strings
* Implement slug on get_url
* Removed slug for names
Given the scope of its usage at this point, this becomes a problem when you'd have a field named y,n, true, false and order_by that field, or have the same values for a document name that parent parameter would accept out of all those that Frappe REST allows.
* feat: add number format parameter in fmt_money
* review fix: move new parameter at the end
Co-authored-by: Kenneth Sequeira <kenneth@Kenneths-MacBook-Air.local>
The sendmail functionality got broken in recent refactoring to the email
module. The call to sendmail was passing from_addr and to_addrs in the
wrong order. This has been fixed.
Issue #13292
After creation of a new document and going back would break routes for doctypes that start with 'App'. In observed instance, it would clips the “app” portion in the appraisal and appraisal-template.
Python 3 interprets string literals as Unicode strings, and therefore \s and \g are treated as escaped Unicode characters.
Fix: Declare RegEx pattern as a raw string instead by prepending r