Skip to content

Commit 2043fd0

Browse files
committed
Merge branch 'main' into gpeacock/load_settings
2 parents 91d2334 + 3e5205c commit 2043fd0

18 files changed

+549
-452
lines changed

.github/workflows/build.yml

Lines changed: 16 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,11 @@ name: Build
22

33
on:
44
pull_request:
5+
types:
6+
- opened
7+
- reopened
8+
- synchronize
9+
- labeled
510
push:
611
branches:
712
- main
@@ -233,9 +238,9 @@ jobs:
233238
apt update -y && apt-get install -y libssl-dev openssl pkg-config
234239
fi
235240
- name: Upload wheels
236-
uses: actions/upload-artifact@v3
241+
uses: actions/upload-artifact@v4
237242
with:
238-
name: wheels
243+
name: wheels-${{ matrix.target }}
239244
path: dist
240245

241246
windows:
@@ -266,9 +271,9 @@ jobs:
266271
args: --release --out dist --find-interpreter
267272
sccache: 'true'
268273
- name: Upload wheels
269-
uses: actions/upload-artifact@v3
274+
uses: actions/upload-artifact@v4
270275
with:
271-
name: wheels
276+
name: wheels-${{ matrix.target }}
272277
path: dist
273278

274279
macos_x86:
@@ -295,9 +300,9 @@ jobs:
295300
args: --release --out dist --find-interpreter
296301
sccache: 'true'
297302
- name: Upload wheels
298-
uses: actions/upload-artifact@v3
303+
uses: actions/upload-artifact@v4
299304
with:
300-
name: wheels
305+
name: wheels-mac-x86_64
301306
path: dist
302307

303308
macos_aarch64:
@@ -324,9 +329,9 @@ jobs:
324329
args: --release --out dist --find-interpreter
325330
sccache: 'true'
326331
- name: Upload wheels
327-
uses: actions/upload-artifact@v3
332+
uses: actions/upload-artifact@v4
328333
with:
329-
name: wheels
334+
name: wheels-mac-aarch64
330335
path: dist
331336

332337
sdist:
@@ -347,7 +352,7 @@ jobs:
347352
command: sdist
348353
args: --out dist
349354
- name: Upload sdist
350-
uses: actions/upload-artifact@v3
355+
uses: actions/upload-artifact@v4
351356
with:
352357
name: wheels
353358
path: dist
@@ -361,8 +366,9 @@ jobs:
361366
environment: Publish
362367
needs: [linux, windows, macos_x86, macos_aarch64, sdist]
363368
steps:
364-
- uses: actions/download-artifact@v3
369+
- uses: actions/download-artifact@v4
365370
with:
371+
pattern: wheels-*
366372
name: wheels
367373
- name: Publish to PyPI
368374
uses: PyO3/maturin-action@v1
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Closing ticket
2+
on:
3+
issues:
4+
types: [closed]
5+
jobs:
6+
label_issues:
7+
runs-on: ubuntu-latest
8+
permissions:
9+
issues: write
10+
steps:
11+
- run: 'gh issue edit "$NUMBER" --add-label "status: done" --remove-label "status: wip,status: todo,status: in progress,status: in test,status: not prioritized,status: blocked,status: api review,status: code review,status: design review,status: code complete,status: ready"'
12+
env:
13+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
14+
GH_REPO: ${{ github.repository }}
15+
NUMBER: ${{ github.event.issue.number }}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Labeling ticket "Done"
2+
on:
3+
issues:
4+
types: [labeled]
5+
jobs:
6+
label_issues:
7+
runs-on: ubuntu-latest
8+
if: |
9+
contains(github.event.issue.labels.*.name, 'status: done')
10+
permissions:
11+
issues: write
12+
steps:
13+
- run: 'gh issue close "$NUMBER"'
14+
env:
15+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16+
GH_REPO: ${{ github.repository }}
17+
NUMBER: ${{ github.event.issue.number }}
Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
name: Labeling ticket "To Do"
2+
on:
3+
issues:
4+
types: [labeled]
5+
jobs:
6+
label_issues:
7+
runs-on: ubuntu-latest
8+
if: |
9+
!contains(github.event.issue.labels.*.name, 'status: done')
10+
permissions:
11+
issues: write
12+
steps:
13+
- run: 'gh issue reopen "$NUMBER"'
14+
env:
15+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
16+
GH_REPO: ${{ github.repository }}
17+
NUMBER: ${{ github.event.issue.number }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: Reopening ticket
2+
on:
3+
issues:
4+
types: [reopened]
5+
jobs:
6+
label_issues:
7+
runs-on: ubuntu-latest
8+
permissions:
9+
issues: write
10+
steps:
11+
- run: 'gh issue edit "$NUMBER" --add-label "status: todo" --remove-label "status: wip,status: done,status: in progress,status: in test,status: not prioritized,status: blocked,status: api review,status: code review,status: design review,status: code complete,status: ready"'
12+
env:
13+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
14+
GH_REPO: ${{ github.repository }}
15+
NUMBER: ${{ github.event.issue.number }}

CONTRIBUTING.md

Lines changed: 31 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ Before you start, we ask that you understand the following guidelines.
66

77
## Code of conduct
88

9-
This project adheres to the Adobe [code of conduct](../CODE_OF_CONDUCT.md). By participating,
9+
This project adheres to the Adobe [code of conduct](CODE_OF_CONDUCT.md). By participating,
1010
you are expected to uphold this code. Please report unacceptable behavior to
1111
1212

@@ -18,12 +18,10 @@ consensus around project direction and issue solutions within issue threads
1818

1919
### Current areas of work
2020

21-
The Adobe CAI team has been using this crate as the foundation of Adobe's Content Authenticity Initiative-related products and services since late 2020. As we shift toward making this crate available for open usage, we're aware that there is quite a bit of work to do to create what we'd feel comfortable calling a 1.0 release. We've decided to err on the side of releasing earlier so that people can experiment with it and give us feedback.
22-
23-
We expect to do work on a number of areas in the next few months while we remain in prerelease (0.x) versions. Some broad categories of work (and thus things you might expect to change) are:
21+
Some broad categories of work (and thus things you might expect to change) are:
2422

2523
* We'll be reviewing and refining our APIs for ease of use and comprehension. We'd appreciate feedback on areas that you find confusing or unnecessarily difficult.
26-
* We'll also be reviewing our APIs for compliance with Rust community best practices. There are some areas (for example, use of public fields and how we take ownership vs references) where we know some work is required.
24+
* We'll also be reviewing our APIs for compliance with best practices.
2725
* Our documentation is incomplete. We'll be working on refining the documentation.
2826
* Our testing infrastructure is incomplete. We'll be working on improving test coverage, memory efficiency, and performance benchmarks.
2927

@@ -61,11 +59,35 @@ This will give us an opportunity to discuss API design and avoid duplicate effor
6159

6260
### Pull request titles
6361

64-
The build process automatically adds a pull request (PR) to the [CHANGELOG](CHANGELOG.md) unless the title of the PR begins with `(IGNORE)`. Start PR titles with `(IGNORE)` for minor documentation updates and other trivial fixes that you want to specifically exclude from the CHANGELOG.
62+
Titles of pull requests that target a long-lived branch such as _main_ or a release-specific branch should follow [conventional commits](https://www.conventionalcommits.org/en/v1.0.0/#specification). This means that the first word of the pull request title should be one of the following:
63+
64+
* `build`
65+
* `chore`
66+
* `ci`
67+
* `docs`
68+
* `feat`
69+
* `fix`
70+
* `perf`
71+
* `refactor`
72+
* `revert`
73+
* `style`
74+
* `test`
75+
76+
Optionally, but preferred, a scope can be added in parentheses after the type. The scope should be the name of the module or component that the commit affects. For example, `feat(api): Introduce a new API to validate 1.0 claims`.
77+
78+
If more detail is warranted, add a blank line and then continue with sentences (these sentences should be punctuated as such) and paragraphs as needed to provide that detail. There is no need to word-wrap this message.
79+
80+
For example:
81+
82+
```text
83+
feat(api): Introduce a new API to validate 1.0 claims
84+
85+
Repurpose existing v2 API for 0.8 compatibility (read: no validation) mode.
86+
```
87+
88+
The conventional commit message requirement does not apply to individual commits within a pull request, provided that those commits will be squashed when the PR is merged and the resulting squash commit does follow the conventional commit requirement. This may require the person merging the PR to verify the commit message syntax when performing the squash merge.
6589

66-
Additionally, the build process takes specific actions if the title of a PR begins with certain special strings:
67-
- `(MINOR)`: Increments the minor version, per [semantic versioning](https://semver.org/) convention. **IMPORTANT:** This flag should be used for any API change that breaks compatibility with previous releases while this crate is in prerelease (version 0.x) status.
68-
- `(MAJOR)`: Increments the major version number, per [semantic versioning](https://semver.org/) convention.
90+
TIP: For single-commit PRs, ensure the commit message conforms to the conventional commit requirement, since by default that will also be the title of the PR.
6991

7092
## From contributor to committer
7193

Cargo.toml

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "c2pa-python"
3-
version = "0.6.2"
3+
version = "0.7.1"
44
edition = "2021"
55
authors = ["Gavin Peacock <[email protected]"]
66

@@ -12,11 +12,7 @@ crate-type = ["lib", "cdylib"]
1212
normal = ["openssl-src"]
1313

1414
[dependencies]
15-
c2pa = {version = "0.38.0", features = ["unstable_api", "file_io", "openssl", "pdf", "fetch_remote_manifests"]}
16-
pem = "3.0.3"
17-
serde = { version = "1.0.197", features = ["derive"] }
18-
serde_derive = "1.0"
19-
serde_json = "1.0"
15+
c2pa = { version = "0.46.0", features = ["file_io", "openssl", "pdf", "fetch_remote_manifests"]}
2016
thiserror = "1.0.49"
2117
uniffi = "0.28.2"
2218
openssl-src = "=300.3.1" # Required for openssl-sys

0 commit comments

Comments
 (0)