Compare commits
5 Commits
Author | SHA1 | Date |
---|---|---|
Paul van Tilburg | 88c59cdb1f | |
Paul van Tilburg | cad766b520 | |
Paul van Tilburg | e62699c102 | |
Paul van Tilburg | f32f67dbf4 | |
Paul van Tilburg | d1e43a7aa7 |
16
CHANGELOG.md
16
CHANGELOG.md
|
@ -7,6 +7,19 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
|
||||
## [Unreleased]
|
||||
|
||||
## [0.2.11] - 2024-02-27
|
||||
|
||||
### Security
|
||||
|
||||
* Updated dependencies, fixes security advisories:
|
||||
* [RUSTSEC-2024-0003](https://rustsec.org/advisories/RUSTSEC-2024-0003)
|
||||
* [RUSTSEC-2023-0072](https://rustsec.org/advisories/RUSTSEC-2024-0072)
|
||||
|
||||
### Fixed
|
||||
|
||||
* Fix clippy issue
|
||||
* Tweak/fix tests; reduce required accuracy for geocoded coordinates
|
||||
|
||||
## [0.2.10] - 2023-11-03
|
||||
|
||||
### Security
|
||||
|
@ -159,7 +172,8 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|||
|
||||
Initial release.
|
||||
|
||||
[Unreleased]: https://git.luon.net/paul/sinoptik/compare/v0.2.10...HEAD
|
||||
[Unreleased]: https://git.luon.net/paul/sinoptik/compare/v0.2.11...HEAD
|
||||
[0.2.11]: https://git.luon.net/paul/sinoptik/compare/v0.2.10...v0.2.11
|
||||
[0.2.10]: https://git.luon.net/paul/sinoptik/compare/v0.2.9...v0.2.10
|
||||
[0.2.9]: https://git.luon.net/paul/sinoptik/compare/v0.2.8...v0.2.9
|
||||
[0.2.8]: https://git.luon.net/paul/sinoptik/compare/v0.2.7...v0.2.8
|
||||
|
|
File diff suppressed because it is too large
Load Diff
|
@ -1,6 +1,6 @@
|
|||
[package]
|
||||
name = "sinoptik"
|
||||
version = "0.2.10"
|
||||
version = "0.2.11"
|
||||
authors = [
|
||||
"Admar Schoonen <admar@luon.net",
|
||||
"Paul van Tilburg <paul@luon.net>"
|
||||
|
|
|
@ -263,8 +263,8 @@ mod tests {
|
|||
let response = client.get("/forecast?address=eindhoven").dispatch();
|
||||
assert_eq!(response.status(), Status::Ok);
|
||||
let json = response.into_json::<JsonValue>().expect("Not valid JSON");
|
||||
assert_float_absolute_eq!(json["lat"].as_f64().unwrap(), 51.4392648, 1e-8);
|
||||
assert_float_absolute_eq!(json["lon"].as_f64().unwrap(), 5.478633, 1e-8);
|
||||
assert_float_absolute_eq!(json["lat"].as_f64().unwrap(), 51.448557, 1e-5);
|
||||
assert_float_absolute_eq!(json["lon"].as_f64().unwrap(), 5.450123, 1e-5);
|
||||
assert_matches!(json["time"], JsonValue::Number(_));
|
||||
assert_matches!(json.get("AQI"), None);
|
||||
assert_matches!(json.get("NO2"), None);
|
||||
|
@ -281,8 +281,8 @@ mod tests {
|
|||
.dispatch();
|
||||
assert_eq!(response.status(), Status::Ok);
|
||||
let json = response.into_json::<JsonValue>().expect("Not valid JSON");
|
||||
assert_float_absolute_eq!(json["lat"].as_f64().unwrap(), 51.4392648, 1e-8);
|
||||
assert_float_absolute_eq!(json["lon"].as_f64().unwrap(), 5.478633, 1e-8);
|
||||
assert_float_absolute_eq!(json["lat"].as_f64().unwrap(), 51.448557, 1e-5);
|
||||
assert_float_absolute_eq!(json["lon"].as_f64().unwrap(), 5.450123, 1e-5);
|
||||
assert_matches!(json["time"], JsonValue::Number(_));
|
||||
assert_matches!(json.get("AQI"), Some(JsonValue::Array(_)));
|
||||
assert_matches!(json.get("NO2"), Some(JsonValue::Array(_)));
|
||||
|
|
|
@ -109,7 +109,7 @@ pub(crate) async fn resolve_address(address: String) -> Result<Position> {
|
|||
let points: Vec<Point<f64>> = osm.forward(&address)?;
|
||||
|
||||
points
|
||||
.get(0)
|
||||
.first()
|
||||
.ok_or(Error::NoPositionFound)
|
||||
.map(Position::from)
|
||||
})
|
||||
|
|
Loading…
Reference in New Issue