sbdl 1.18.18__tar.gz → 1.18.19__tar.gz

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.1
2
2
  Name: sbdl
3
- Version: 1.18.18
3
+ Version: 1.18.19
4
4
  Summary: System Behaviour Description Language (Compiler)
5
5
  Home-page: https://sbdl.dev
6
6
  Author: Michael A. Hicks
@@ -0,0 +1,4 @@
1
+ [build-system]
2
+ requires = ["setuptools>=42", "wheel"]
3
+ build-backend = "setuptools.build_meta"
4
+
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: sbdl
3
- Version: 1.18.18
3
+ Version: 1.18.19
4
4
  Summary: System Behaviour Description Language (Compiler)
5
5
  Home-page: https://sbdl.dev
6
6
  Author: Michael A. Hicks
@@ -1,10 +1,11 @@
1
1
  csv-to-sbdl.py
2
- sbdl
2
+ pyproject.toml
3
3
  sbdl.py
4
4
  sbdl_server.py
5
5
  setup.py
6
6
  sbdl.egg-info/PKG-INFO
7
7
  sbdl.egg-info/SOURCES.txt
8
8
  sbdl.egg-info/dependency_links.txt
9
+ sbdl.egg-info/entry_points.txt
9
10
  sbdl.egg-info/requires.txt
10
11
  sbdl.egg-info/top_level.txt
@@ -0,0 +1,2 @@
1
+ [console_scripts]
2
+ sbdl = sbdl:run_main
@@ -4,4 +4,3 @@ jinja2
4
4
  matplotlib
5
5
  networkx
6
6
  openpyxl
7
- pandas
@@ -221,8 +221,8 @@ _A=True
221
221
  import argparse,base64,datetime,csv,functools,getpass,hashlib,importlib,io,json,os,pathlib,pickle,platform,re,shlex,string,subprocess,sys,tarfile,tempfile,textwrap,time,traceback,types,unittest,urllib.request,urllib.parse,warnings,zlib,zipfile
222
222
  warnings.filterwarnings(_A1,category=DeprecationWarning)
223
223
  __NAME=_j
224
- __VERSION='1.18.18'
225
- __VERSION_DEV='2a6b4c8'
224
+ __VERSION='1.18.19'
225
+ __VERSION_DEV='ab2813a'
226
226
  __VERSION_DSL='25.6'
227
227
  __VERSION_REST_API='1.1.0'
228
228
  __AUTHOR='contact@sbdl.dev'
@@ -1879,14 +1879,14 @@ def msword_input_handler(file_reference):
1879
1879
  return result,handler
1880
1880
  def msexcel_input_handler(file_reference):
1881
1881
  result=_C;handler=_B;_,extension=os.path.splitext(file_reference)
1882
- if extension=='.xls'or extension=='.xlsx'or extension=='.ods':
1882
+ if extension=='.xls'or extension=='.xlsx':
1883
1883
  try:
1884
- import pandas;pdframe=pandas.read_excel(file_reference);content=[]
1885
- for col in pdframe:
1886
- content.append(str(col))
1887
- for cell in pdframe[col]:content.append(ms_character_fix(str(cell)))
1884
+ import openpyxl;wb=openpyxl.load_workbook(file_reference,data_only=_A);ws=wb.active;content=[]
1885
+ for col_cells in ws.iter_cols():
1886
+ header=col_cells[0].value;content.append(str(header))
1887
+ for cell in col_cells[1:]:content.append(ms_character_fix(str(cell.value)))
1888
1888
  handler=list_file_object(content);result=_A
1889
- except Exception as e:f_print('Trying to parse what looks like an MS Excel file but pandas package cannot be imported correctly:\n {}'.format(str(e)),do_warning=_A,warning=_A)
1889
+ except Exception as e:f_print('Trying to parse what looks like an MS Excel file but openpyxl package cannot be imported correctly:\n {}'.format(str(e)),do_warning=_A,warning=_A)
1890
1890
  return result,handler
1891
1891
  def make_remote_file_local(file_reference):
1892
1892
  local_file_reference=file_reference;parsed_file_reference=urllib.parse.urlparse(local_file_reference);error_string=_B
@@ -2311,7 +2311,7 @@ def write_process_graph_output(sbdl_ast,output_file,file_opener,_,print_l):
2311
2311
  if SBDL_Parser.Attributes.condition in event_elem.properties():condition=event_elem.get_property(SBDL_Parser.Attributes.condition)
2312
2312
  def emit_note():
2313
2313
  nonlocal event_cont,note_stagger
2314
- if show_descriptions and event_elem.description():event_cont+=f"{indent_str}note {_AA if note_stagger else _AB}\n{indent_str}{event_elem.description()}\n{indent_str}end note\n";note_stagger=not note_stagger
2314
+ if show_descriptions and event_elem.description():event_cont+=f"{indent_str}note "+(_AA if note_stagger else _AB)+'\n{indent_str}{event_elem.description()}\n{indent_str}end note\n';note_stagger=not note_stagger
2315
2315
  if ev_aspect!=current_aspect and get_config_value(_q,number=_A):
2316
2316
  event_cont+=f"{indent_str}"
2317
2317
  if ev_aspect in elements:
@@ -2321,12 +2321,12 @@ def write_process_graph_output(sbdl_ast,output_file,file_opener,_,print_l):
2321
2321
  if first_event:
2322
2322
  event_cont+=f"{indent_str}start\n";first_event=_C
2323
2323
  if get_config_value(_q,number=_A):event_cont+=f"{indent_str}{elem_colour_prefix(g_process_elem)}:{g_process_elem.identifier()}; <<procedure>>\n";emit_note()
2324
- if is_loop:event_cont+=f"{indent_str}repeat{_D if control_only else""}"
2325
- if not control_only:event_cont+=f"{indent_str}{elem_colour_prefix(event_elem)if not is_loop else""}:{event_elem.identifier()}; <<task>>\n";emit_note()
2324
+ if is_loop:suffix=_D if control_only else'';event_cont+=f"{indent_str}repeat{suffix}"
2325
+ if not control_only:prefix=elem_colour_prefix(event_elem)if not is_loop else'';event_cont+=f"{indent_str}{prefix}:{event_elem.identifier()}; <<task>>\n";emit_note()
2326
2326
  if ev_links and condition and not is_loop:event_cont+=f"{indent_str}if ({condition}) then (condition met)\n"
2327
2327
  child_count=0
2328
2328
  for event_id in ev_links:
2329
- if is_parallel:event_cont+=f"{indent_str}fork{" again"if child_count else""}\n"
2329
+ if is_parallel:suffix=' again'if child_count else'';event_cont+=f"{indent_str}fork{suffix}\n"
2330
2330
  event_cont+=recurse_event_contents(elements[event_id],ev_aspect,indent=indent+2);child_count+=1
2331
2331
  if is_parallel:event_cont+=f"{indent_str}endfork\n"
2332
2332
  if ev_links and SBDL_Parser.Attributes.condition_alternative in event_elem.properties():
@@ -2338,7 +2338,7 @@ def write_process_graph_output(sbdl_ast,output_file,file_opener,_,print_l):
2338
2338
  def handle_process_element(process_elem):
2339
2339
  nonlocal g_process_elem,first_event;first_event=_A;g_process_elem=process_elem;process_cont=''
2340
2340
  if not get_config_value(_q,number=_A):
2341
- process_cont+=f'group {elem_colour_prefix(process_elem)}"**{f"{process_elem.type()}::{process_elem.stereotype()}"if process_elem.stereotype()else process_elem.type()}** {process_elem.identifier()}" {{\n';description=process_elem.description()
2341
+ process_cont+=f'group {elem_colour_prefix(process_elem)}"**'+(f"{process_elem.type()}::{process_elem.stereotype()}"if process_elem.stereotype()else process_elem.type())+'** {process_elem.identifier()}" {{\n';description=process_elem.description()
2342
2342
  if show_descriptions and description:process_cont+=f"note\n{description}\nend note\n"
2343
2343
  process_links=SBDL_AST.get_all_links_for_element(process_elem,elements)
2344
2344
  for event_id in[x.identifier()for x in process_links if x.is_a(SBDL_Event)and x.identifier()in elements]:process_cont+=recurse_event_contents(elements[event_id])
@@ -2,14 +2,18 @@ from setuptools import setup
2
2
 
3
3
  setup(
4
4
  name='sbdl',
5
- version='1.18.18',
5
+ version='1.18.19',
6
6
  description = "System Behaviour Description Language (Compiler)",
7
7
  author = "Michael A. Hicks",
8
8
  author_email = "michael@mahicks.org",
9
9
  url = "https://sbdl.dev",
10
- scripts=['sbdl'],
11
10
  py_modules=['sbdl','csv-to-sbdl','sbdl_server'],
12
11
  license = "Proprietary",
13
12
  python_requires='>=3.6',
14
- install_requires=['networkx','matplotlib','docx2txt','pandas','openpyxl','docxtpl','jinja2']
13
+ install_requires=['networkx','matplotlib','docx2txt','openpyxl','docxtpl','jinja2'],
14
+ entry_points={
15
+ 'console_scripts': [
16
+ 'sbdl = sbdl:run_main',
17
+ ],
18
+ }
15
19
  )
sbdl-1.18.18/sbdl DELETED
@@ -1,5 +0,0 @@
1
- #!/usr/bin/python3
2
- import sys
3
- import subprocess
4
-
5
- subprocess.call([sys.executable, '-m', 'sbdl'] + sys.argv[1:])
File without changes
File without changes
File without changes