Skip to content

Commit

Permalink
Add ReadTheDocs config file + misc fixes (#386)
Browse files Browse the repository at this point in the history
  • Loading branch information
subhashb authored Nov 21, 2023
1 parent a19e8b2 commit 422460a
Show file tree
Hide file tree
Showing 3 changed files with 27 additions and 2 deletions.
22 changes: 22 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
# .readthedocs.yaml
# Read the Docs configuration file
# See https://docs.readthedocs.io/en/stable/config-file/v2.html for details

# Required
version: 2

# Set the version of Python and other tools you might need
build:
os: ubuntu-22.04
tools:
python: "3.11"

# Build documentation in the docs/ directory with Sphinx
sphinx:
configuration: docs/conf.py

# We recommend specifying your dependencies to enable reproducible builds:
# https://docs.readthedocs.io/en/stable/guides/reproducible-builds.html
# python:
# install:
# - requirements: docs/requirements.txt
5 changes: 4 additions & 1 deletion src/protean/domain/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,10 @@ class Domain(_PackageBoundObject):
"AUTOLOAD_DOMAIN": True,
"IDENTITY_STRATEGY": IdentityStrategy.UUID.value,
"IDENTITY_TYPE": IdentityType.STRING.value,
"DATABASES": {"default": {"PROVIDER": "protean.adapters.MemoryProvider"}},
"DATABASES": {
"default": {"PROVIDER": "protean.adapters.MemoryProvider"},
"memory": {"PROVIDER": "protean.adapters.MemoryProvider"},
},
"EVENT_PROCESSING": EventProcessing.ASYNC.value,
"COMMAND_PROCESSING": CommandProcessing.ASYNC.value,
"EVENT_STORE": {
Expand Down
2 changes: 1 addition & 1 deletion tests/repository/child_entities.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ class Post(BaseAggregate):
title = String(required=True, max_length=1000)
slug = String(required=True, max_length=1024)
content = Text(required=True)
posted_at = DateTime(required=True, default=datetime.now())
posted_at = DateTime(required=True, default=datetime.now)

post_meta = HasOne("tests.repository.child_entities.PostMeta")
comments = HasMany("tests.repository.child_entities.Comment")
Expand Down

0 comments on commit 422460a

Please sign in to comment.