Skip to content

Commit 0f0be9e

Browse files
committed
update proto-lens
1 parent 2be2501 commit 0f0be9e

File tree

104 files changed

+10067
-4190
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

104 files changed

+10067
-4190
lines changed
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
# Please see the documentation for all configuration options:
2+
# https://docs.github.com/code-security/dependabot/dependabot-version-updates/configuration-options-for-the-dependabot.yml-file
3+
4+
version: 2
5+
updates:
6+
- package-ecosystem: "github-actions"
7+
directory: "/"
8+
schedule:
9+
interval: "monthly"
10+
groups:
11+
github-actions:
12+
applies-to: version-updates
13+
patterns:
14+
- "*"
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
on:
2+
- push
3+
- pull_request
4+
name: cabal build
5+
jobs:
6+
runhaskell:
7+
name: cabal test
8+
runs-on: ubuntu-latest
9+
strategy:
10+
matrix:
11+
version:
12+
- ghc: 9.10.1
13+
cabal: 3.12.1.0
14+
steps:
15+
- uses: actions/[email protected]
16+
with:
17+
submodules: true
18+
- uses: haskell-actions/setup@64445b6b5dd545faf5f8e2acee8253eb5c2b29aa # v2.7.11
19+
with:
20+
ghc-version: ${{ matrix.version.ghc }}
21+
cabal-version: ${{ matrix.version.cabal }}
22+
- run: cabal build --dependencies-only --project-file ghc${{ matrix.version.ghc }}.cabal.project all
23+
- run: cabal build --project-file ghc${{ matrix.version.ghc }}.cabal.project all
24+
- run: cabal test --project-file ghc${{ matrix.version.ghc }}.cabal.project all
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: HLint
2+
on: [push, pull_request]
3+
4+
jobs:
5+
hlint:
6+
runs-on: ubuntu-latest
7+
permissions:
8+
# Needed to upload results to GitHub code scanning.
9+
security-events: write
10+
steps:
11+
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
12+
- uses: haskell-actions/hlint-scan@abd8bbb55afd1ec2c86bc28e081c1ca49037dd9c # v1.3.0

pub/proto-lens/.github/workflows/stack-ci.yml

Lines changed: 13 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414

1515
name: Stack CI
1616

17+
permissions: read-all
18+
1719
on:
1820
push:
1921
branches:
@@ -40,7 +42,7 @@ jobs:
4042

4143
steps:
4244
- name: Checkout
43-
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
45+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
4446
with:
4547
submodules: true
4648

@@ -49,7 +51,7 @@ jobs:
4951
run: |
5052
cat matrix.yaml
5153
CI_BUILDS=$(yq eval -o json -I 0 matrix.yaml)
52-
echo "::set-output name=ci-builds::$CI_BUILDS"
54+
echo "ci-builds=$CI_BUILDS" >> $GITHUB_OUTPUT
5355
5456
build:
5557
name: Build and Test
@@ -70,20 +72,21 @@ jobs:
7072

7173
steps:
7274
- name: Checkout
73-
uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f
75+
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
7476
with:
7577
submodules: true
7678

7779
# Installs the recent protoc, for now unpinned to gain some experience
7880
- name: Install Protoc
79-
uses: arduino/setup-protoc@v1
81+
uses: arduino/setup-protoc@v3
8082
with:
81-
version: '3.x'
83+
version: '28.x'
84+
repo-token: ${{ secrets.GITHUB_TOKEN }}
8285

8386
# Install Stack without GHC first, so we have an opportunity to cache the
8487
# Pantry package index.
8588
- name: Install Stack
86-
uses: haskell/actions/setup@eb3073b623d53d0cdd38e4d4c2408f14e3fc71c5
89+
uses: haskell-actions/setup@64445b6b5dd545faf5f8e2acee8253eb5c2b29aa # v2.7.11
8790
id: setup-stack
8891
with:
8992
enable-stack: true
@@ -100,7 +103,7 @@ jobs:
100103
# out-of-date one, so we benefit from using restore-keys to bootstrap it
101104
# with a previous index.
102105
- name: Cache Pantry Package Index
103-
uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353
106+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684
104107
with:
105108
# Everything except the decompressed Hackage index tarball. Why is
106109
# that even materialized to disk?
@@ -117,7 +120,7 @@ jobs:
117120
# GHC takes a while to gunzip and configure; let's try caching it
118121
# pre-configured with zstd.
119122
- name: Cache Configured GHC
120-
uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353
123+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684
121124
with:
122125
# Omit the tarball itself; it'll double the cache size assuming
123126
# similar compression ratios.
@@ -142,7 +145,7 @@ jobs:
142145
# other builds with the same GHC version to benefit from any packages in
143146
# common between two lockfiles.
144147
- name: Cache Dependencies
145-
uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353
148+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684
146149
with:
147150
# The Stack global work directory, minus GHC installations (already
148151
# extracted from a tarball) and the Pantry package index (already
@@ -178,7 +181,7 @@ jobs:
178181
# Cache pre-built modules for incremental builds, making sure to keep
179182
# builds with different dependencies separate.
180183
- name: Cache Modules
181-
uses: actions/cache@c64c572235d810460d0d6876e9c705ad5002b353
184+
uses: actions/cache@5a3ec84eff668545956fd18022155c47e93e2684
182185
with:
183186
path: "**/.stack-work"
184187
key: |

pub/proto-lens/.gitignore

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,4 @@ dist/
55
# For "cabal sandbox"
66
.cabal-sandbox
77
cabal.sandbox.config
8-
dist-newstyle/
9-
result
8+
dist-newstyle

pub/proto-lens/.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
[submodule "google/protobuf"]
22
path = google/protobuf
3-
url = https://github.com/google/protobuf
3+
url = https://github.com/protocolbuffers/protobuf

pub/proto-lens/.hlint.yaml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
# HLint configuration file
2+
# https://github.com/ndmitchell/hlint
3+
##########################
4+
5+
6+
# Ignore generated files.
7+
- ignore: {within: Proto.Google.Protobuf.Descriptor}
8+
- ignore: {within: Proto.Google.Protobuf.Descriptor_Fields}
9+
- ignore: {within: Proto.Google.Protobuf.Compiler.Plugin}
10+
- ignore: {within: Proto.Google.Protobuf.Compiler.Plugin_Fields}
11+
12+
13+
# Warnings currently triggered by existing code.
14+
- ignore: {name: "Avoid lambda"} # 1 hint
15+
- ignore: {name: "Eta reduce"} # 1 hint
16+
- ignore: {name: "Use <$"} # 1 hint
17+
- ignore: {name: "Use <$>"} # 1 hint
18+
- ignore: {name: "Use ?~"} # 5 hints
19+
- ignore: {name: "Use fmap"} # 10 hints
20+
- ignore: {name: "Use lambda-case"} # 3 hints

pub/proto-lens/.travis.yml

Lines changed: 0 additions & 76 deletions
This file was deleted.

pub/proto-lens/README.md

Lines changed: 11 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# proto-lens
22

3-
[![Build Status](https://travis-ci.org/google/proto-lens.svg?branch=master)](https://travis-ci.org/google/proto-lens)
3+
[![Cabal build](https://github.com/google/proto-lens/actions/workflows/cabal-ci.yml/badge.svg)](https://github.com/google/proto-lens/actions/workflows/cabal-ci.yml)
44

55
The proto-lens library provides an API for protocol buffers using modern Haskell
66
language and library patterns. Specifically, it provides:
@@ -23,7 +23,7 @@ There is also a [reference document](docs/types.md) showing the protobuf scalar
2323
First, install the "protoc" binary somewhere in your PATH. You can get it by
2424
following [these instructions](docs/installing-protoc.md).
2525

26-
This project requires at least `protoc` version 3.12.0.
26+
This project requires at least `protoc` version 28.0.
2727

2828
## Building from HEAD
2929

@@ -118,6 +118,15 @@ will generate the haskell files `Proto/Project/{Foo,Bar}.hs`.
118118
- Unknown proto2 enum values cause a decoding error, instead of being preserved
119119
round-trip.
120120

121+
## Protobuf Editions
122+
123+
- `features.utf8_validation = NONE` does not disable UTF-8 validation.
124+
125+
- If more than one field sharing the same message type are
126+
in a single message type, and if one of the fields has
127+
`features.message_encoding = DELIMITED`, then all of these
128+
fields will use `DELIMITED` encoding.
129+
121130
# Troubleshooting
122131

123132
## Rebuilding

pub/proto-lens/discrimination-ieee754/discrimination-ieee754.cabal

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
cabal-version: 1.12
22

3-
-- This file has been generated from package.yaml by hpack version 0.34.4.
3+
-- This file has been generated from package.yaml by hpack version 0.37.0.
44
--
55
-- see: https://github.com/sol/hpack
66

77
name: discrimination-ieee754
8-
version: 0.1.0.1
8+
version: 0.1.0.5
99
synopsis: Discrimination of floating-point numbers via their IEEE754 representation.
1010
description: Support for sorting/grouping by floating-point numbers. Uses the technique described by http://stereopsis.com/radix.html.
1111
category: Data
@@ -31,10 +31,10 @@ library
3131
hs-source-dirs:
3232
src
3333
build-depends:
34-
base >=4.10 && <4.16
34+
base >=4.10 && <4.21
3535
, contravariant >=1.3 && <1.6
3636
, data-binary-ieee754 ==0.4.*
37-
, discrimination >=0.3 && <0.5
37+
, discrimination >=0.3 && <0.6
3838
default-language: Haskell2010
3939

4040
test-suite test
@@ -46,10 +46,10 @@ test-suite test
4646
test
4747
build-depends:
4848
QuickCheck
49-
, base >=4.10 && <4.16
49+
, base >=4.10 && <4.21
5050
, contravariant >=1.3 && <1.6
5151
, data-binary-ieee754 ==0.4.*
52-
, discrimination >=0.3 && <0.5
52+
, discrimination >=0.3 && <0.6
5353
, discrimination-ieee754
5454
, test-framework
5555
, test-framework-quickcheck2 ==0.3.*

0 commit comments

Comments
 (0)