dbos 0.13.0a1__tar.gz → 0.14.0a2__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.

Potentially problematic release.


This version of dbos might be problematic. Click here for more details.

Files changed (75) hide show
  1. {dbos-0.13.0a1 → dbos-0.14.0a2}/PKG-INFO +1 -1
  2. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_admin_sever.py +0 -1
  3. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_dbos_config.py +2 -2
  4. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/cli.py +3 -1
  5. {dbos-0.13.0a1 → dbos-0.14.0a2}/pyproject.toml +1 -1
  6. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_config.py +3 -0
  7. {dbos-0.13.0a1 → dbos-0.14.0a2}/LICENSE +0 -0
  8. {dbos-0.13.0a1 → dbos-0.14.0a2}/README.md +0 -0
  9. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/__init__.py +0 -0
  10. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_app_db.py +0 -0
  11. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_classproperty.py +0 -0
  12. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_context.py +0 -0
  13. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_core.py +0 -0
  14. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_croniter.py +0 -0
  15. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_dbos.py +0 -0
  16. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_error.py +0 -0
  17. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_fastapi.py +0 -0
  18. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_flask.py +0 -0
  19. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_kafka.py +0 -0
  20. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_kafka_message.py +0 -0
  21. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_logger.py +0 -0
  22. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/env.py +0 -0
  23. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/script.py.mako +0 -0
  24. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/50f3227f0b4b_fix_job_queue.py +0 -0
  25. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/5c361fc04708_added_system_tables.py +0 -0
  26. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/a3b18ad34abe_added_triggers.py +0 -0
  27. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/d76646551a6b_job_queue_limiter.py +0 -0
  28. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/d76646551a6c_workflow_queue.py +0 -0
  29. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_migrations/versions/eab0cc1d9a14_job_queue.py +0 -0
  30. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_queue.py +0 -0
  31. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_recovery.py +0 -0
  32. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_registrations.py +0 -0
  33. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_request.py +0 -0
  34. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_roles.py +0 -0
  35. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_scheduler.py +0 -0
  36. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_schemas/__init__.py +0 -0
  37. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_schemas/application_database.py +0 -0
  38. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_schemas/system_database.py +0 -0
  39. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_serialization.py +0 -0
  40. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_sys_db.py +0 -0
  41. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/README.md +0 -0
  42. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/__package/__init__.py +0 -0
  43. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/__package/main.py +0 -0
  44. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/__package/schema.py +0 -0
  45. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/alembic.ini +0 -0
  46. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/dbos-config.yaml.dbos +0 -0
  47. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/migrations/env.py.dbos +0 -0
  48. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/migrations/script.py.mako +0 -0
  49. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/migrations/versions/2024_07_31_180642_init.py +0 -0
  50. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_templates/hello/start_postgres_docker.py +0 -0
  51. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/_tracer.py +0 -0
  52. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/dbos-config.schema.json +0 -0
  53. {dbos-0.13.0a1 → dbos-0.14.0a2}/dbos/py.typed +0 -0
  54. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/__init__.py +0 -0
  55. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/atexit_no_ctor.py +0 -0
  56. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/atexit_no_launch.py +0 -0
  57. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/classdefs.py +0 -0
  58. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/conftest.py +0 -0
  59. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/more_classdefs.py +0 -0
  60. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_admin_server.py +0 -0
  61. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_classdecorators.py +0 -0
  62. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_concurrency.py +0 -0
  63. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_croniter.py +0 -0
  64. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_dbos.py +0 -0
  65. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_failures.py +0 -0
  66. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_fastapi.py +0 -0
  67. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_fastapi_roles.py +0 -0
  68. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_flask.py +0 -0
  69. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_kafka.py +0 -0
  70. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_package.py +0 -0
  71. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_queue.py +0 -0
  72. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_scheduler.py +0 -0
  73. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_schema_migration.py +0 -0
  74. {dbos-0.13.0a1 → dbos-0.14.0a2}/tests/test_singleton.py +0 -0
  75. {dbos-0.13.0a1 → dbos-0.14.0a2}/version/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: dbos
3
- Version: 0.13.0a1
3
+ Version: 0.14.0a2
4
4
  Summary: Ultra-lightweight durable execution in Python
5
5
  Author-Email: "DBOS, Inc." <contact@dbos.dev>
6
6
  License: MIT
@@ -53,7 +53,6 @@ class AdminRequestHandler(BaseHTTPRequestHandler):
53
53
  self._end_headers()
54
54
  self.wfile.write("healthy".encode("utf-8"))
55
55
  elif self.path == _deactivate_path:
56
- dbos_logger.info("Deactivating DBOS")
57
56
  # Stop all scheduled workflows, queues, and kafka loops
58
57
  for event in self.dbos.stop_events:
59
58
  event.set()
@@ -169,7 +169,7 @@ def load_config(config_file_path: str = "dbos-config.yaml") -> ConfigFile:
169
169
 
170
170
  if not _is_valid_app_name(data["name"]):
171
171
  raise DBOSInitializationError(
172
- f'Invalid app name {data["name"]}. App names must be between 3 and 30 characters and contain only alphanumeric characters, dashes, and underscores.'
172
+ f'Invalid app name {data["name"]}. App names must be between 3 and 30 characters long and contain only lowercase letters, numbers, dashes, and underscores.'
173
173
  )
174
174
 
175
175
  if "app_db_name" not in data["database"]:
@@ -198,4 +198,4 @@ def _app_name_to_db_name(app_name: str) -> str:
198
198
  def _set_env_vars(config: ConfigFile) -> None:
199
199
  for env, value in config.get("env", {}).items():
200
200
  if value is not None:
201
- os.environ[env] = value
201
+ os.environ[env] = str(value)
@@ -187,7 +187,9 @@ def init(
187
187
  )
188
188
 
189
189
  if not _is_valid_app_name(project_name):
190
- raise Exception(f"{project_name} is an invalid DBOS app name")
190
+ raise Exception(
191
+ f"{project_name} is an invalid DBOS app name. App names must be between 3 and 30 characters long and contain only lowercase letters, numbers, dashes, and underscores."
192
+ )
191
193
 
192
194
  templates_dir = _get_templates_directory()
193
195
  templates = [x.name for x in os.scandir(templates_dir) if x.is_dir()]
@@ -22,7 +22,7 @@ dependencies = [
22
22
  ]
23
23
  requires-python = ">=3.9"
24
24
  readme = "README.md"
25
- version = "0.13.0a1"
25
+ version = "0.14.0a2"
26
26
 
27
27
  [project.license]
28
28
  text = "MIT"
@@ -44,6 +44,7 @@ def test_valid_config(mocker):
44
44
  foo: ${BARBAR}
45
45
  bazbaz: BAZBAZ
46
46
  bob: ${BOBBOB}
47
+ test_number: 123
47
48
  """
48
49
  os.environ["BARBAR"] = "FOOFOO"
49
50
  mocker.patch(
@@ -61,10 +62,12 @@ def test_valid_config(mocker):
61
62
  assert configFile["database"]["connectionTimeoutMillis"] == 3000
62
63
  assert configFile["env"]["foo"] == "FOOFOO"
63
64
  assert configFile["env"]["bob"] is None # Unset environment variable
65
+ assert configFile["env"]["test_number"] == 123
64
66
 
65
67
  _set_env_vars(configFile)
66
68
  assert os.environ["bazbaz"] == "BAZBAZ"
67
69
  assert os.environ["foo"] == "FOOFOO"
70
+ assert os.environ["test_number"] == "123"
68
71
  assert "bob" not in os.environ
69
72
 
70
73
 
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes