Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
f229a38
ci: disable automatic semantic release on push
Emmafidelis Aug 4, 2026
771cb89
Merge pull request #391 from Emmafidelis/ci/changes
aakvatech Aug 21, 2026
9bb39b1
ci: disable automatic semantic release on push
Emmafidelis Aug 4, 2026
301069f
Merge pull request #409 from Aakvatech-Limited/backport-391-to-versio…
aakvatech Aug 21, 2026
d5dbddc
chore: enforce app-owned ruff, pre-commit and frappe semgrep hooks
av-dev2 Aug 21, 2026
23e61ad
ci: drop bench install job, tests run manually on the bench
av-dev2 Aug 21, 2026
269f02f
ci: run frappe semgrep as a full-repo scan instead of inside pre-commit
av-dev2 Aug 21, 2026
adf45f2
fix: drop unused PyPDF2 dependency flagged by pip-audit
av-dev2 Aug 21, 2026
87d4638
style: apply ruff format and fix all pre-commit findings
av-dev2 Aug 21, 2026
0d17d64
Merge branch 'chore/pre-commit-tooling' into chore_enforce_pre-commit…
av-dev2 Aug 21, 2026
966f128
Merge branch 'ci/semgrep-full-scan' into chore_enforce_pre-commit_lin…
av-dev2 Aug 21, 2026
2d57478
Merge branch 'ci/remove-bench-install-job' into chore_enforce_pre-com…
av-dev2 Aug 21, 2026
e2dad8d
Merge branch 'style/ruff-format' into chore_enforce_pre-commit_linter…
av-dev2 Aug 21, 2026
cd81833
fix(vehicle-sync): defer failed retries until pending queue is processed
MariamMabele Aug 6, 2026
fdcf892
fix(vehicle-fines): simplify daily sync queue and failed task handling
MariamMabele Aug 21, 2026
785e6ea
Merge pull request #416 from Aakvatech-Limited/backport-395-to-versio…
aakvatech Aug 21, 2026
0d6b748
fix: drop field creation now defined in CSF TZ Settings JSON
av-dev2 Aug 21, 2026
8481fcf
refactor: move NMB Callback doctype to edu_tz
av-dev2 Aug 21, 2026
ae36179
refactor: move NMB Callback controller to edu_tz
av-dev2 Aug 21, 2026
44d798b
refactor: move NMB Callback form script to edu_tz
av-dev2 Aug 21, 2026
7f6f973
test: move NMB Callback test stub to edu_tz
av-dev2 Aug 21, 2026
46f2436
refactor: remove NMB Callback package from csf_tz
av-dev2 Aug 21, 2026
69527d8
refactor: move Student Applicant Fees doctype to edu_tz
av-dev2 Aug 21, 2026
0fa8028
refactor: move Student Applicant Fees controller to edu_tz
av-dev2 Aug 21, 2026
8be027f
refactor: move Student Applicant Fees form script to edu_tz
av-dev2 Aug 21, 2026
5f492b6
test: move Student Applicant Fees test stub to edu_tz
av-dev2 Aug 21, 2026
8b084a2
refactor: remove Student Applicant Fees package from csf_tz
av-dev2 Aug 21, 2026
57d8d7e
refactor: move Program Enrollment hooks to edu_tz
av-dev2 Aug 21, 2026
c909895
refactor: move Student Applicant fee creation to edu_tz
av-dev2 Aug 21, 2026
1a7ec69
refactor: move Fees form script to edu_tz
av-dev2 Aug 21, 2026
a364a6a
refactor: move Program Enrollment form script to edu_tz
av-dev2 Aug 21, 2026
66077b9
refactor: move Program Enrollment Tool script to edu_tz
av-dev2 Aug 21, 2026
be1d23c
refactor: move Student Applicant form script to edu_tz
av-dev2 Aug 21, 2026
03fda0c
refactor: drop fee and enrollment helpers moved to edu_tz
av-dev2 Aug 21, 2026
8728eec
refactor: reduce bank_api to NMB callback shims forwarding to edu_tz
av-dev2 Aug 21, 2026
99d1ce7
refactor: drop education account filters from Company form
av-dev2 Aug 21, 2026
a6934c3
fix: skip Student ledger join when education is not installed
av-dev2 Aug 21, 2026
d276431
refactor: hand Company education section to edu_tz
av-dev2 Aug 21, 2026
b4cad57
chore: drop education fields from legacy fixture json
av-dev2 Aug 21, 2026
709190b
chore: drop education names from legacy fixture list
av-dev2 Aug 21, 2026
ca5bb7c
feat: drop moved education doctypes on sites without edu_tz
av-dev2 Aug 21, 2026
853236a
chore: register remove_education_doctypes patch
av-dev2 Aug 21, 2026
cb575d6
refactor: unregister education hooks and scripts moved to edu_tz
av-dev2 Aug 21, 2026
1bfe4a4
Merge branch 'version-16-hotfix' into feat/move_edu_features_to_edu_t…
av-dev2 Aug 21, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion .deepsource.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,3 @@ enabled = true

[analyzers.meta]
runtime_version = "3.x.x"

113 changes: 0 additions & 113 deletions .github/workflows/ci.yml

This file was deleted.

20 changes: 18 additions & 2 deletions .github/workflows/linter.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ jobs:
cache: pip
- name: Install pre-commit
run: pip install pre-commit
# Semgrep is skipped here and run as a full-repo scan in the next steps
- name: Run pre-commit on changed files
env:
SKIP: frappe-semgrep-rules
run: |
pre-commit run \
--show-diff-on-failure \
Expand All @@ -39,10 +42,23 @@ jobs:
- name: Download Semgrep rules
run: git clone --depth 1 https://github.com/frappe/semgrep-rules.git frappe-semgrep-rules

- name: Install Semgrep
run: pip install semgrep

# Blocking: real bugs / security issues only
- name: Run Semgrep rules
run: |
pip install semgrep
semgrep ci --config ./frappe-semgrep-rules/rules --config r/python.lang.correctness
semgrep scan --config ./frappe-semgrep-rules/rules \
--config r/python.lang.security \
--severity=ERROR --error csf_tz

# Informational: style and i18n warnings, never fails the build
- name: Semgrep warnings (non-blocking)
if: always()
run: |
semgrep scan --config ./frappe-semgrep-rules/rules \
--config r/python.lang.security \
--severity=WARNING csf_tz || true

deps-vulnerable-check:
name: 'Vulnerable Dependency Check'
Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
name: Release

on:
push:
branches: [version-15]
workflow_dispatch:

permissions:
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,6 @@ build/
coverage/
*.lcov
.nyc_output

# Semgrep rules cloned by pre-commit / CI
frappe-semgrep-rules/
20 changes: 17 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
exclude: 'node_modules|.git'
exclude: 'node_modules|.git|frappe-semgrep-rules'
default_stages: [pre-commit]
default_install_hook_types: [pre-commit, commit-msg]
fail_fast: false
Expand All @@ -11,6 +11,7 @@ repos:
files: "csf_tz.*"
exclude: ".*json$|.*txt$|.*csv|.*md|.*svg"
- id: end-of-file-fixer
exclude: ".*json$"
- id: check-merge-conflict
- id: check-ast
- id: check-json
Expand All @@ -19,18 +20,31 @@ repos:
- id: debug-statements

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.1
rev: v0.11.0
hooks:
- id: ruff
name: "Run ruff import sorter"
args: ["--select=I", "--fix"]

- id: ruff
name: "Run ruff linter"
args: ["--fix"]

- id: ruff-format
name: "Run ruff formatter"

- repo: local
hooks:
- id: frappe-semgrep-rules
name: "Frappe Semgrep Security Rules"
entry: bash -c 'if [ ! -d frappe-semgrep-rules/.git ]; then rm -rf frappe-semgrep-rules && GIT_TEMPLATE_DIR="" git clone --depth 1 https://github.com/frappe/semgrep-rules.git frappe-semgrep-rules; fi && semgrep scan --config ./frappe-semgrep-rules/rules --config r/python.lang.security --severity=ERROR --error --quiet "$@"' --
language: python
additional_dependencies: ["semgrep"]
types: [python]
files: "^csf_tz/.*\\.py$"
pass_filenames: true
require_serial: true

- repo: https://github.com/alessandrojcm/commitlint-pre-commit-hook
rev: v9.22.0
hooks:
Expand All @@ -40,5 +54,5 @@ repos:

ci:
autoupdate_schedule: weekly
skip: []
skip: [frappe-semgrep-rules]
submodules: false
13 changes: 13 additions & 0 deletions .semgrepignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Semgrep ignore file. Creating it replaces semgrep's built-in defaults, so they are re-listed.
.git/
node_modules/
__pycache__/
*.pyc
*.egg-info/
dist/
build/
frappe-semgrep-rules/

# Test files
**/test_*.py
**/tests/
1 change: 0 additions & 1 deletion commitlint.config.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
module.exports = {
parserPreset: "conventional-changelog-conventionalcommits",
rules: {
"subject-empty": [2, "never"],
"type-case": [2, "always", "lower-case"],
Expand Down
50 changes: 24 additions & 26 deletions csf_tz/__init__.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
# -*- coding: utf-8 -*-
from __future__ import unicode_literals
import os
import importlib
import os

import frappe

Expand All @@ -12,33 +10,33 @@


def load_monkey_patches():
"""
Loads all modules present in monkey_patches to override some logic
in Frappe / ERPNext. Returns if patches have already been loaded earlier.
"""
global patches_loaded
"""
Loads all modules present in monkey_patches to override some logic
in Frappe / ERPNext. Returns if patches have already been loaded earlier.
"""
global patches_loaded

if patches_loaded:
return
if patches_loaded:
return

patches_loaded = True
patches_loaded = True

if app_name not in frappe.get_installed_apps():
return
if app_name not in frappe.get_installed_apps():
return

for module_name in os.listdir(frappe.get_app_path(app_name, "monkey_patches")):
if not module_name.endswith(".py") or module_name == "__init__.py":
continue
for module_name in os.listdir(frappe.get_app_path(app_name, "monkey_patches")):
if not module_name.endswith(".py") or module_name == "__init__.py":
continue

importlib.import_module(app_name + ".monkey_patches." + module_name[:-3])
importlib.import_module(app_name + ".monkey_patches." + module_name[:-3])


old_get_hooks = frappe.get_hooks


def get_hooks(*args, **kwargs):
load_monkey_patches()
return old_get_hooks(*args, **kwargs)
load_monkey_patches()
return old_get_hooks(*args, **kwargs)


frappe.get_hooks = get_hooks
Expand All @@ -47,17 +45,17 @@ def get_hooks(*args, **kwargs):


def connect(*args, **kwargs):
"""
Patches frappe.connect to load monkey patches once a connection is
established with the database.
"""
"""
Patches frappe.connect to load monkey patches once a connection is
established with the database.
"""

old_connect(*args, **kwargs)
load_monkey_patches()
old_connect(*args, **kwargs)
load_monkey_patches()


frappe.connect = connect


def console(*data):
frappe.publish_realtime("out_to_console", data, user=frappe.session.user)
frappe.publish_realtime("out_to_console", data, user=frappe.session.user)
Loading
Loading