Skip to content

Commit aa20ef8

Browse files
committed
0.6.7
1 parent be075f2 commit aa20ef8

File tree

2 files changed

+21
-17
lines changed

2 files changed

+21
-17
lines changed

build.sc

+4-4
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ import de.tobiasroeser.mill.vcs.version.VcsVersion
66

77
val dottyVersion = Option(sys.props("dottyVersion"))
88

9-
object requests extends Cross[RequestsModule]((List("2.12.6", "2.13.0", "2.11.12", "3.0.0-RC1") ++ dottyVersion): _*)
9+
object requests extends Cross[RequestsModule]((List("2.12.13", "2.13.5", "2.11.12", "3.0.0-RC2") ++ dottyVersion): _*)
1010
class RequestsModule(val crossScalaVersion: String) extends CrossScalaModule with PublishModule {
1111
def publishVersion = VcsVersion.vcsState().format()
1212
def artifactName = "requests"
@@ -21,12 +21,12 @@ class RequestsModule(val crossScalaVersion: String) extends CrossScalaModule wit
2121
)
2222
)
2323
def ivyDeps = Agg(
24-
ivy"com.lihaoyi::geny::0.6.7"
24+
ivy"com.lihaoyi::geny::0.6.8"
2525
)
2626
object test extends Tests{
2727
def ivyDeps = Agg(
28-
ivy"com.lihaoyi::utest::0.7.7",
29-
ivy"com.lihaoyi::ujson::1.3.9"
28+
ivy"com.lihaoyi::utest::0.7.8",
29+
ivy"com.lihaoyi::ujson::1.3.11"
3030
)
3131
def testFrameworks = Seq("utest.runner.Framework")
3232
}

readme.md

+17-13
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ If you use Requests-Scala and like it, you will probably enjoy the following boo
1212
- [*Hands-on Scala Programming*](https://www.handsonscala.com/)
1313

1414
*Hands-on Scala* has uses Requests-Scala extensively throughout the book, and has
15-
the entirety of *Chapter 12: Working with HTTP APIs* dedicated to
15+
the entirety of *Chapter 12: Working with HTTP APIs* dedicated to
1616
the library. *Hands-on Scala* is a great way to level up your skills in Scala
1717
in general and Requests-Scala in particular.
1818

@@ -87,7 +87,7 @@ val r = requests.options("http://httpbin.org/get")
8787

8888
```scala
8989
val r = requests.get(
90-
"http://httpbin.org/get",
90+
"http://httpbin.org/get",
9191
params = Map("key1" -> "value1", "key2" -> "value2")
9292
)
9393
```
@@ -191,9 +191,9 @@ too big to fit in memory, while still benefiting from most of Requests' friendly
191191

192192
## Handling JSON
193193

194-
Requests does not provide any built-in JSON support, but you can easily use a
195-
third-party JSON library to work with it. This example shows how to use
196-
[uJson](http://www.lihaoyi.com/upickle/) talk to a HTTP endpoint that requires a
194+
Requests does not provide any built-in JSON support, but you can easily use a
195+
third-party JSON library to work with it. This example shows how to use
196+
[uJson](http://www.lihaoyi.com/upickle/) talk to a HTTP endpoint that requires a
197197
JSON-formatted body, either using `upickle.default.stream`:
198198

199199
```scala
@@ -243,9 +243,9 @@ val r = requests.post(
243243
data = requests.MultiPart(
244244
requests.MultiItem("name", new java.io.File("build.sc"), "file.txt"),
245245
// you can upload strings, and file name is optional
246-
requests.MultiItem("name2", "Hello"),
246+
requests.MultiItem("name2", "Hello"),
247247
// bytes arrays are ok too
248-
requests.MultiItem("name3", Array[Byte](1, 2, 3, 4))
248+
requests.MultiItem("name3", Array[Byte](1, 2, 3, 4))
249249
)
250250
)
251251
```
@@ -280,7 +280,7 @@ requests.get("https://httpbin.org/delay/1", readTimeout = 10)
280280
// TimeoutException
281281

282282
requests.get("https://httpbin.org/delay/1", readTimeout = 1500)
283-
// ok
283+
// ok
284284

285285
requests.get("https://httpbin.org/delay/3", readTimeout = 1500)
286286
// TimeoutException
@@ -490,7 +490,7 @@ headers, cookies or other things:
490490

491491
```scala
492492
val s = requests.Session(
493-
headers = Map("x-special-header" -> "omg"),
493+
headers = Map("x-special-header" -> "omg"),
494494
cookieValues = Map("cookie" -> "vanilla")
495495
)
496496

@@ -531,7 +531,7 @@ common Scala HTTP clients:
531531
```scala
532532
// Requests-Scala
533533
val r = requests.get(
534-
"https://api.github.com/search/repositories",
534+
"https://api.github.com/search/repositories",
535535
params = Map("q" -> "http language:scala", "sort" -> "stars")
536536
)
537537

@@ -619,12 +619,12 @@ val query = "http language:scala"
619619
// the `query` parameter is automatically url-encoded
620620
// `sort` is removed, as the value is not defined
621621
val request = sttp.get(uri"https://api.github.com/search/repositories?q=$query&sort=$sort")
622-
622+
623623
implicit val backend = HttpURLConnectionBackend()
624624
val response = request.send()
625625

626-
// response.unsafeBody: by default read into a String
627-
println(response.unsafeBody)
626+
// response.unsafeBody: by default read into a String
627+
println(response.unsafeBody)
628628
```
629629
```scala
630630
// Dispatch
@@ -656,6 +656,10 @@ codebase or project!
656656

657657
## Changelog
658658

659+
### 0.6.7
660+
661+
- Add support for Scala 3.0.0-RC2
662+
659663
### 0.6.5
660664

661665
- `requests.Response` now implements the `geny.Readable` interface, and can be

0 commit comments

Comments
 (0)