Skip to content

Conversation

@joshka-oai
Copy link
Collaborator

  • add GitHub workflow running cargo-deny on push/PR
  • document cargo-deny allowlist with workspace-dep notes and advisory ignores
  • align workspace crates to inherit version/edition/license for consistent checks

Copy link
Contributor

@chatgpt-codex-connector chatgpt-codex-connector bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Copy link
Collaborator Author

@joshka-oai joshka-oai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Self review notes

@@ -1,7 +1,8 @@
[package]
name = "codex-backend-client"
version = "0.0.0"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm assuming that this is fine to bump - we're not publishing this, so it doesn't really matter what it's set to here

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2024 edition formatting changes

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

2024 edition formatting changes

@@ -1,7 +1,8 @@
[package]
name = "codex-windows-sandbox"
version = "0.1.0"
Copy link
Collaborator Author

@joshka-oai joshka-oai Nov 21, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume this version is not really relevant - please confirm @iceweasel-oai

Comment on lines +72 to +75
ignore = [
{ id = "RUSTSEC-2024-0388", reason = "derivative is unmaintained; pulled in via starlark v0.13.0 used by execpolicy/cli/core; no fixed release yet" },
{ id = "RUSTSEC-2025-0057", reason = "fxhash is unmaintained; pulled in via starlark_map/starlark v0.13.0 used by execpolicy/cli/core; no fixed release yet" },
{ id = "RUSTSEC-2024-0436", reason = "paste is unmaintained; pulled in via ratatui/rmcp/starlark used by tui/execpolicy; no fixed release yet" },
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added

# List of explicitly allowed licenses
# See https://spdx.org/licenses/ for list of possible licenses
# [possible values: any SPDX 3.11 short identifier (+ optional exception)].
allow = [
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added based on the current list of licenses. I also made codex fill in the comments here, mostly to help validate why we'e got each of these in our allow list - these will likely get out of date easily, this is not a big deal IMO)

# https://embarkstudios.github.io/cargo-deny/checks/bans/cfg.html
[bans]
# Lint level for when multiple versions of the same crate are detected
multiple-versions = "warn"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This triggers a bunch. We may consider allow here if that's annoying. Fixing the problems here is out of scope for this change.

Comment on lines +266 to +268
github = [
"nornagon", # ratatui and crossterm forks
]
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly default - called out the actual changes (I also intentionally committed the default so that the changes are visible).

@joshka-oai joshka-oai force-pushed the joshka/cargo-deny branch 5 times, most recently from c6f934c to 8b0559e Compare November 21, 2025 22:21
- add GitHub workflow running cargo-deny on push/PR
- document cargo-deny allowlist with workspace-dep notes and advisory ignores
- align workspace crates to inherit version/edition/license for consistent checks
Copy link
Collaborator Author

@joshka-oai joshka-oai left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

undid a couple of edition (pty and windows-sandbox) as CI shows that changing the edition changes the behavior on these items.

@@ -1,16 +1,13 @@
[package]
edition = "2021"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Intentionally kept as 2021. This affects how the code in this runs

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why? This does not sound like a good idea to have 2024 crates using 2021 on purpose

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changing this for the windows and pty crates changes the behavior of a few things. Formatting changes quite a bit, and tests start to fail. I didn't dig deeply, and agree that we should should fix this, but it's a distinct thing which could need to be rolled back if it causes a problem. 2024 crates can use 2021 crates without a problem, so this is intentionally inconsistent pending a fix on that.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will do a fast follow on this.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

[package]
name = "codex-windows-sandbox"
version = "0.1.0"
edition = "2021"
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Intentionally kept as 2021. This affects how the code in this runs

edition = "2024"
name = "codex-ansi-escape"
version = { workspace = true }
version.workspace = true
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we really need all those? Isn't it possible to do this at the repo level? I fear that people will forget to add them when creating new crates

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pulling the version and edition items into this is not strictly necessary, it's just a small inoffensive cleanup to make it easy to set once and use everywhere. The necessary part is to set a license (as cargo-deny is about checking we only use valid licenses.

Creating a new crate in the repo using cargo new picks up the workspace level options automatically, so this is effectively just doing the same thing that we'd end up there. We can disable the check that is triggered by not specifically having a license on the crates by marking all of our crates as not published and setting an option to ignore private crates, but I think it's worth just leaving this setting at the default and making each crate pull from the workspace manifest.

cargo add foo
[package]
name = "foo"
version.workspace = true
edition.workspace = true
license.workspace = true

[dependencies]

[lints]
workspace = true

If we don't set these license when creating a new package, CI will fail with an error telling the user to add a license for the new crate, which I'd hope would prompt codex to investigate bringing the new crate into the same pattern as the other crates like this.

@joshka-oai joshka-oai merged commit ec49b56 into main Nov 24, 2025
26 checks passed
@joshka-oai joshka-oai deleted the joshka/cargo-deny branch November 24, 2025 20:22
@github-actions github-actions bot locked and limited conversation to collaborators Nov 24, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants