dmart 1.4.25__py3-none-any.whl → 1.4.26__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: dmart
3
- Version: 1.4.25
3
+ Version: 1.4.26
4
4
  Requires-Python: >=3.11
5
5
  Requires-Dist: fastapi
6
6
  Requires-Dist: pydantic
@@ -1,6 +1,6 @@
1
1
  bundler.py,sha256=MDTUTVS0WL7gb-i1rDcS4i37KTqaW88TluL4L3rwjRw,1817
2
2
  data_generator.py,sha256=CnE-VHEeX7-lAXtqCgbRqR9WHjTuOgeiZcviYrHAmho,2287
3
- dmart.py,sha256=EKr0YX1j4yoDrvc1LLHiXqBTKUtJAGvnDkIy3O9JdlA,25719
3
+ dmart.py,sha256=s56hBfeEOKqdtUosLGi9MY76bRfRLHDvWKXT2i_Y8qw,23689
4
4
  get_settings.py,sha256=Sbe2WCoiK398E7HY4SNLfDN_GmE8knR4M-YJWF31jcg,153
5
5
  main.py,sha256=KZGhIL6AnEm5ZAPy4IvhBDpzSTjuodilV7NafNOyhzM,19676
6
6
  migrate.py,sha256=hn1MZoVby_Jjqhc7y3CrLcGD619QmVZv3PONNvO7VKQ,665
@@ -271,8 +271,8 @@ utils/ticket_sys_utils.py,sha256=9QAlW2iiy8KyxQRBDj_WmzS5kKb0aYJmGwd4qzmGVqo,700
271
271
  utils/web_notifier.py,sha256=QM87VVid2grC5lK3NdS1yzz0z1wXljr4GChJOeK86W4,843
272
272
  utils/templates/activation.html.j2,sha256=XAMKCdoqONoc4ZQucD0yV-Pg5DlHHASZrTVItNS-iBE,640
273
273
  utils/templates/reminder.html.j2,sha256=aoS8bTs56q4hjAZKsb0jV9c-PIURBELuBOpT_qPZNVU,639
274
- dmart-1.4.25.dist-info/METADATA,sha256=1UTQWFfPUraoJmDrQI5DrLWcwSCPPHQHJaZ4LHa80-c,2149
275
- dmart-1.4.25.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
276
- dmart-1.4.25.dist-info/entry_points.txt,sha256=GjfoGh1bpxuU9HHGJzbtCFPNptHv9TryxHMN3uBSKpg,37
277
- dmart-1.4.25.dist-info/top_level.txt,sha256=S-gfX1pLerapNXiHZ8lvPYoV7sgwSX2_NCZ6xfzDUHM,267
278
- dmart-1.4.25.dist-info/RECORD,,
274
+ dmart-1.4.26.dist-info/METADATA,sha256=qhwJ1zV-khUXfFD7kr6-z-m-iqg_yR2YnJPqH0Rh0gE,2149
275
+ dmart-1.4.26.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
276
+ dmart-1.4.26.dist-info/entry_points.txt,sha256=GjfoGh1bpxuU9HHGJzbtCFPNptHv9TryxHMN3uBSKpg,37
277
+ dmart-1.4.26.dist-info/top_level.txt,sha256=S-gfX1pLerapNXiHZ8lvPYoV7sgwSX2_NCZ6xfzDUHM,267
278
+ dmart-1.4.26.dist-info/RECORD,,
dmart.py CHANGED
@@ -20,28 +20,6 @@ from pathlib import Path
20
20
  from hypercorn.config import Config
21
21
  from hypercorn.run import run
22
22
 
23
- # Try to import alembic
24
- try:
25
- import alembic
26
- # Check if we are importing the local alembic directory which is likely a leftover
27
- if hasattr(alembic, '__path__'):
28
- local_alembic_path = os.path.abspath(os.path.join(os.path.dirname(os.path.abspath(__file__)), 'alembic'))
29
- for p in alembic.__path__:
30
- if os.path.abspath(p) == local_alembic_path:
31
- # Check if it is a namespace package (no __init__.py)
32
- if not os.path.exists(os.path.join(p, '__init__.py')):
33
- # It is a leftover directory
34
- try:
35
- shutil.rmtree(p)
36
- # Force reload
37
- if 'alembic' in sys.modules:
38
- del sys.modules['alembic']
39
- import alembic
40
- except Exception:
41
- pass
42
- except ImportError:
43
- pass
44
-
45
23
  try:
46
24
  from alembic import command as alembic_command
47
25
  from alembic.config import Config as AlembicConfig
@@ -590,29 +568,9 @@ def main():
590
568
  try:
591
569
  # Check if alembic library is installed
592
570
  if not HAS_ALEMBIC:
593
- print("Warning: 'alembic' library not found. Attempting to run 'alembic' CLI...")
594
-
595
- with tempfile.NamedTemporaryFile(mode='w', suffix='.ini', delete=False) as tmp:
596
- temp_ini_path = tmp.name
597
- config = configparser.ConfigParser()
598
- config.read(str(ini_path))
599
- if not config.has_section('alembic'):
600
- config.add_section('alembic')
601
- config.set('alembic', 'script_location', alembic_dir.as_posix())
602
- config.write(tmp)
603
-
604
- try:
605
- subprocess.run([sys.executable, "-m", "alembic", "-c", temp_ini_path, "upgrade", "head"], check=True)
606
- except Exception as e:
607
- print(f"Error running alembic CLI: {e}")
608
- print("Please install 'alembic' library with 'pip install alembic'.")
609
- if ALEMBIC_ERROR:
610
- print(f"Details: {ALEMBIC_ERROR}")
611
- sys.exit(1)
612
- finally:
613
- if os.path.exists(temp_ini_path):
614
- os.unlink(temp_ini_path)
615
- return
571
+ print(f"Error: 'alembic' library not found. {ALEMBIC_ERROR}")
572
+ print("Please install 'alembic' library with 'pip install alembic'.")
573
+ sys.exit(1)
616
574
 
617
575
  alembic_cfg = AlembicConfig(str(ini_path))
618
576
  alembic_cfg.set_main_option("script_location", alembic_dir.as_posix())
File without changes