Version: 2.0.0 Migration
Effective Date: February 2026
Deprecation Date: August 2026
Audience: All IPFS Datasets Python users
What's Changing:
The data_transformation/ directory is being consolidated into processors/ for better organization.
Action Required: Update your imports before August 2026. Your old imports will work with warnings until then.
Time to Complete: 5-10 minutes for most projects
Run this command to find all data_transformation imports in your code:
grep -r "from ipfs_datasets_py.data_transformation" . --include="*.py"Use this table to update your imports:
| Old Path | New Path |
|---|---|
data_transformation.ipld |
processors.storage.ipld |
data_transformation.serialization |
processors.serialization |
data_transformation.ipfs_formats |
processors.ipfs.formats |
data_transformation.unixfs |
processors.ipfs (unixfs) |
data_transformation.ucan |
processors.auth.ucan |
# Run with deprecation warnings visible
python -W default your_script.py
# Run tests
pytestIf you see deprecation warnings, you've successfully updated most imports. Update any remaining ones.
What Moved: All IPLD (InterPlanetary Linked Data) storage functionality
# ❌ OLD (deprecated)
from ipfs_datasets_py.data_transformation.ipld import (
IPLDStorage,
IPLDKnowledgeGraph,
IPLDVectorStore,
create_dag_node,
parse_dag_node
)
# ✅ NEW (current)
from ipfs_datasets_py.processors.storage.ipld import (
IPLDStorage,
IPLDKnowledgeGraph,
IPLDVectorStore,
create_dag_node,
parse_dag_node
)Use Cases: IPLD storage, knowledge graphs, vector stores
What Moved: All data format conversion and serialization
# ❌ OLD (deprecated)
from ipfs_datasets_py.data_transformation.serialization import (
DatasetSerializer,
DataInterchangeUtils
)
from ipfs_datasets_py.data_transformation.car_conversion import DataInterchangeUtils
from ipfs_datasets_py.data_transformation.jsonl_to_parquet import convert_jsonl
# ✅ NEW (current)
from ipfs_datasets_py.processors.serialization import (
DatasetSerializer,
DataInterchangeUtils,
convert_jsonl
)Use Cases: CAR files, Parquet, JSONL, dataset serialization
What Moved: IPFS multiformats and UnixFS
# ❌ OLD (deprecated)
from ipfs_datasets_py.data_transformation.ipfs_formats import get_cid
from ipfs_datasets_py.data_transformation.unixfs import UnixFS
# ✅ NEW (current)
from ipfs_datasets_py.processors.ipfs.formats import get_cid
from ipfs_datasets_py.processors.ipfs import UnixFSUse Cases: CID generation, multihash, multicodec, UnixFS structures
What Moved: UCAN authentication tokens
# ❌ OLD (deprecated)
from ipfs_datasets_py.data_transformation.ucan import UCAN
# ✅ NEW (current)
from ipfs_datasets_py.processors.auth.ucan import UCANUse Cases: UCAN token generation, verification, delegation
Before:
from ipfs_datasets_py.data_transformation.ipld import IPLDStorage
from ipfs_datasets_py.processors.pdf_processor import PDFProcessor
storage = IPLDStorage()
processor = PDFProcessor(storage=storage)
result = processor.process("document.pdf")After:
from ipfs_datasets_py.processors.storage.ipld import IPLDStorage
from ipfs_datasets_py.processors.pdf_processor import PDFProcessor
storage = IPLDStorage()
processor = PDFProcessor(storage=storage)
result = processor.process("document.pdf")Change: One import line
Before:
from ipfs_datasets_py.data_transformation.serialization import DatasetSerializer
serializer = DatasetSerializer()
car_file = serializer.serialize_to_car(dataset)After:
from ipfs_datasets_py.processors.serialization import DatasetSerializer
serializer = DatasetSerializer()
car_file = serializer.serialize_to_car(dataset)Change: One import line
Before:
from ipfs_datasets_py.data_transformation.ipld import IPLDKnowledgeGraph
kg = IPLDKnowledgeGraph()
kg.add_entity("Person", {"name": "Alice"})
kg.add_relationship("Alice", "knows", "Bob")After:
from ipfs_datasets_py.processors.storage.ipld import IPLDKnowledgeGraph
kg = IPLDKnowledgeGraph()
kg.add_entity("Person", {"name": "Alice"})
kg.add_relationship("Alice", "knows", "Bob")Change: One import line
Use these sed commands (review before running!):
# IPLD Storage
find . -name "*.py" -exec sed -i 's/from ipfs_datasets_py\.data_transformation\.ipld/from ipfs_datasets_py.processors.storage.ipld/g' {} +
# Serialization
find . -name "*.py" -exec sed -i 's/from ipfs_datasets_py\.data_transformation\.serialization/from ipfs_datasets_py.processors.serialization/g' {} +
# IPFS Formats
find . -name "*.py" -exec sed -i 's/from ipfs_datasets_py\.data_transformation\.ipfs_formats/from ipfs_datasets_py.processors.ipfs.formats/g' {} +
# UnixFS
find . -name "*.py" -exec sed -i 's/from ipfs_datasets_py\.data_transformation\.unixfs/from ipfs_datasets_py.processors.ipfs/g' {} +
# UCAN
find . -name "*.py" -exec sed -i 's/from ipfs_datasets_py\.data_transformation\.ucan/from ipfs_datasets_py.processors.auth.ucan/g' {} +For Python 3.10+, imports can also be done via IDE refactoring:
- Find all references to old imports
- Update to new paths
- Run tests to verify
Problem:
ImportError: cannot import name 'IPLDStorage' from 'ipfs_datasets_py.processors.storage.ipld'Solution: Make sure you're using the latest version of ipfs_datasets_py:
pip install --upgrade ipfs_datasets_pyProblem: Still seeing warnings after updating imports.
Solution: Check for indirect imports in your dependencies or internal modules. Run:
python -W error::DeprecationWarning your_script.pyThis will show exactly where the warnings are coming from.
Problem: Getting circular import errors after migration.
Solution: Ensure you're using the new paths consistently. Don't mix old and new imports.
- February 2026: Migration begins, both paths work
- February-August 2026: Deprecation warnings issued for old paths
- August 2026 (v2.0.0): Old paths removed, only new paths work
You have 6 months to update your code.
- Integration Plan:
docs/PROCESSORS_DATA_TRANSFORMATION_INTEGRATION_PLAN_V2.md - Quick Migration:
docs/PROCESSORS_DATA_TRANSFORMATION_QUICK_MIGRATION.md - Architecture:
docs/PROCESSORS_DATA_TRANSFORMATION_ARCHITECTURE.md
- Summary:
docs/DATA_TRANSFORMATION_MIGRATION_SUMMARY.md
- GitHub Issues: Report migration problems as issues
- Pull Requests: Submit PRs for documentation improvements
After migration, verify:
- All imports updated to new paths
- No deprecation warnings when running code
- All tests pass
- No import errors
- Code works as expected
# test_migration.py
"""Test that migration is complete."""
def test_new_imports():
"""Test that new imports work."""
from ipfs_datasets_py.processors.storage.ipld import IPLDStorage
from ipfs_datasets_py.processors.serialization import DatasetSerializer
from ipfs_datasets_py.processors.ipfs.formats import get_cid
from ipfs_datasets_py.processors.auth.ucan import UCAN
print("✅ All new imports work!")
def test_no_old_imports():
"""Ensure code doesn't use old imports."""
import warnings
with warnings.catch_warnings(record=True) as w:
warnings.simplefilter("always", DeprecationWarning)
# Your import statements here
# If any use old paths, warnings will be recorded
if len(w) > 0:
print(f"⚠️ Found {len(w)} deprecation warnings")
for warning in w:
print(f" - {warning.message}")
else:
print("✅ No deprecated imports found!")
if __name__ == "__main__":
test_new_imports()
test_no_old_imports()- ✅ Clearer, more logical organization
- ✅ Easier to find functionality
- ✅ Better IDE auto-completion
- ✅ Consistent with rest of package
- ✅ Reduced code duplication
- ✅ Clearer module responsibilities
- ✅ Easier maintenance
- ✅ Better testing organization
- ✅ More maintainable architecture
- ✅ Easier to extend
- ✅ Better documentation structure
- ✅ Simplified dependencies
- Update Early: Don't wait until the deadline
- Update All at Once: Avoid mixing old and new imports
- Test Thoroughly: Run your full test suite after migration
- Update Documentation: Update any internal docs or examples
- Share Knowledge: Help team members migrate their code
processors/storage/- IPLD storage and knowledge graphsprocessors/serialization/- Format conversion and serializationprocessors/ipfs/- IPFS-specific utilitiesprocessors/auth/- Authentication and authorization
- Multimedia migration (already complete)
- Knowledge graphs refactoring (in progress)
Last Updated: 2026-02-15
Version: 1.0 (v2.0.0 migration)
Status: Active - 6 month migration window