{"id":1334,"library":"arro3-core","title":"Arro3 Core","description":"Arro3-core provides the Pythonic foundation for managing, processing, and generating geospatial data with a focus on ease of use and interoperability. It defines a standardized schema for geospatial datasets and provides utilities for reading and writing them. The current version is 0.8.0, and being a pre-1.0 library, its API is subject to change.","status":"active","version":"0.8.0","language":"en","source_language":"en","source_url":"https://github.com/Arro3/arro3-core","tags":["geospatial","data-management","schema","pydantic","serialization"],"install":[{"cmd":"pip install arro3-core","lang":"bash","label":"Install stable version"}],"dependencies":[{"reason":"Used for data validation and schema definition. Requires Pydantic v2.","package":"pydantic","optional":false},{"reason":"Used for efficient serialization/deserialization.","package":"msgpack","optional":false},{"reason":"Used for fast JSON serialization/deserialization.","package":"orjson","optional":false},{"reason":"Used for compression/decompression of Arro files.","package":"zstandard","optional":false}],"imports":[{"note":"The core Arro schema object resides in the `schema.core` module.","symbol":"Arro","correct":"from arro3.schema.core import Arro"},{"note":"Utilities for reading and writing Arro files are in the `core` module.","symbol":"ArroFile","correct":"from arro3.core import ArroFile"}],"quickstart":{"code":"import os\nfrom arro3.core import ArroFile\nfrom arro3.schema.core import Arro\n\n# Define a simple Arro object structure\ndata = {\n    \"id\": \"my-dataset-id\",\n    \"name\": \"My Test Dataset\",\n    \"description\": \"A minimal example Arro dataset.\",\n    \"bbox\": [0.0, 0.0, 1.0, 1.0], # minx, miny, maxx, maxy\n    \"spatial_ref_sys\": {\"epsg\": 4326}, # Example SRS\n    \"assets\": {} # Assets dict required, can be empty\n}\n\ntry:\n    # 1. Create an Arro object from a dictionary\n    my_arro = Arro(**data)\n    print(f\"Created Arro object with ID: {my_arro.id}\")\n\n    # 2. Define a temporary file path for demonstration\n    temp_file_path = \"temp_arro_dataset.json\"\n\n    # 3. Save the Arro object to a file\n    ArroFile.write(my_arro, temp_file_path)\n    print(f\"Arro object saved to {temp_file_path}\")\n\n    # 4. Load the Arro object from the file\n    loaded_arro = ArroFile.read(temp_file_path)\n    print(f\"Loaded Arro object with ID: {loaded_arro.id}\")\n    assert my_arro.id == loaded_arro.id\n    print(\"Verification successful: Loaded ID matches original ID.\")\n\nexcept Exception as e:\n    print(f\"An error occurred: {e}\")\nfinally:\n    # Clean up the temporary file\n    if os.path.exists(temp_file_path):\n        os.remove(temp_file_path)\n        print(f\"Cleaned up temporary file: {temp_file_path}\")\n","lang":"python","description":"This quickstart demonstrates how to create an Arro object from a dictionary, save it to a local file using `ArroFile.write()`, and then load it back using `ArroFile.read()`."},"warnings":[{"fix":"Always pin to a specific patch version (e.g., `arro3-core==0.8.0`) and review release notes carefully when upgrading. Test thoroughly after any upgrade.","message":"Arro3-core is currently in its 0.x.x release series, meaning the API is not yet stable. Breaking changes to classes, methods, and schema definitions can occur between minor versions (e.g., 0.8.0 to 0.9.0).","severity":"breaking","affected_versions":"<1.0.0"},{"fix":"Ensure your project's environment satisfies the `pydantic>=2.0.0,<3.0.0` dependency. If other libraries require Pydantic v1, consider isolating `arro3-core` in a separate virtual environment or re-evaluating compatibility.","message":"The `Arro` schema relies on Pydantic v2. Using `arro3-core` with Pydantic v1 will lead to import errors or unexpected behavior due to API differences.","severity":"gotcha","affected_versions":"All versions"},{"fix":"It is recommended to use the same `arro3-core` version for writing and reading files. If sharing files, ensure all consumers are aware of and use the expected library version. Regularly back up data if schema changes are anticipated.","message":"The internal file format (e.g., for `.json` or `.json.gz` files written by `ArroFile`) might evolve. Files written with an older version of `arro3-core` might not be readable by newer versions, or vice-versa, especially during the 0.x.x development phase.","severity":"gotcha","affected_versions":"<1.0.0"}],"env_vars":null,"last_verified":"2026-04-09T00:00:00.000Z","next_check":"2026-07-08T00:00:00.000Z"}