pydantic-fixedwidth 0.1.2__tar.gz → 0.2.0__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 pydantic-fixedwidth might be problematic. Click here for more details.

Files changed (24) hide show
  1. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.devcontainer/devcontainer.json +1 -1
  2. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.github/workflows/ci.yaml +2 -2
  3. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.github/workflows/release.yaml +1 -1
  4. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/PKG-INFO +8 -2
  5. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/README.md +7 -1
  6. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/pyproject.toml +1 -1
  7. pydantic_fixedwidth-0.2.0/uv.lock +504 -0
  8. pydantic_fixedwidth-0.1.2/uv.lock +0 -454
  9. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.devcontainer/onCreateCommand.sh +0 -0
  10. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.editorconfig +0 -0
  11. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.gitattributes +0 -0
  12. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.github/dependabot.yaml +0 -0
  13. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.gitignore +0 -0
  14. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.pre-commit-config.yaml +0 -0
  15. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.python-version +0 -0
  16. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.vscode/extensions.json +0 -0
  17. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/.vscode/settings.json +0 -0
  18. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/LICENSE +0 -0
  19. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/Makefile +0 -0
  20. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/pydantic_fixedwidth/__init__.py +0 -0
  21. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/pydantic_fixedwidth/fixedwidth.py +0 -0
  22. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/pydantic_fixedwidth/py.typed +0 -0
  23. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/tests/__init__.py +0 -0
  24. {pydantic_fixedwidth-0.1.2 → pydantic_fixedwidth-0.2.0}/tests/test_fixedwidth.py +0 -0
@@ -2,7 +2,7 @@
2
2
  "name": "lasuillard/pydantic-fixedwidth",
3
3
  "image": "mcr.microsoft.com/devcontainers/base:1-bookworm",
4
4
  "features": {
5
- "ghcr.io/devcontainers-contrib/features/pre-commit:2": {}
5
+ "ghcr.io/devcontainers-extra/features/pre-commit:2": {}
6
6
  },
7
7
  "onCreateCommand": "./.devcontainer/onCreateCommand.sh",
8
8
  "postAttachCommand": "make install",
@@ -20,7 +20,7 @@ jobs:
20
20
  uses: actions/checkout@v4
21
21
 
22
22
  - name: Set up uv
23
- uses: astral-sh/setup-uv@v5
23
+ uses: astral-sh/setup-uv@v6
24
24
  with:
25
25
  version: latest
26
26
  enable-cache: true
@@ -51,7 +51,7 @@ jobs:
51
51
  uses: actions/checkout@v4
52
52
 
53
53
  - name: Set up uv
54
- uses: astral-sh/setup-uv@v5
54
+ uses: astral-sh/setup-uv@v6
55
55
  with:
56
56
  version: latest
57
57
  enable-cache: true
@@ -17,7 +17,7 @@ jobs:
17
17
  uses: actions/checkout@v4
18
18
 
19
19
  - name: Set up uv
20
- uses: astral-sh/setup-uv@v5
20
+ uses: astral-sh/setup-uv@v6
21
21
  with:
22
22
  version: latest
23
23
  enable-cache: true
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pydantic-fixedwidth
3
- Version: 0.1.2
3
+ Version: 0.2.0
4
4
  Summary: Custom Pydantic models for parsing and serializing fixed-width format of data.
5
5
  Project-URL: Homepage, https://github.com/lasuillard/pydantic-fixedwidth
6
6
  Project-URL: Repository, https://github.com/lasuillard/pydantic-fixedwidth.git
@@ -24,7 +24,7 @@ Description-Content-Type: text/markdown
24
24
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
25
25
  [![CI](https://github.com/lasuillard/pydantic-fixedwidth/actions/workflows/ci.yaml/badge.svg)](https://github.com/lasuillard/pydantic-fixedwidth/actions/workflows/ci.yaml)
26
26
  [![codecov](https://codecov.io/gh/lasuillard/pydantic-fixedwidth/graph/badge.svg?token=R5pQWB43DP)](https://codecov.io/gh/lasuillard/pydantic-fixedwidth)
27
- ![PyPI - Version](https://img.shields.io/pypi/v/pydantic-fixedwidth)
27
+ [![PyPI - Version](https://img.shields.io/pypi/v/pydantic-fixedwidth)](https://pypi.org/project/pydantic-fixedwidth/)
28
28
 
29
29
  Custom Pydantic models for serializing and deserializing fixed-width format data.
30
30
 
@@ -66,6 +66,7 @@ class SomeRequest(Fixedwidth):
66
66
  )
67
67
 
68
68
 
69
+ # Format model to bytes
69
70
  some_request = SomeRequest(
70
71
  string="<DFG&",
71
72
  hangul="한글",
@@ -76,4 +77,9 @@ b = some_request.format_bytes()
76
77
 
77
78
  assert len(b) == 54
78
79
  assert b == b"<DFG& \xed\x95\x9c\xea\xb8\x800000000381 20240123141120124277"
80
+
81
+ # Parse bytes into model
82
+ parsed_request = SomeRequest.parse_bytes(b)
83
+
84
+ assert parsed_request == some_request
79
85
  ```
@@ -3,7 +3,7 @@
3
3
  [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
4
4
  [![CI](https://github.com/lasuillard/pydantic-fixedwidth/actions/workflows/ci.yaml/badge.svg)](https://github.com/lasuillard/pydantic-fixedwidth/actions/workflows/ci.yaml)
5
5
  [![codecov](https://codecov.io/gh/lasuillard/pydantic-fixedwidth/graph/badge.svg?token=R5pQWB43DP)](https://codecov.io/gh/lasuillard/pydantic-fixedwidth)
6
- ![PyPI - Version](https://img.shields.io/pypi/v/pydantic-fixedwidth)
6
+ [![PyPI - Version](https://img.shields.io/pypi/v/pydantic-fixedwidth)](https://pypi.org/project/pydantic-fixedwidth/)
7
7
 
8
8
  Custom Pydantic models for serializing and deserializing fixed-width format data.
9
9
 
@@ -45,6 +45,7 @@ class SomeRequest(Fixedwidth):
45
45
  )
46
46
 
47
47
 
48
+ # Format model to bytes
48
49
  some_request = SomeRequest(
49
50
  string="<DFG&",
50
51
  hangul="한글",
@@ -55,4 +56,9 @@ b = some_request.format_bytes()
55
56
 
56
57
  assert len(b) == 54
57
58
  assert b == b"<DFG& \xed\x95\x9c\xea\xb8\x800000000381 20240123141120124277"
59
+
60
+ # Parse bytes into model
61
+ parsed_request = SomeRequest.parse_bytes(b)
62
+
63
+ assert parsed_request == some_request
58
64
  ```
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "pydantic-fixedwidth"
3
- version = "0.1.2"
3
+ version = "0.2.0"
4
4
  description = "Custom Pydantic models for parsing and serializing fixed-width format of data."
5
5
  readme = "README.md"
6
6
  license = "MIT"