Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
244 commits
Select commit Hold shift + click to select a range
139258d
use src layout
d-v-b Aug 29, 2025
049310c
Merge pull request #1268 from d-v-b/impr/src-layout
dimitri-yatsenko Sep 5, 2025
ebeab88
use pytest to manage docker container startup for tests
d-v-b Sep 16, 2025
718e219
fix environment variable mismatch
d-v-b Sep 16, 2025
1252add
add database.port to settings.py, and update conftest
d-v-b Sep 16, 2025
fecbb83
revert python version floor increment
d-v-b Sep 16, 2025
76aaf5e
use normal healthcheck intervals
d-v-b Sep 16, 2025
c68f1df
revert change to healthcheck, because the nanoseconds were correct
d-v-b Sep 16, 2025
3a34d82
update gitignore
d-v-b Sep 16, 2025
f73d7c7
add pixi lockfile
d-v-b Sep 16, 2025
de13442
update .gitattributes for pixi
d-v-b Sep 16, 2025
64fc0ac
lint
d-v-b Sep 16, 2025
b3f82d9
add astroid exemption to codespell rc
d-v-b Sep 16, 2025
a321f92
spruce up linting workflow
d-v-b Sep 16, 2025
1aa30f4
lint with ruff
d-v-b Sep 16, 2025
de4ce27
update linting workflow
d-v-b Sep 16, 2025
59d0159
update test workflow to use src layout
d-v-b Sep 16, 2025
85ff041
update test workflow to use src layout
d-v-b Sep 16, 2025
2007f33
update hook invocations to use src layout
d-v-b Sep 16, 2025
9fcb25a
Merge pull request #1274 from d-v-b/fix/unbreak-test-workflow
dimitri-yatsenko Sep 17, 2025
896e6cd
Merge pull request #1269 from d-v-b/feat/pytest-container-management
dimitri-yatsenko Sep 19, 2025
b3b712b
simplify devcontainer
d-v-b Nov 10, 2025
a506d40
update deps, and add activate script for dot
d-v-b Nov 10, 2025
88ca4dc
refactor test fixtures
d-v-b Nov 10, 2025
a30d41b
skip multiprocessing tests on osx
d-v-b Nov 10, 2025
d631b8b
skip c901 check
d-v-b Nov 10, 2025
f45e7c8
update pre-commit
d-v-b Nov 10, 2025
4893e3d
Merge pull request #1279 from d-v-b/chore/dev-env-fixes
dimitri-yatsenko Dec 10, 2025
66c9ebd
Merge branch 'pre/v2.0' of https://github.com/datajoint/datajoint-pyt…
d-v-b Dec 11, 2025
b00a4f0
more linting
d-v-b Dec 12, 2025
65b701a
sync pyproject.toml
d-v-b Dec 12, 2025
908d226
fix long matlab blobs
d-v-b Dec 12, 2025
cb4c128
Merge pull request #1273 from d-v-b/impr/modernize-pre-commit
dimitri-yatsenko Dec 12, 2025
ddae20d
switch settings to use pydantic-settings
d-v-b Dec 17, 2025
80d6d6f
remove unnecessary class
d-v-b Dec 17, 2025
defebec
Merge pull request #1281 from d-v-b/chore/use-pydantic-settings
dimitri-yatsenko Dec 19, 2025
a268bd3
Merge remote-tracking branch 'origin/pre/v2.0' into claude/review-set…
claude Dec 19, 2025
6eb7eed
refactor: simplify settings to pure pydantic without backward compat
claude Dec 19, 2025
f5077db
feat: add recursive config search and secrets separation
claude Dec 19, 2025
df45286
fix: remove unused imports (ruff)
claude Dec 20, 2025
898c5c2
style: apply ruff-format changes
claude Dec 20, 2025
aefb7cf
feat: add type aliases for numeric column types
claude Dec 20, 2025
864121d
feat: add int64 and uint64 type aliases
claude Dec 20, 2025
ca7f078
test: add tests for numeric type aliases
claude Dec 20, 2025
36a553a
fix: remove unused import in test_type_aliases
claude Dec 20, 2025
43bd053
refactor: remove set_password from admin module
claude Dec 20, 2025
97107f6
refactor: remove save methods from settings
claude Dec 20, 2025
69ed63e
docs: update documentation for new settings system
claude Dec 20, 2025
6fefbf6
docs: add documentation for numeric type aliases
claude Dec 20, 2025
b55c1bf
Drop support for Python < 3.10 and MySQL < 8.0
claude Dec 20, 2025
83fc7bd
Update documentation and CI for Python 3.10+ and MySQL 8.0+
claude Dec 20, 2025
028dbad
Merge remote-tracking branch 'origin/claude/drop-legacy-support-rFhLT…
claude Dec 20, 2025
4518b36
Add initial specification for file column type
claude Dec 20, 2025
ba3c66b
Revise file type spec: unified storage backend with fsspec
claude Dec 20, 2025
965a30f
Update file type spec to use existing datajoint.json settings
claude Dec 20, 2025
667e740
Add filename collision avoidance and transaction handling to spec
claude Dec 20, 2025
9d3e194
Major spec revision: files/folders, transactions, fetch handles
claude Dec 20, 2025
93559a4
Update path structure: field after PK, add partition pattern
claude Dec 20, 2025
dc1c899
Add PK value encoding rules for paths
claude Dec 20, 2025
5f27b75
Clarify orphan cleanup as separate maintenance procedure
claude Dec 20, 2025
4f15c90
Add legacy type deprecation notice
claude Dec 20, 2025
af6cef2
Add store metadata and client verification mechanism
claude Dec 20, 2025
ec2e737
Simplify store metadata - remove schema tracking
claude Dec 20, 2025
b32ef8d
Rename type from 'file' to 'object'
claude Dec 20, 2025
93ce01e
Add Zarr compatibility: staged insert and fsspec access
claude Dec 20, 2025
997d992
Finalize staged_insert1 API for direct object storage writes
claude Dec 20, 2025
36806cc
Simplify object naming: field name as base, extension from source
claude Dec 20, 2025
6c6349b
Restructure store paths: objects/ after table, rename store config
claude Dec 20, 2025
0ea880a
Make content hashing optional, add folder manifests
claude Dec 21, 2025
c340ec7
Clarify folder manifest storage location and rationale
claude Dec 21, 2025
6cd9b9c
Add optional database_host and database_name to store metadata
claude Dec 21, 2025
38844f1
Highlight no hidden tables - key architectural difference
claude Dec 21, 2025
d65ece7
Refactor external storage to use fsspec for unified backend
claude Dec 21, 2025
4b7e7bd
Fix unused imports (ruff lint)
claude Dec 21, 2025
949b8a6
Fix ruff-format: add blank lines after local imports
claude Dec 21, 2025
0019109
Implement object column type for managed file storage
claude Dec 21, 2025
b45df2c
Fix ruff lint: line length and unused imports
claude Dec 21, 2025
adf4305
Fix unused imports (ruff lint)
claude Dec 21, 2025
095753f
Add documentation for object column type
claude Dec 21, 2025
08838f6
Fix ruff-format: code formatting adjustments
claude Dec 21, 2025
3da69fd
Add pytest tests for object column type
claude Dec 21, 2025
944c9be
Fix E402: move schema_object import to top of file
claude Dec 21, 2025
752248c
Fix unused imports (ruff lint)
claude Dec 21, 2025
7ef4e61
Fix ruff-format: add blank lines after local imports
claude Dec 21, 2025
f9e7496
"strongly-typed" -> "type-checked" Json in documentation.
dimitri-yatsenko Dec 22, 2025
d68ea68
feat: add bool/boolean type alias
claude Dec 22, 2025
e202818
refactor: simplify bool type alias to only support 'bool'
claude Dec 22, 2025
15418c3
Address Zarr reviewer feedback: optional metadata fields
claude Dec 22, 2025
fb8c0cb
Add Augmented Schema vs External References section
claude Dec 22, 2025
a9447e7
Rename file-type-spec.md to object-type-spec.md
claude Dec 22, 2025
5170ab1
Fix ruff-format: single line error message
claude Dec 22, 2025
3e32188
Simplify ExternalTable storage initialization
claude Dec 22, 2025
4e90c1e
Clarify staged insert compatibility: Zarr/TileDB yes, HDF5 no
claude Dec 22, 2025
5a727d2
Add remote URL support for copy insert
claude Dec 22, 2025
4bdc882
Remove redundant self.spec attribute from ExternalTable
claude Dec 22, 2025
cc96f03
Fix ruff-format: single line error message in upload_filepath
claude Dec 22, 2025
b2bc219
Merge branch claude/add-type-aliases-6uN3E
claude Dec 22, 2025
38a0bfb
Merge pull request #1282 from datajoint/claude/review-settings-manage…
d-v-b Dec 22, 2025
67cdb68
Merge pull request #1287 from datajoint/claude/drop-legacy-support-rFhLT
d-v-b Dec 22, 2025
45a94e1
refactor: rename TYPE_ALIASES to SQL_TYPE_ALIASES
claude Dec 22, 2025
d7e3fcf
Merge remote-tracking branch 'origin/pre/v2.0' into claude/add-type-a…
claude Dec 22, 2025
8ee058a
Merge pre/v2.0
claude Dec 22, 2025
6bce2a5
Merge pull request #1283 from datajoint/claude/add-type-aliases-6uN3E
ttngu207 Dec 22, 2025
36f3bb7
Merge pre/v2.0
claude Dec 22, 2025
d5439cf
Address reviewer feedback on object type spec
claude Dec 23, 2025
54460ed
Fix ruff lint and format issues in preview.py
claude Dec 23, 2025
052a40b
Add access control patterns section to spec
claude Dec 23, 2025
260a43a
Update object type spec for multi-store support
claude Dec 24, 2025
5ed7329
Implement multi-store support for object type
claude Dec 24, 2025
895259f
Merge pull request #1288 from datajoint/claude/add-file-column-type-L…
dimitri-yatsenko Dec 24, 2025
164e7cc
Implement Custom Types -- AttributeType (#1289)
dimitri-yatsenko Jan 1, 2026
bab8d1e
Add decimal(n,f) to core types (Tier 2)
claude Jan 1, 2026
21dd700
Rename core type 'blob' to 'bytes' for cross-database portability
claude Jan 1, 2026
2f38734
Fix dtype table: longblob is native type for raw bytes
claude Jan 1, 2026
4399f51
Update enum PostgreSQL mapping to use native ENUM type
claude Jan 1, 2026
7e32089
Document UTC timezone policy for datetime type
claude Jan 1, 2026
5d2c9f6
Add text to core types and document type modifier policy
claude Jan 1, 2026
e55c9a7
Add encoding and collation policy documentation
claude Jan 1, 2026
4fa802a
Document AttributeType naming conventions comprehensively
claude Jan 1, 2026
11d67a6
Redesign AttributeType naming with @ storage mode convention
claude Jan 1, 2026
d6bdd80
Fix content@ notation in json dtype description
claude Jan 1, 2026
1ad327d
Rename content type to hash for clarity
claude Jan 1, 2026
92647f1
Fix DataJoint syntax in HashRegistry definition
claude Jan 1, 2026
7d0a5a5
Clarify nullability and default value handling
claude Jan 1, 2026
af7c76c
Remove HashRegistry table, use JSON field scanning for GC
claude Jan 1, 2026
691edcc
Use MD5 instead of SHA256 for content hashing
claude Jan 1, 2026
905c463
Remove dead code: uuid_from_file and uuid_from_stream
claude Jan 1, 2026
57af0e8
Remove outdated storage-types-implementation-plan.md
claude Jan 1, 2026
40d7871
Fix type pattern conflicts and BLOB reference
dimitri-yatsenko Jan 1, 2026
5cb5ae4
Rename AttributeTypes to Codec Types in documentation
claude Jan 1, 2026
2dde3d9
Add Codec base class with __init_subclass__ auto-registration
claude Jan 1, 2026
8218fa7
Update Codec API with get_dtype(is_external) method
claude Jan 1, 2026
e7054dd
Unify codec names and fix external storage chain
dimitri-yatsenko Jan 1, 2026
898d0ed
Rename AttributeType/adapter terminology to Codec
dimitri-yatsenko Jan 1, 2026
f3e4489
Remove backward compatibility aliases from Codec API
dimitri-yatsenko Jan 1, 2026
4417ec1
Add Codec documentation with plugin specification
dimitri-yatsenko Jan 1, 2026
568d71a
Remove object-type-spec.md (implementation complete)
dimitri-yatsenko Jan 1, 2026
8271c86
Clean up dead code and outdated terminology
dimitri-yatsenko Jan 2, 2026
39cd993
Remove enable_filepath_feature fixture
dimitri-yatsenko Jan 2, 2026
11e492b
Rename tests to use Codec terminology
dimitri-yatsenko Jan 2, 2026
d4560e6
Implement testcontainers for pytest-managed container lifecycle
dimitri-yatsenko Jan 2, 2026
70f53d4
Fix test compatibility with testcontainers
dimitri-yatsenko Jan 2, 2026
fa47f47
Add pytest marks for test dependency management
dimitri-yatsenko Jan 2, 2026
6691f65
Implement semantic matching for joins based on attribute lineage
dimitri-yatsenko Jan 2, 2026
a3dcabf
Simplify delete_table_lineages call and update spec types
dimitri-yatsenko Jan 2, 2026
19cde1c
Add schema.lineage property to view all lineages
dimitri-yatsenko Jan 2, 2026
ba81cb8
Implement primary key rules for join operations
dimitri-yatsenko Jan 3, 2026
85ee0f8
Add extend() method as semantic alias for left join
dimitri-yatsenko Jan 3, 2026
1e9e1ba
Add AutoPopulate 1.0 and 2.0 specification documents
dimitri-yatsenko Jan 3, 2026
8255b11
Add implementation plan and update spec with ~~ naming
dimitri-yatsenko Jan 3, 2026
5f5f6a0
Implement Job class and update schema.jobs property
dimitri-yatsenko Jan 3, 2026
c9e5c58
Add per-table job management and FK-only PK validation
dimitri-yatsenko Jan 3, 2026
4e6f230
Complete AutoPopulate 2.0 implementation with per-table Job management
dimitri-yatsenko Jan 4, 2026
2a7aed2
Update test schemas to use core DataJoint types
dimitri-yatsenko Jan 4, 2026
26a2445
Use datetime(3) for Job table timestamps
dimitri-yatsenko Jan 4, 2026
b09310d
Implement hidden job metadata and replace NATURAL JOIN with USING
dimitri-yatsenko Jan 4, 2026
574b5f1
Remove deprecated add_hidden_timestamp feature and dead code
dimitri-yatsenko Jan 4, 2026
f89be6f
Add job metadata migration utility and optimize progress()
dimitri-yatsenko Jan 4, 2026
1e5afa5
Fix Part.delete to pass through kwargs to Table.delete
dimitri-yatsenko Jan 4, 2026
6b56f25
Modernize fetch API with composable output methods
dimitri-yatsenko Jan 4, 2026
5b5d09a
Add insert API improvements: validate(), chunk_size, insert_dataframe()
dimitri-yatsenko Jan 4, 2026
4164348
Add Polars and PyArrow insert support
dimitri-yatsenko Jan 4, 2026
1d2832b
docs: Harmonize docstrings to NumPy style with Python 3.10+ type hints
dimitri-yatsenko Jan 4, 2026
66f143e
Merge origin/claude/modern-fetch-api: Add Polars and PyArrow insert s…
dimitri-yatsenko Jan 4, 2026
96e2edf
docs: Continue docstring harmonization to NumPy style (batch 2)
dimitri-yatsenko Jan 4, 2026
8dbe50f
docs: Continue docstring harmonization to NumPy style (batch 3)
dimitri-yatsenko Jan 4, 2026
2f3e88b
docs: Continue docstring harmonization to NumPy style (batch 4)
dimitri-yatsenko Jan 4, 2026
ff04914
docs: Update README and change license to Apache 2.0
dimitri-yatsenko Jan 4, 2026
7c7e404
docs: Restructure to developer-focused documentation
dimitri-yatsenko Jan 4, 2026
2108a0c
docs: Remove changelog (now auto-generated by GitHub)
dimitri-yatsenko Jan 4, 2026
b3d3014
docs: Streamline contributing guide
dimitri-yatsenko Jan 4, 2026
13b73a0
docs: Add table declaration specification
dimitri-yatsenko Jan 5, 2026
f081477
Add include_key parameter to to_arrays() for primary key retrieval
dimitri-yatsenko Jan 6, 2026
5a9bc4a
merge: Integrate modern-fetch-api branch
dimitri-yatsenko Jan 6, 2026
c16e79f
docs: Update README with Relational Workflow Model and OAS
dimitri-yatsenko Jan 6, 2026
a024baa
Replace safemode parameter with prompt in delete() and drop()
dimitri-yatsenko Jan 6, 2026
a237b26
Simplify fetch API: remove download_path, fetch.py, Fetch1 class
dimitri-yatsenko Jan 6, 2026
7820702
merge: Integrate modern-fetch-api with updated fetch methods
dimitri-yatsenko Jan 6, 2026
d1dafdc
Change aggr default to keep all rows (like proj)
dimitri-yatsenko Jan 6, 2026
d5c275d
Merge remote-tracking branch 'origin/claude/modern-fetch-api' into do…
dimitri-yatsenko Jan 6, 2026
aa1db4f
Allow empty insert for tables with all defaults (#1280)
dimitri-yatsenko Jan 6, 2026
736860e
Make Codec.get_dtype() an abstractmethod for consistency
dimitri-yatsenko Jan 6, 2026
9207d83
fix: Handle np.bool_ in insert and fix download_path tests
dimitri-yatsenko Jan 6, 2026
c3fbf35
Merge pull request #1300 from datajoint/claude/clarify-column-type-na…
dimitri-yatsenko Jan 7, 2026
7d855b7
Merge pull request #1301 from datajoint/claude/semantic-match
dimitri-yatsenko Jan 7, 2026
42441f5
Merge pull request #1302 from datajoint/claude/pk-rules
dimitri-yatsenko Jan 7, 2026
83b380f
Merge pull request #1303 from datajoint/claude/autopopulate-2.0
dimitri-yatsenko Jan 7, 2026
c78ab51
Merge pull request #1304 from datajoint/claude/modern-fetch-api
dimitri-yatsenko Jan 7, 2026
3c2d805
Merge branch 'docs-2.0-migration' into empty_insert
dimitri-yatsenko Jan 7, 2026
1cf37b8
Fix missing newline at end of version.py
dimitri-yatsenko Jan 7, 2026
6fb88d8
Merge pull request #1306 from datajoint/empty_insert
dimitri-yatsenko Jan 7, 2026
ff7f71e
license: Clean up Apache 2.0 transition (fixes #1235)
dimitri-yatsenko Jan 7, 2026
0e81f05
Merge pull request #1305 from datajoint/docs-2.0-migration
dimitri-yatsenko Jan 7, 2026
9f28b10
fix: enable auto_mkdir for local filesystem in StorageBackend
dimitri-yatsenko Jan 8, 2026
9737dee
fix(Top): allow order_by=None to inherit existing ordering (#1242)
dimitri-yatsenko Jan 8, 2026
c2a2eae
refactor: improve API consistency for jobs and schema.drop
dimitri-yatsenko Jan 8, 2026
cabdb74
refactor(delete): replace force_parts/force_masters with part_integrity
dimitri-yatsenko Jan 8, 2026
dacf4ac
ci: add MySQL/MinIO services to GitHub Actions workflow
dimitri-yatsenko Jan 8, 2026
ae5fd68
style: format user_tables.py
dimitri-yatsenko Jan 8, 2026
fbc4cad
ci: use docker-compose for test services
dimitri-yatsenko Jan 8, 2026
d778e4f
ci: install graphviz for ERD tests
dimitri-yatsenko Jan 8, 2026
4f4a924
fix(jobs): use MySQL server time consistently for all scheduling
dimitri-yatsenko Jan 8, 2026
344de9b
fix(jobs): use NOW(3) to match CURRENT_TIMESTAMP(3) precision
dimitri-yatsenko Jan 8, 2026
2100487
refactor(jobs): always use NOW(3) + INTERVAL for scheduled_time
dimitri-yatsenko Jan 8, 2026
1fdfb3e
ci: use pixi for CI workflow
dimitri-yatsenko Jan 8, 2026
307983a
docs: update developer guide to use pixi as primary toolchain
dimitri-yatsenko Jan 8, 2026
272fcb5
ci: disable locked mode for pixi install
dimitri-yatsenko Jan 8, 2026
b8645f8
fix(pixi): add test extras to feature-specific pypi-dependencies
dimitri-yatsenko Jan 8, 2026
27391c7
feat: add mypy type checking to pre-commit
dimitri-yatsenko Jan 8, 2026
f195110
feat: add unit tests to pre-commit hooks
dimitri-yatsenko Jan 8, 2026
46333e0
Merge PR #1312: DataJoint 2.0 - Jobs 2.0, CI, part_integrity, and more
dimitri-yatsenko Jan 8, 2026
f824af2
test(Top): verify dj.Top preserves ORDER BY in results
dimitri-yatsenko Jan 8, 2026
17c5f4d
feat: modernize virtual schema infrastructure
dimitri-yatsenko Jan 8, 2026
a6bc04b
chore: update pre-commit comment to reference ruff
dimitri-yatsenko Jan 8, 2026
2c6dcb9
feat: add type annotations to errors and hash modules
dimitri-yatsenko Jan 8, 2026
11de5b5
fix: prevent auto-labeler from removing manual labels
dimitri-yatsenko Jan 8, 2026
405f10e
docs: update package keywords for modern data engineering
dimitri-yatsenko Jan 8, 2026
bc8e3bd
fix: handle tier prefixes in Schema.get_table and __contains__
dimitri-yatsenko Jan 8, 2026
400b4a4
fix: update virtual module tests to use 2.0 fetch API
dimitri-yatsenko Jan 8, 2026
612511d
fix: update CLI to use virtual_schema instead of create_virtual_module
dimitri-yatsenko Jan 8, 2026
2665f5b
fix: use VirtualModule with custom name in CLI
dimitri-yatsenko Jan 8, 2026
73f9fba
fix: resolve CLI -h conflict with --help
dimitri-yatsenko Jan 8, 2026
ec44361
test: update CLI tests for --host flag change
dimitri-yatsenko Jan 9, 2026
3c8258b
style: format cli.py with ruff
dimitri-yatsenko Jan 9, 2026
ef66992
style: format test_cli.py with ruff
dimitri-yatsenko Jan 9, 2026
c1b36f0
Merge pull request #1313 from datajoint/virtual-modules
dimitri-yatsenko Jan 9, 2026
23c3d82
fix: Aggregation and Union __bool__ always returning True (#1234) (#1…
dimitri-yatsenko Jan 9, 2026
38d0f94
fix: add dark mode support for table previews in Jupyter (#1167) (#1315)
dimitri-yatsenko Jan 9, 2026
3f5b237
fix: return 0 from delete() when user cancels operation (#1155) (#1316)
dimitri-yatsenko Jan 9, 2026
5f2847c
fix: handle TypeError in lookup_class_name for Diagram (#1072) (#1317)
dimitri-yatsenko Jan 9, 2026
d38a670
refactor: remove text from core types, keep as native passthrough (#1…
dimitri-yatsenko Jan 9, 2026
1673be8
fix: translate MySQL error 3730 to IntegrityError (#1032) (#1319)
dimitri-yatsenko Jan 9, 2026
1270d90
feat: add context manager support to Connection class (#1320)
dimitri-yatsenko Jan 9, 2026
299ac0d
perf: implement lazy imports for heavy dependencies (#1321)
dimitri-yatsenko Jan 9, 2026
8732f87
fix: raise error when table declaration fails due to permissions (#1322)
dimitri-yatsenko Jan 9, 2026
1aa68c0
fix: handle MATLAB cell arrays with empty/nested elements (#1323)
dimitri-yatsenko Jan 9, 2026
6c29792
fix: provide helpful error when table heading is not configured (#1324)
dimitri-yatsenko Jan 9, 2026
1a3e3d1
feat: Add URL representation for storage paths and remove orphaned do…
dimitri-yatsenko Jan 9, 2026
c93f1c4
ci: Add pre/v2.0 branch to breaking and bug label patterns
dimitri-yatsenko Jan 9, 2026
23967f4
style: Reduce query result table font size to 75%
dimitri-yatsenko Jan 10, 2026
90e5c17
chore: Remove accidentally committed config files
dimitri-yatsenko Jan 10, 2026
5db3359
docs: Use uint16 instead of native int in codec examples
dimitri-yatsenko Jan 10, 2026
7269d44
chore: Remove accidentally committed config files
dimitri-yatsenko Jan 10, 2026
8456f39
chore: Add .secrets and datajoint.json to gitignore
dimitri-yatsenko Jan 10, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions .codespellrc

This file was deleted.

7 changes: 4 additions & 3 deletions .devcontainer/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ RUN \
pip uninstall datajoint -y

USER root
ENV DJ_HOST db
ENV DJ_USER root
ENV DJ_PASS password
ENV DJ_HOST=db
ENV DJ_USER=root
ENV DJ_PASS=password
ENV S3_ENDPOINT=minio:9000
58 changes: 4 additions & 54 deletions .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
@@ -1,56 +1,6 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/docker-existing-docker-compose
{
"name": "Existing Docker Compose (Extend)",
// Update the 'dockerComposeFile' list if you have more compose files or use different names.
// The .devcontainer/docker-compose.yml file contains any overrides you need/want to make.
"dockerComposeFile": [
"../docker-compose.yaml",
"docker-compose.yml"
],
// The 'service' property is the name of the service for the container that VS Code should
// use. Update this value and .devcontainer/docker-compose.yml to the real service name.
"service": "app",
// The optional 'workspaceFolder' property is the path VS Code should open by default when
// connected. This is typically a file mount in .devcontainer/docker-compose.yml
"workspaceFolder": "/workspaces/${localWorkspaceFolderBasename}",
// Features to add to the dev container. More info: https://containers.dev/features.
// "features": {},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [
80,
443,
3306,
8080,
9000
],
"mounts": [
"type=bind,source=${env:SSH_AUTH_SOCK},target=/ssh-agent"
],
"containerEnv": {
"SSH_AUTH_SOCK": "/ssh-agent"
},
// Uncomment the next line if you want start specific services in your Docker Compose config.
// "runServices": [],
// Uncomment the next line if you want to keep your containers running after VS Code shuts down.
"shutdownAction": "stopCompose",
"onCreateCommand": "python3 -m pip install -q -e .[dev]",
"features": {
"ghcr.io/devcontainers/features/git:1": {},
"ghcr.io/devcontainers/features/docker-in-docker:2": {},
"ghcr.io/devcontainers/features/github-cli:1": {},
},
// Configure tool-specific properties.
"customizations": {
"vscode": {
"extensions": [
"ms-python.python"
]
}
},
"remoteEnv": {
"LOCAL_WORKSPACE_FOLDER": "${localWorkspaceFolder}"
}
// Uncomment to connect as an existing user other than the container default. More info: https://aka.ms/dev-containers-non-root.
// "remoteUser": "devcontainer"
"dockerComposeFile": ["../docker-compose.yaml", "docker-compose.yml"],
"service": "app",
"workspaceFolder": "/src",
"postCreateCommand": "curl -fsSL https://pixi.sh/install.sh | bash && echo 'export PATH=\"$HOME/.pixi/bin:$PATH\"' >> ~/.bashrc"
}
24 changes: 4 additions & 20 deletions .devcontainer/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,30 +1,14 @@
# Devcontainer overrides for the app service from ../docker-compose.yaml
# Inherits db and minio services automatically
services:
# Update this to the name of the service you want to work with in your docker-compose.yml file
app:
# Uncomment if you want to override the service's Dockerfile to one in the .devcontainer
# folder. Note that the path of the Dockerfile and context is relative to the *primary*
# docker-compose.yml file (the first in the devcontainer.json "dockerComposeFile"
# array). The sample below assumes your primary file is in the root of your project.
container_name: datajoint-python-devcontainer
image: datajoint/datajoint-python-devcontainer:${PY_VER:-3.11}-${DISTRO:-bookworm}
build:
context: .
context: ..
dockerfile: .devcontainer/Dockerfile
args:
- PY_VER=${PY_VER:-3.11}
- DISTRO=${DISTRO:-bookworm}

volumes:
# Update this to wherever you want VS Code to mount the folder of your project
- ..:/workspaces:cached

# Uncomment the next four lines if you will use a ptrace-based debugger like C++, Go, and Rust.
# cap_add:
# - SYS_PTRACE
# security_opt:
# - seccomp:unconfined

user: root

# Overrides default command so things don't shut down after the process ends.
# Keep container running for devcontainer
command: /bin/sh -c "while sleep 1000; do :; done"
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# SCM syntax highlighting & preventing 3-way merges
pixi.lock merge=binary linguist-language=YAML linguist-generated=true
4 changes: 2 additions & 2 deletions .github/pr_labeler.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
# https://github.com/actions/labeler
breaking:
- head-branch: ['breaking', 'BREAKING']
- head-branch: ['breaking', 'BREAKING', 'pre/v2.0']
bug:
- head-branch: ['fix', 'FIX', 'bug', 'BUG']
- head-branch: ['fix', 'FIX', 'bug', 'BUG', 'pre/v2.0']
feature:
- head-branch: ['feat', 'FEAT']
documentation:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/label_prs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,5 @@ jobs:
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
configuration-path: .github/pr_labeler.yaml
sync-labels: true
sync-labels: false # Don't remove manually added labels
dot: true
4 changes: 2 additions & 2 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
extra_args: codespell --all-files
- uses: pre-commit/[email protected]
with:
extra_args: black --all-files
extra_args: ruff --all-files
- uses: pre-commit/[email protected]
with:
extra_args: flake8 --all-files
extra_args: ruff-format --all-files
8 changes: 4 additions & 4 deletions .github/workflows/post_draft_release_published.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ jobs:
strategy:
matrix:
include:
- py_ver: "3.9"
- py_ver: "3.10"
runs-on: ubuntu-latest
env:
PY_VER: ${{matrix.py_ver}}
Expand All @@ -40,14 +40,14 @@ jobs:
- name: Update version.py
run: |
VERSION=$(echo "${{ github.event.release.name }}" | grep -oP '\d+\.\d+\.\d+')
sed -i "s/^__version__ = .*/__version__ = \"$VERSION\"/" datajoint/version.py
cat datajoint/version.py
sed -i "s/^__version__ = .*/__version__ = \"$VERSION\"/" src/datajoint/version.py
cat src/datajoint/version.py
# Commit the changes
BRANCH_NAME="update-version-$VERSION"
git switch -c $BRANCH_NAME
git config --global user.name "github-actions"
git config --global user.email "[email protected]"
git add datajoint/version.py
git add src/datajoint/version.py
git commit -m "Update version.py to $VERSION"
echo "BRANCH_NAME=$BRANCH_NAME" >> $GITHUB_ENV
- name: Update README.md badge
Expand Down
69 changes: 41 additions & 28 deletions .github/workflows/test.yaml
Original file line number Diff line number Diff line change
@@ -1,42 +1,55 @@
name: Test

on:
push:
branches:
- "**" # every branch
- "!gh-pages" # exclude gh-pages branch
- "!stage*" # exclude branches beginning with stage
- "**"
- "!gh-pages"
- "!stage*"
paths:
- "datajoint"
- "tests"
- "src/datajoint/**"
- "tests/**"
- "pyproject.toml"
- "pixi.lock"
- ".github/workflows/test.yaml"
pull_request:
branches:
- "**" # every branch
- "!gh-pages" # exclude gh-pages branch
- "!stage*" # exclude branches beginning with stage
- "**"
- "!gh-pages"
- "!stage*"
paths:
- "datajoint"
- "tests"
- "src/datajoint/**"
- "tests/**"
- "pyproject.toml"
- "pixi.lock"
- ".github/workflows/test.yaml"

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
py_ver: ["3.9", "3.10", "3.11", "3.12", "3.13"]
mysql_ver: ["8.0"]
include:
- py_ver: "3.9"
mysql_ver: "5.7"
steps:
- uses: actions/checkout@v4
- name: Set up Python ${{matrix.py_ver}}
uses: actions/setup-python@v5

- name: Set up pixi
uses: prefix-dev/[email protected]
with:
python-version: ${{matrix.py_ver}}
- name: Integration test
env:
PY_VER: ${{matrix.py_ver}}
MYSQL_VER: ${{matrix.mysql_ver}}
# taking default variables set in docker-compose.yaml to sync with local test
run: |
export HOST_UID=$(id -u)
docker compose --profile test up --quiet-pull --build --exit-code-from djtest djtest
cache: true
locked: false

- name: Run tests
run: pixi run -e test test-cov

# Unit tests run without containers (faster feedback)
unit-tests:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Set up pixi
uses: prefix-dev/[email protected]
with:
cache: true
locked: false

- name: Run unit tests
run: pixi run -e test pytest tests/unit -v
7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -185,3 +185,10 @@ cython_debug/
dj_local_conf.json
*.env
!.vscode/launch.json
# pixi environments
.pixi
_content/

# Local config
.secrets/
datajoint.json
68 changes: 32 additions & 36 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
# pip install datajoint[test]
# pre-commit install
# pre-commit run --all-files
# pre-commit autoupdate
# SKIP=flake8 git commit -m "foo"
# SKIP=ruff git commit -m "foo"

# See https://pre-commit.com for more information
# See https://pre-commit.com/hooks.html for more hooks
Expand All @@ -20,43 +19,40 @@ repos:
rev: v2.4.1
hooks:
- id: codespell
- repo: https://github.com/pycqa/isort
rev: 6.0.1 # Use the latest stable version
args: [--toml, pyproject.toml]
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.8.4
hooks:
- id: isort
args:
- --profile=black # Optional, makes isort compatible with Black
- repo: https://github.com/psf/black
rev: 25.1.0 # matching versions in pyproject.toml and github actions
hooks:
- id: black
args: ["--check", "-v", "datajoint", "tests", "--diff"] # --required-version is conflicting with pre-commit
- repo: https://github.com/PyCQA/flake8
rev: 7.3.0
hooks:
# syntax tests
- id: flake8
args:
- --select=E9,F63,F7,F82
- --count
- --show-source
- --statistics
files: datajoint # a lot of files in tests are not compliant
# style tests
- id: flake8
args:
- --ignore=E203,E722,W503
- --count
- --max-complexity=62
- --max-line-length=127
- --statistics
- --per-file-ignores=datajoint/diagram.py:C901
files: datajoint # a lot of files in tests are not compliant
# Run the linter
- id: ruff
args: [--fix]
files: ^(src/|tests/)
# Run the formatter
- id: ruff-format
files: ^(src/|tests/)
- repo: https://github.com/rhysd/actionlint
rev: v1.7.7
hooks:
# lint github actions workflow yaml
- id: actionlint

## Suggest to add pytest hook that runs unit test | Prerequisite: split unit/integration test
## https://github.com/datajoint/datajoint-python/issues/1211
- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.14.1
hooks:
- id: mypy
files: ^src/datajoint/
additional_dependencies:
- pydantic
- pydantic-settings
- types-PyMySQL
- types-tqdm
- pandas-stubs
- numpy
- repo: local
hooks:
- id: unit-tests
name: unit tests
entry: pytest tests/unit/ -v --tb=short
language: system
pass_filenames: false
always_run: true
stages: [pre-commit]
Loading
Loading