kou commented on code in PR #14561:
URL: https://github.com/apache/arrow/pull/14561#discussion_r1083337552
##########
docker-compose.yml:
##########
@@ -1400,7 +1423,8 @@ services:
ARROW_R_DEV: "true"
volumes: *ubuntu-volumes
command: >
- /bin/bash -c "/arrow/ci/scripts/r_revdepcheck.sh /arrow"
+ /bin/bash -c "
+ /arrow/ci/scripts/r_revdepcheck.sh /arrow"
Review Comment:
Could you revert this?
##########
.dockerignore:
##########
@@ -62,4 +62,5 @@
!rust/datafusion/benches
!rust/integration-testing/Cargo.toml
!go/go.mod
-!go/go.sum
\ No newline at end of file
+!go/go.sum
+!swift/Arrow
Review Comment:
I think that this is needless because this is not used in Dockerfile. We can
access `swift/Arrow` in `docker run` because we mount the source directory to
`/arrow` in `docker run`.
##########
swift/Arrow/Package.swift:
##########
@@ -0,0 +1,23 @@
+// swift-tools-version:5.5
+// The swift-tools-version declares the minimum version of Swift required to
build this package.
Review Comment:
Could you add license header?
##########
ci/docker/linux-apt-swift.dockerfile:
##########
@@ -0,0 +1,44 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+ARG base
+FROM ${base}
+
+ADD swift/ /arrow/swift
+RUN apt-get update -y -q && \
+ apt-get install -y -q \
+ binutils \
+ git \
+ gnupg2 \
+ libc6-dev \
+ libcurl4 \
+ libedit2 \
+ libgcc-9-dev \
+ libpython2.7 \
+ libsqlite3-0 \
+ libstdc++-9-dev \
+ libxml2 \
+ libz3-dev \
+ pkg-config \
+ tzdata \
+ zlib1g-dev \
+ wget && \
+ apt-get clean && \
+ wget
https://download.swift.org/swift-5.7.1-release/ubuntu2004/swift-5.7.1-RELEASE/swift-5.7.1-RELEASE-ubuntu20.04.tar.gz
+
+RUN tar -xvzf swift-5.7.1-RELEASE-ubuntu20.04.tar.gz
+ENV PATH=/swift-5.7.1-RELEASE-ubuntu20.04/usr/bin:$PATH
Review Comment:
```suggestion
ubuntu_version=$(. /etc/os-release && echo ${VERSION_ID}) && \
ubuntu_version_no-dot=$(echo ${ubuntu_version} | sed -e 's/\.//g')
wget
https://download.swift.org/swift-5.7.3-release/ubuntu${ubuntu_version_no_dot}/swift-5.7.3-RELEASE/swift-5.7.3-RELEASE-ubuntu${ubuntu_version}.tar.gz
&& \
tar -xvzf swift-5.7.3-RELEASE-ubuntu${ubuntu_version}.tar.gz && \
rm swift-5.7.3-RELEASE-ubuntu${ubuntu_version}.tar.gz && \
mv swift-5.7.3-RELEASE-ubuntu${ubuntu_version} /swift
ENV PATH=/swift/usr/bin:$PATH
```
##########
swift/Arrow/README.md:
##########
@@ -0,0 +1,49 @@
+<!---
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+
+# Apache Arrow
Review Comment:
How about adding "Swift" such as "Apache Arrow Swift"?
```suggestion
# Apache Arrow Swift
```
##########
docker-compose.yml:
##########
@@ -869,6 +870,28 @@ services:
volumes: *ubuntu-volumes
command: *python-command
+ ubuntu-swift:
+ # Usage:
+ # docker-compose build ubuntu-cpp
+ # docker-compose build ubuntu-swift
+ # docker-compose run --rm ubuntu-swift
+ # Parameters:
+ # ARCH: amd64, arm64v8, ...
+ # UBUNTU: 20.04
+ image: ${REPO}:${ARCH}-ubuntu-${UBUNTU}-swift
+ build:
+ context: .
+ dockerfile: ci/docker/linux-apt-swift.dockerfile
+ args:
+ base: ${REPO}:${ARCH}-ubuntu-${UBUNTU}-cpp
Review Comment:
Do we need to use `ubuntu-cpp` as base image?
Should we use a Swift's Docker image instead?
https://hub.docker.com/_/swift/?tab=tags
##########
.github/workflows/swift.yml:
##########
@@ -0,0 +1,91 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Swift
+
+on:
+ push:
+ paths:
+ - '.github/workflows/swift.yml'
+ - 'ci/docker/**'
+ - 'ci/scripts/swift_*'
+ - 'swift/**'
+ pull_request:
+ paths:
+ - '.github/workflows/swift.yml'
+ - 'ci/docker/**'
+ - 'ci/scripts/swift_*'
+ - 'swift/**'
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{
github.workflow }}
+ cancel-in-progress: true
+
+permissions:
+ contents: read
+
+env:
+ DOCKER_VOLUME_PREFIX: ".docker/"
+
+jobs:
+
+docker:
+ name: ${{ matrix.title }}
+ runs-on: ubuntu-latest
+ if: ${{ !contains(github.event.pull_request.title, 'WIP') }}
+ timeout-minutes: 60
+ strategy:
+ fail-fast: false
+ matrix:
+ name:
+ - swift-5-7-1
+ include:
+ - name: swift-5.7.1
+ cache: conda-swift-5.7.1
+ image: ubuntu-swift
+ title: Swift ubuntu
+ env:
+ UBUNTU: ${{ matrix.ubuntu || 20.04 }}
Review Comment:
It seems that `matrix.ubuntu` isn't defined.
```suggestion
env:
UBUNTU: ${{ matrix.ubuntu || 20.04 }}
```
##########
swift/Arrow/README.md:
##########
@@ -0,0 +1,49 @@
+<!---
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements. See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership. The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied. See the License for the
+ specific language governing permissions and limitations
+ under the License.
+-->
+
+# Apache Arrow
+
+An implementation of Arrow targeting Swift.
+
+# Status
Review Comment:
```suggestion
## Status
```
The following headings should have one more `#` too.
##########
swift/Arrow/Package.swift:
##########
@@ -0,0 +1,23 @@
+// swift-tools-version:5.5
+// The swift-tools-version declares the minimum version of Swift required to
build this package.
+
+import PackageDescription
+
+let package = Package(
Review Comment:
Can we specify package license?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]