cjnfuncs 3.1__tar.gz → 3.2__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.
Files changed (30) hide show
  1. {cjnfuncs-3.1 → cjnfuncs-3.2}/LICENSE +1 -1
  2. {cjnfuncs-3.1/src/cjnfuncs.egg-info → cjnfuncs-3.2}/PKG-INFO +28 -12
  3. {cjnfuncs-3.1 → cjnfuncs-3.2}/README.md +27 -11
  4. {cjnfuncs-3.1 → cjnfuncs-3.2}/pyproject.toml +17 -7
  5. cjnfuncs-3.2/src/cjnfuncs/__init__.py +3 -0
  6. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/configman.py +468 -76
  7. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/resourcelock.py +79 -45
  8. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/timevalue.py +46 -5
  9. {cjnfuncs-3.1 → cjnfuncs-3.2/src/cjnfuncs.egg-info}/PKG-INFO +28 -12
  10. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs.egg-info/SOURCES.txt +0 -9
  11. cjnfuncs-3.1/MANIFEST.in +0 -2
  12. cjnfuncs-3.1/SMTP.md +0 -417
  13. cjnfuncs-3.1/configman.md +0 -1009
  14. cjnfuncs-3.1/core.md +0 -591
  15. cjnfuncs-3.1/deployfiles.md +0 -218
  16. cjnfuncs-3.1/mungePath.md +0 -294
  17. cjnfuncs-3.1/resourcelock.md +0 -495
  18. cjnfuncs-3.1/rwt.md +0 -290
  19. cjnfuncs-3.1/src/cjnfuncs/__init__.py +0 -0
  20. cjnfuncs-3.1/timevalue.md +0 -283
  21. {cjnfuncs-3.1 → cjnfuncs-3.2}/setup.cfg +0 -0
  22. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/SMTP.py +0 -0
  23. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/core.py +0 -0
  24. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/deployfiles.py +0 -0
  25. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/mungePath.py +0 -0
  26. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs/rwt.py +0 -0
  27. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs.egg-info/dependency_links.txt +0 -0
  28. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs.egg-info/entry_points.txt +0 -0
  29. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs.egg-info/requires.txt +0 -0
  30. {cjnfuncs-3.1 → cjnfuncs-3.2}/src/cjnfuncs.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  MIT License
2
2
 
3
- Copyright (c) 2019-2025 Chris Nelson
3
+ Copyright (c) 2019-2026 Chris Nelson
4
4
 
5
5
  Permission is hereby granted, free of charge, to any person obtaining a copy
6
6
  of this software and associated documentation files (the "Software"), to deal
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: cjnfuncs
3
- Version: 3.1
3
+ Version: 3.2
4
4
  Summary: A collection of core functions for tool script writing
5
5
  Author-email: Chris Nelson <github@cjnaz.com>
6
6
  License-Expression: MIT
@@ -22,18 +22,18 @@ Dynamic: license-file
22
22
 
23
23
  ## cjnfuncs is comprised of several modules (follow links to respective documentation)
24
24
 
25
- NOTE: Since relative links to other .md files do not work on PyPI, please go to the [cjnfuncs GitHub repo](https://github.com/cjnaz/cjnfuncs) to read the documentation.
25
+ NOTE: These link point to the github repo since relative links to other .md files do not work on PyPI.
26
26
 
27
27
  module | Description/Purpose
28
28
  --|--
29
- [core](core.md) | Set up the base environment
30
- [configman](configman.md) | Feature-rich configuration file toolset
31
- [timevalue](timevalue.md) | Handle time values with units, such as '5m' (5 minutes), and schedule future operations
32
- [mungePath](mungePath.md) | Ease-of-use pathlib extension for constructing and manipulating file paths
33
- [rwt / run_with_timeout](rwt.md) | Execute any function with an enforced timeout
34
- [deployfiles](deployfiles.md) | Push bundled setup files within a package to the proper user/system locations
35
- [resourcelock](resourcelock.md) | Inter-process resource lock mechanism
36
- [SMTP](SMTP.md) | Send notification and email messages
29
+ [core](https://github.com/cjnaz/cjnfuncs/blob/main/core.md) | Set up the base environment
30
+ [configman](https://github.com/cjnaz/cjnfuncs/blob/main/configman.md) | Feature-rich configuration file toolset
31
+ [timevalue](https://github.com/cjnaz/cjnfuncs/blob/main/timevalue.md) | Handle time values with units, such as '5m' (5 minutes), and schedule future operations
32
+ [mungePath](https://github.com/cjnaz/cjnfuncs/blob/main/mungePath.md) | Ease-of-use pathlib extension for constructing and manipulating file paths
33
+ [rwt / run_with_timeout](https://github.com/cjnaz/cjnfuncs/blob/main/rwt.md) | Execute any function with an enforced timeout
34
+ [deployfiles](https://github.com/cjnaz/cjnfuncs/blob/main/deployfiles.md) | Push bundled setup files within a package to the proper user/system locations
35
+ [resourcelock](https://github.com/cjnaz/cjnfuncs/blob/main/resourcelock.md) | Inter-process resource lock mechanism
36
+ [SMTP](https://github.com/cjnaz/cjnfuncs/blob/main/SMTP.md) | Send notification and email messages
37
37
 
38
38
  Developed and tested on Python 3.9.21 and supported on all higher Python versions.
39
39
  Developed on Linux. Supported on Windows, except for the resourcelock module (posix-ipc module dependency).
@@ -60,21 +60,37 @@ Project repo: https://github.com/cjnaz/cjnfuncs
60
60
 
61
61
  ## Key changes since the prior major public release (version 3.0)
62
62
 
63
+ 3.2 changes
64
+ - `persistent_config` - Layered on top of config_item, this new class provides a clean and simple tool for carrying runtime data across tool
65
+ script restarts and system reboots.
66
+
67
+ - Shared memory block handling - Extending resourcelock's features, read/write access is provided to the shared memory block associated with
68
+ a user-defined lock.
69
+
70
+
71
+ 3.1 changes
63
72
  - Several issues with Windows support were fixed.
64
73
 
65
74
  - `configman.config_item()` now supports a safe_mode switch, which will speed up Windows usage of loadconfig() at some risk. See the note on `config_item()`.
66
75
 
67
- - Named child loggers are now implemented on several cjnfuncs modules. By default, logging from cjnfuncs modules is disabled (logging events are usually at the INFO or DEBUG
76
+ - Named child loggers are now implemented on several cjnfuncs modules. By default, logging from cjnfuncs modules is disabled (internal logging events are usually at the INFO or DEBUG
68
77
  level, while the default logging level is set to WARNING). For example, logging from configman may be enabled by `logging.getLogger('cjnfuncs.configman').setLevel(logging.INFO)`,
69
- or using `core.set_logging.level(logging.INFO, 'cjnfuncs.configman')`.
78
+ or using `core.set_logging_level(logging.INFO, 'cjnfuncs.configman')`.
70
79
 
71
80
  - Changed mungePath set_attributes from default True to default False to avoid long processing time on Windows by default.
72
81
 
73
82
  - deployfiles can now create an empty target directory.
74
83
 
84
+ 3.1.1 changes
85
+ - get_next_dt now supports a days or weeks offset for the days arg
86
+ - Added separate child logger `cjnfuncs.resourcelock_islocked` so that `is_locked()` may be called in a loop without flooding the log while `cjnfuncs.resourcelock` is set to debug
87
+
75
88
  <br/>
76
89
 
77
90
  ## Revision history
91
+
92
+ - 3.2 - 260506 - New features: persistent_config and shared memory block handling
93
+ - 3.1.1 260207 - separate resourcelock_islocked logger, get_next_dt days/weeks offset
78
94
  - 3.1 251109
79
95
  Support for and use of child loggers,
80
96
  deployfiles create empty dir,
@@ -2,18 +2,18 @@
2
2
 
3
3
  ## cjnfuncs is comprised of several modules (follow links to respective documentation)
4
4
 
5
- NOTE: Since relative links to other .md files do not work on PyPI, please go to the [cjnfuncs GitHub repo](https://github.com/cjnaz/cjnfuncs) to read the documentation.
5
+ NOTE: These link point to the github repo since relative links to other .md files do not work on PyPI.
6
6
 
7
7
  module | Description/Purpose
8
8
  --|--
9
- [core](core.md) | Set up the base environment
10
- [configman](configman.md) | Feature-rich configuration file toolset
11
- [timevalue](timevalue.md) | Handle time values with units, such as '5m' (5 minutes), and schedule future operations
12
- [mungePath](mungePath.md) | Ease-of-use pathlib extension for constructing and manipulating file paths
13
- [rwt / run_with_timeout](rwt.md) | Execute any function with an enforced timeout
14
- [deployfiles](deployfiles.md) | Push bundled setup files within a package to the proper user/system locations
15
- [resourcelock](resourcelock.md) | Inter-process resource lock mechanism
16
- [SMTP](SMTP.md) | Send notification and email messages
9
+ [core](https://github.com/cjnaz/cjnfuncs/blob/main/core.md) | Set up the base environment
10
+ [configman](https://github.com/cjnaz/cjnfuncs/blob/main/configman.md) | Feature-rich configuration file toolset
11
+ [timevalue](https://github.com/cjnaz/cjnfuncs/blob/main/timevalue.md) | Handle time values with units, such as '5m' (5 minutes), and schedule future operations
12
+ [mungePath](https://github.com/cjnaz/cjnfuncs/blob/main/mungePath.md) | Ease-of-use pathlib extension for constructing and manipulating file paths
13
+ [rwt / run_with_timeout](https://github.com/cjnaz/cjnfuncs/blob/main/rwt.md) | Execute any function with an enforced timeout
14
+ [deployfiles](https://github.com/cjnaz/cjnfuncs/blob/main/deployfiles.md) | Push bundled setup files within a package to the proper user/system locations
15
+ [resourcelock](https://github.com/cjnaz/cjnfuncs/blob/main/resourcelock.md) | Inter-process resource lock mechanism
16
+ [SMTP](https://github.com/cjnaz/cjnfuncs/blob/main/SMTP.md) | Send notification and email messages
17
17
 
18
18
  Developed and tested on Python 3.9.21 and supported on all higher Python versions.
19
19
  Developed on Linux. Supported on Windows, except for the resourcelock module (posix-ipc module dependency).
@@ -40,21 +40,37 @@ Project repo: https://github.com/cjnaz/cjnfuncs
40
40
 
41
41
  ## Key changes since the prior major public release (version 3.0)
42
42
 
43
+ 3.2 changes
44
+ - `persistent_config` - Layered on top of config_item, this new class provides a clean and simple tool for carrying runtime data across tool
45
+ script restarts and system reboots.
46
+
47
+ - Shared memory block handling - Extending resourcelock's features, read/write access is provided to the shared memory block associated with
48
+ a user-defined lock.
49
+
50
+
51
+ 3.1 changes
43
52
  - Several issues with Windows support were fixed.
44
53
 
45
54
  - `configman.config_item()` now supports a safe_mode switch, which will speed up Windows usage of loadconfig() at some risk. See the note on `config_item()`.
46
55
 
47
- - Named child loggers are now implemented on several cjnfuncs modules. By default, logging from cjnfuncs modules is disabled (logging events are usually at the INFO or DEBUG
56
+ - Named child loggers are now implemented on several cjnfuncs modules. By default, logging from cjnfuncs modules is disabled (internal logging events are usually at the INFO or DEBUG
48
57
  level, while the default logging level is set to WARNING). For example, logging from configman may be enabled by `logging.getLogger('cjnfuncs.configman').setLevel(logging.INFO)`,
49
- or using `core.set_logging.level(logging.INFO, 'cjnfuncs.configman')`.
58
+ or using `core.set_logging_level(logging.INFO, 'cjnfuncs.configman')`.
50
59
 
51
60
  - Changed mungePath set_attributes from default True to default False to avoid long processing time on Windows by default.
52
61
 
53
62
  - deployfiles can now create an empty target directory.
54
63
 
64
+ 3.1.1 changes
65
+ - get_next_dt now supports a days or weeks offset for the days arg
66
+ - Added separate child logger `cjnfuncs.resourcelock_islocked` so that `is_locked()` may be called in a loop without flooding the log while `cjnfuncs.resourcelock` is set to debug
67
+
55
68
  <br/>
56
69
 
57
70
  ## Revision history
71
+
72
+ - 3.2 - 260506 - New features: persistent_config and shared memory block handling
73
+ - 3.1.1 260207 - separate resourcelock_islocked logger, get_next_dt days/weeks offset
58
74
  - 3.1 251109
59
75
  Support for and use of child loggers,
60
76
  deployfiles create empty dir,
@@ -1,6 +1,8 @@
1
1
  [project]
2
2
  name = 'cjnfuncs'
3
- version = '3.1'
3
+ version = '3.2'
4
+ # 3.2 - Release - New features: persistent_config and shared memory block handling
5
+ # 3.1.1 - separate resourcelock_islocked logger, get_next_dt days/weeks offset
4
6
  # 3.1 - release
5
7
  # Support for and use of child loggers
6
8
  # deployfiles create empty dir
@@ -35,18 +37,26 @@ classifiers = [ # https://pypi.org/classifiers/
35
37
  ]
36
38
 
37
39
 
38
- # [project.optional-dependencies]
39
- # linux = ["posix-ipc >= 1.1.1; sys_platform == 'linux'"]
40
-
41
-
42
40
  [build-system]
43
41
  requires = ['setuptools']
44
42
  build-backend = 'setuptools.build_meta'
45
43
 
46
44
 
45
+ [project.scripts]
46
+ resourcelock = 'cjnfuncs.resourcelock:cli'
47
+
48
+
47
49
  [project.urls]
48
50
  repository = 'https://github.com/cjnaz/cjnfuncs'
49
51
 
50
52
 
51
- [project.scripts]
52
- resourcelock = 'cjnfuncs.resourcelock:cli'
53
+ [tool.setuptools.packages.find]
54
+ where = ["src"]
55
+
56
+
57
+ # [tool.setuptools]
58
+ # include-package-data = true
59
+
60
+
61
+ # [tool.setuptools.package-data]
62
+ # '*' = ['fonts/*', 'deployment_files/*']
@@ -0,0 +1,3 @@
1
+ import logging
2
+
3
+ logging.getLogger('cjnfuncs').setLevel(logging.WARNING)