Skip to content

Conversation

@hazel-sudz
Copy link
Contributor

@hazel-sudz hazel-sudz commented Apr 10, 2022

it handles the GPG part nicely (should work with the exiting ENV variable). It might take some iterations to get this to work properly as it's hard to test.

testing

I created some dummy GPG creds that should simulate how to CI environment will look like:

# simulate keys that will exist in CI with a dummy keychain that I made
export LONG_ID=5E7939893DB7189A35E0FB7B8D866B98E9211F8F
export PGP_SECRET=`gpg --pinentry-mode loopback --passphrase test --armor --export-secret-keys $LONG_ID`
export PGP_PASSPHRASE="test"
export SONATYPE_PASSWORD="upload should fail"
export SONATYPE_USERNAME="upload should fail"

running ./sbt "ci-release"

It does not fail on GPG signing anymore. I do have some errors from sonatype network requests that look suspicious. I would expect something like "forbidden" on the network requests but I get:

Caused by: java.net.ProtocolException: Server redirected too many  times (20)

edit: I think this is because of malformed creds but I cannot confirm as I don't have real creds

sbt-denver

sbt-publish-ci still uses sbt-denver so the tag/snapshot workflow should still work. I kept my overrides for sbt-denver to disable adding timestamps to the snapshots because that will break tests.

crossScalaVersions := Seq(scalaVersion.value, "2.12.14"),
javacOptions ++= Seq("-source", "1.8", "-target", "1.8"),
doc / javacOptions := Seq("-source", "1.8"),
versionScheme := Some("early-semver"),
Copy link
Contributor Author

@hazel-sudz hazel-sudz Apr 10, 2022

Choose a reason for hiding this comment

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

sbt throws some annoying warnings without this I don't think it does anything functional though

@codecov-commenter
Copy link

codecov-commenter commented Apr 10, 2022

Codecov Report

Merging #1985 (8c1b62f) into develop (e44f2f2) will increase coverage by 2.07%.
The diff coverage is n/a.

Impacted file tree graph

@@              Coverage Diff              @@
##             develop    #1985      +/-   ##
=============================================
+ Coverage      35.74%   37.82%   +2.07%     
- Complexity      1079     1116      +37     
=============================================
  Files            316      316              
  Lines          20941    21117     +176     
  Branches        2850     2924      +74     
=============================================
+ Hits            7485     7987     +502     
+ Misses         12557    12141     -416     
- Partials         899      989      +90     
Impacted Files Coverage Δ
...alization/runtime_helpers/TraversableHelpers.scala 96.00% <0.00%> (-1.34%) ⬇️
...rc/main/scala/com/twitter/scalding/TypedJson.scala 0.00% <0.00%> (ø)
...tter/scalding/db/macros/impl/JdbcFieldSetter.scala 0.00% <0.00%> (ø)
...lding/db/macros/impl/handler/DateTypeHandler.scala 0.00% <0.00%> (ø)
...ding/db/macros/impl/handler/AnnotationHelper.scala 0.00% <0.00%> (ø)
...ing/db/macros/impl/handler/StringTypeHandler.scala 0.00% <0.00%> (ø)
...ng/db/macros/impl/handler/NumericTypeHandler.scala 0.00% <0.00%> (ø)
.../db/macros/impl/ColumnDefinitionProviderImpl.scala 0.00% <0.00%> (ø)
...la/com/twitter/scalding/GeneratedConversions.scala 9.64% <0.00%> (+0.25%) ⬆️
...src/main/scala/com/twitter/scalding/JsonLine.scala 72.97% <0.00%> (+0.75%) ⬆️
... and 50 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update e44f2f2...8c1b62f. Read the comment docs.

@hazel-sudz
Copy link
Contributor Author

@johnynek sorry if this takes a few iterations it is hard to test. But I think this should solve our GPG problem at the least

@hazel-sudz hazel-sudz marked this pull request as ready for review April 10, 2022 01:56
@hazel-sudz
Copy link
Contributor Author

also if it would be possible to run ./sbt "ci-release" locally with real creds loaded for sonatype if might be helpful to debug any issues with a faster feedback loop here instead of constantly making new PRs.

Copy link
Collaborator

@johnynek johnynek left a comment

Choose a reason for hiding this comment

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

Do you know what tags we need to add to get it to pick up the right version?

@johnynek
Copy link
Collaborator

Unfortunately I'm away from my machine now.

@hazel-sudz
Copy link
Contributor Author

hazel-sudz commented Apr 10, 2022

Unfortunately I'm away from my machine now.

let's just merge and see what changes we need after that then. Can't break something that's not working anyways is my logic.

re tags: not sure I will look at the git history locally when I get the chance. Wild guess but the tag might be attributed to a different branch?

@johnynek
Copy link
Collaborator

pushed a tag: https://github.com/twitter/scalding/tree/v0.18.0-RC2

let's see if this works.

@johnynek johnynek merged commit 6434348 into twitter:develop Apr 10, 2022
@johnynek
Copy link
Collaborator

publish action: https://github.com/twitter/scalding/actions/runs/2142743724

@hazel-sudz
Copy link
Contributor Author

it's a miracle!!! https://oss.sonatype.org/content/repositories/snapshots/com/twitter/maple/0.18.0-RC2-1-64343489-SNAPSHOT/maple-0.18.0-RC2-1-64343489-SNAPSHOT-javadoc.jar

going to try these out next week I'm sure something might come up @johnynek

@johnynek
Copy link
Collaborator

It's not a miracle, it's your hard work! Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants