Skip to content

Commit 916c619

Browse files
authored
Merge pull request #15 from mathieu17g/fix-ci-deprecation
Fix CI: Update deprecated GitHub Actions and GeoInterface compatibility
2 parents 43964c3 + 9f2b027 commit 916c619

File tree

3 files changed

+96
-20
lines changed

3 files changed

+96
-20
lines changed

.github/dependabot.yml

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
version: 2
2+
updates:
3+
# Maintain dependencies for GitHub Actions
4+
- package-ecosystem: "github-actions"
5+
directory: "/"
6+
schedule:
7+
interval: "monthly"
8+
open-pull-requests-limit: 10
9+
labels:
10+
- "dependencies"
11+
- "github-actions"
12+
# Groups all github-actions updates into a single PR
13+
groups:
14+
github-actions:
15+
patterns:
16+
- "*"

.github/workflows/CI.yml

Lines changed: 73 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,101 @@
11
name: CI
2+
23
on:
34
push:
4-
branches: [main]
5-
tags: ["*"]
5+
branches:
6+
- main
7+
- master
68
pull_request:
9+
branches:
10+
- main
11+
- master
12+
13+
# Required permissions for modern Julia CI
14+
permissions:
15+
actions: write # Required for julia-actions/cache
16+
contents: read # Basic repository read access
17+
pull-requests: read
18+
statuses: write
19+
720
jobs:
821
test:
922
name: Julia ${{ matrix.version }} - ${{ matrix.os }} - ${{ matrix.arch }} - ${{ github.event_name }}
1023
runs-on: ${{ matrix.os }}
24+
1125
strategy:
1226
fail-fast: false
1327
matrix:
1428
version:
15-
- '1' # automatically expands to the latest stable 1.x release of Julia
16-
- 'nightly'
29+
- 'lts' # Latest LTS release
30+
- '1' # Latest stable 1.x release
31+
- 'pre' # Pre-release (nightly)
1732
os:
1833
- ubuntu-latest
1934
- macOS-latest
2035
- windows-latest
2136
arch:
2237
- x64
23-
- x86
2438
exclude:
39+
# Exclude some combinations to save CI time
2540
- os: macOS-latest
26-
arch: x86
41+
version: 'pre'
42+
- os: windows-latest
43+
version: 'pre'
44+
2745
steps:
28-
- uses: actions/checkout@v2
29-
- uses: julia-actions/setup-julia@v1
46+
# Update to v4 to avoid Node.js deprecation warnings
47+
- uses: actions/checkout@v4
48+
49+
# Update to v2 for modern Julia support
50+
- uses: julia-actions/setup-julia@v2
3051
with:
3152
version: ${{ matrix.version }}
3253
arch: ${{ matrix.arch }}
33-
- uses: actions/cache@v1
34-
env:
35-
cache-name: cache-artifacts
36-
with:
37-
path: ~/.julia/artifacts
38-
key: ${{ runner.os }}-test-${{ env.cache-name }}-${{ hashFiles('**/Project.toml') }}
39-
restore-keys: |
40-
${{ runner.os }}-test-${{ env.cache-name }}-
41-
${{ runner.os }}-test-
42-
${{ runner.os }}-
54+
55+
# Use julia-actions/cache for better Julia-specific caching
56+
- uses: julia-actions/cache@v2
57+
58+
# Build package dependencies
4359
- uses: julia-actions/julia-buildpkg@v1
60+
61+
# Run tests with annotations for better error reporting
4462
- uses: julia-actions/julia-runtest@v1
63+
with:
64+
annotate: true
65+
66+
# Process coverage data
4567
- uses: julia-actions/julia-processcoverage@v1
46-
- uses: codecov/codecov-action@v1
68+
69+
# Upload coverage to Codecov (update to v4)
70+
- uses: codecov/codecov-action@v5
4771
with:
48-
file: lcov.info
72+
files: lcov.info
73+
token: ${{ secrets.CODECOV_TOKEN }}
74+
fail_ci_if_error: false
75+
76+
# Documentation job - commented out until docs/ folder exists
77+
# docs:
78+
# name: Documentation
79+
# runs-on: ubuntu-latest
80+
# permissions:
81+
# contents: write
82+
# pull-requests: read
83+
# statuses: write
84+
# steps:
85+
# - uses: actions/checkout@v4
86+
# - uses: julia-actions/setup-julia@v2
87+
# with:
88+
# version: '1'
89+
# - uses: julia-actions/cache@v2
90+
# - name: Configure doc environment
91+
# shell: julia --color=yes --project=docs {0}
92+
# run: |
93+
# using Pkg
94+
# Pkg.develop(PackageSpec(path=pwd()))
95+
# Pkg.instantiate()
96+
# - name: Build and deploy documentation
97+
# env:
98+
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
99+
# DOCUMENTER_KEY: ${{ secrets.DOCUMENTER_KEY }}
100+
# run: |
101+
# julia --color=yes --project=docs docs/make.jl

src/KML.jl

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -726,4 +726,11 @@ for T in vcat(all_concrete_subtypes(KMLElement), all_abstract_subtypes(Object))
726726
end
727727
end
728728

729+
# Add this type-level implementation for GeoInterface v1.x
730+
GeoInterface.isgeometry(::Type{<:Geometry}) = true
731+
732+
# Add the missing ncoord implementations for GeoInterface v1.x
733+
GeoInterface.ncoord(::GeoInterface.LineStringTrait, ls::LineString) = 2
734+
GeoInterface.ncoord(::GeoInterface.LinearRingTrait, lr::LinearRing) = 2
735+
729736
end #module

0 commit comments

Comments
 (0)