Skip to content

Commit 461542d

Browse files
jhammanclaude
andcommitted
Fix Documenter.jl build errors: docstrings, @ref links, and missing docs
- Add docstrings to get_attributes and set_attributes! for both ZarrsArray and ZarrsGroup - Fix broken @ref links: "Icechunk documentation" -> "Icechunk Integration" in getting_started.md and cloud.md - Add Storage and Internals sections to api.md to include all documented symbols (ZarrsStorageHandle, ZarrsArrayHandle, ZarrsGroupHandle, Base.keys, Base.getindex, create_storage, julia_shape, zarrs_subset, build_v3_metadata, build_v2_metadata, numpy_dtype_str) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent a8c16a6 commit 461542d

5 files changed

Lines changed: 43 additions & 2 deletions

File tree

docs/src/api.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ zinfo
1515
```@docs
1616
ZarrsGroup
1717
zgroup
18+
Base.keys(::ZarrsGroup)
19+
Base.getindex(::ZarrsGroup, ::AbstractString)
1820
```
1921

2022
## Attributes
@@ -72,3 +74,22 @@ Zarrs.Icechunk.delete_tag
7274
Zarrs.Icechunk.lookup_branch
7375
Zarrs.Icechunk.lookup_tag
7476
```
77+
78+
## Storage
79+
80+
```@docs
81+
Zarrs.create_storage
82+
Zarrs.ZarrsStorageHandle
83+
Zarrs.ZarrsArrayHandle
84+
Zarrs.ZarrsGroupHandle
85+
```
86+
87+
## Internals
88+
89+
```@docs
90+
Zarrs.julia_shape
91+
Zarrs.zarrs_subset
92+
Zarrs.build_v3_metadata
93+
Zarrs.build_v2_metadata
94+
Zarrs.numpy_dtype_str
95+
```

docs/src/cloud.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ subset = z[1:10, 1:10]
1818
## Icechunk (S3, GCS, Azure)
1919

2020
For cloud storage with versioning, use the Icechunk integration. See the
21-
[Icechunk documentation](@ref) for full details.
21+
[Icechunk Integration](@ref) for full details.
2222

2323
```julia
2424
using Zarrs

docs/src/getting_started.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -132,7 +132,7 @@ session = writable_session(repo, "main")
132132
snapshot_id = commit(session, "initial data")
133133
```
134134

135-
See the [Icechunk documentation](@ref) for full details on storage backends,
135+
See the [Icechunk Integration](@ref) page for full details on storage backends,
136136
credentials, branches, and tags.
137137

138138
## DiskArrays Integration

src/array.jl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -250,11 +250,21 @@ end
250250
# Attributes
251251
# ---------------------------------------------------------------------------
252252

253+
"""
254+
get_attributes(z::ZarrsArray) -> Dict{String,Any}
255+
256+
Return the array's user attributes as a dictionary.
257+
"""
253258
function get_attributes(z::ZarrsArray)
254259
json_str = LibZarrs.zarrs_array_get_attributes(z.handle.ptr)
255260
return JSON.parse(json_str)
256261
end
257262

263+
"""
264+
set_attributes!(z::ZarrsArray, attrs::Dict)
265+
266+
Replace the array's user attributes and persist to storage.
267+
"""
258268
function set_attributes!(z::ZarrsArray, attrs::Dict)
259269
LibZarrs.zarrs_array_set_attributes(z.handle.ptr, JSON.json(attrs))
260270
LibZarrs.zarrs_array_store_metadata(z.handle.ptr)

src/group.jl

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -100,11 +100,21 @@ end
100100
# Group attributes
101101
# ---------------------------------------------------------------------------
102102

103+
"""
104+
get_attributes(g::ZarrsGroup) -> Dict{String,Any}
105+
106+
Return the group's user attributes as a dictionary.
107+
"""
103108
function get_attributes(g::ZarrsGroup)
104109
json_str = LibZarrs.zarrs_group_get_attributes(g.handle.ptr)
105110
return JSON.parse(json_str)
106111
end
107112

113+
"""
114+
set_attributes!(g::ZarrsGroup, attrs::Dict)
115+
116+
Replace the group's user attributes and persist to storage.
117+
"""
108118
function set_attributes!(g::ZarrsGroup, attrs::Dict)
109119
LibZarrs.zarrs_group_set_attributes(g.handle.ptr, JSON.json(attrs))
110120
LibZarrs.zarrs_group_store_metadata(g.handle.ptr)

0 commit comments

Comments
 (0)