Commit Graph

110 Commits

Author SHA1 Message Date
magpie-engineering d460ff7970
Update to version of rocket master after update to tokio version 1.6.1 dependency (#92)
Co-authored-by: Magpie Engineering <as8709@gmail.com>
2021-06-02 02:40:07 +00:00
Eric Dattore 0b2d3e80b1
Update to latest Rocket master (#91)
- Update all instances of `State<T>` to borrow and drop anonymous lifetime
- Remove examples showing returning a `Response` instead of a `Responder`
  since `Response` no longer implements `Responder`
2021-05-28 10:57:55 +08:00
dependabot-preview[bot] 273522e697
Upgrade to GitHub-native Dependabot (#90)
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
2021-04-30 10:48:53 +08:00
thanadolps c0d7b36877
Update to latest master Rocket version (#89)
* Change to catch up with latest rocket master

- rocket::handler -> rocket::route
- request.get_param() -> request.param
- Change attach -> ignite and ignite -> build
- Update lifetime signature of FromRequest

* Remove unused import

* Remove colliding route in catch_all_options_routes()

In rocket 0.5 "/<catch_all_options_route..>" should match path "/" too hence the collision.

* Revert "Remove unused import"

This reverts commit 69db6d53

* add #[allow(unused_imports)] to log

* lock Rocket to specific commit

* apply rustfmt
2021-04-26 15:36:37 +08:00
Yong Wen Chua 305971023d
Delete .travis.yml 2020-11-26 13:55:17 +08:00
Zachary Kohnen 8427e62521
fix: Update to latest master Rocket version (#85)
- Add explicit branch name to rocket dependency
- Fix linter errors
2020-10-29 08:42:09 -06:00
Henning Holm fae7ccf9ce
Use async version from rocket's master branch (#81)
* Use hyper re-export from rocket_http

This way, the hyper version corresponding to the current rocket version
is used for the tests.

* Use async version from rocket's master branch
* switch rocket version to master branch
  (use release version once async is available)
* adapt code to incorporate changes from rocket and hyper
* Make Clippy happy again
* Make crate compile on Rust stable

Rocket meanwhile works on Rust stable, so there is no reason to be
limited to nightly.
* Fix GitHub CI build
* Use stable branch of Rust instead of broken minimum required nightly
  version.
* Disable fail-fast to reveal all problems at once.
* Remove deletion of rust-toolchain file as the file is no longer
  required/existing.

Co-authored-by: Maximilian Köstler <maximilian@koestler.hamburg>
2020-09-07 20:47:01 -06:00
Yong Wen Chua 172f423887
Bump log 2020-03-18 14:52:18 +08:00
Yong Wen Chua d829301823
Fix build warnings 2020-03-18 14:45:41 +08:00
Yong Wen Chua 2408b0c3b4
Update CHANGELOG.md 2020-01-22 09:43:22 +08:00
morbatex 51539453d5 added a builder pattern to CorsOptions (#75)
* added a builder pattern to CorsOptions

* builder pattern in corsOptions is now consuming
2020-01-22 09:42:16 +08:00
dependabot-preview[bot] f9603e118f Update url requirement from 1.7.2 to 2.1.0
Updates the requirements on [url](https://github.com/servo/rust-url) to permit the latest version.
- [Release notes](https://github.com/servo/rust-url/releases)
- [Commits](https://github.com/servo/rust-url/compare/v1.7.2...v2.1.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2019-11-13 03:10:50 +00:00
Yong Wen Chua 0630b4c34b
Use Github Actions for PR tests (#71) 2019-11-13 10:59:51 +08:00
Yong Wen Chua 3a9b1fd7e8
Fix build issues for Rocket 0.4.2 (#70)
- Fix clippy lints
- Bump minimum Rust version beyond Rocket required for
  - `std::mem::MaybeUninit` (cf. https://github.com/rust-lang/rust/pull/60445)
  - `alloc` crate
2019-11-13 10:45:06 +08:00
Jacob Pratt c75dcb286d Disable default features, which are not used (#69) 2019-08-28 10:35:40 +08:00
Yong Wen Chua 2827c8a02b
Release v0.5.0 2019-05-27 08:54:49 +08:00
Yong Wen Chua f438d5538e
Better Opaque Exact Match Error Handling and Docs (#64)
* Add notes about Opaque Origins

* Improve error handling for Opaque Exact matches

* Cleanups

* Add more test condition
2019-03-19 10:19:10 +08:00
Yong Wen Chua b5cb16c74a
Bump to beta 2 for development 2019-03-18 10:34:05 +08:00
Yong Wen Chua 00e1399b1f
Release 0.5.0-beta-1 2019-03-18 10:32:24 +08:00
Yong Wen Chua ed1571394c
Add anchor 2019-03-18 10:30:26 +08:00
Yong Wen Chua d707ad7b7a
Add CHANGELOG and migration notes 2019-03-18 10:27:56 +08:00
Yong Wen Chua f00b1f9a38
Add more docs 2019-03-18 10:13:15 +08:00
Yong Wen Chua 6ac56f54c6
Fix issue validating opaque origins (#63)
* Fix issue validating opaque origins

* Remove commented line

* Separate lifetimes for `AllowedOrigins::some`

* Add targets
2019-03-18 09:55:16 +08:00
Yong Wen Chua 6f56109d77
Support Regex in origins configuration (#62)
* Refactor Origin

* Fix tests

* Fix tests

* Add JSON deserialization test

* Support regex

* Fix wording

* Fix wording
2019-03-12 15:05:40 +08:00
Yong Wen Chua f9bffe77d6
Refactor Origins to better support additional use cases (#59)
* Specify an internal structure for Cors

* Use type alias

* Refactor Origin validation

* Separate out `Origin`

* Add tests
2019-03-12 09:58:51 +08:00
Atul Bhosale 9d8f7aa6f7 Update copyright notice to 2019 [ci skip] (#61) 2019-02-05 09:39:01 +08:00
Yong Wen Chua 9f87c73a51
Add clippy and rustfmt checks (#58) 2018-12-19 01:51:09 +01:00
Yong Wen Chua b15ce2b24b
Bump url crate 2018-12-19 08:35:08 +08:00
Yong Wen Chua c86bb44529
Create `CorsOptions` (#57)
* Create `CorsOptions`

- `Cors` will be, in the future, an "optimised" or "compiled" version of
`CorsOptions`
- For now, `Cors` simply clones `CorsOptions` and `Deref`s to
`CorsOptions`.

* Update examples

* Remove usage of `Self` struct constructors
2018-12-19 01:29:26 +01:00
Yong Wen Chua aa15af333f
Clean up Crate docs 2018-12-18 17:05:17 +08:00
Yong Wen Chua 93db1fa217
Remove deprecated function 2018-12-18 16:08:48 +08:00
Johan Bjäreholt c4e4b7d585 More detailed error messages and moved away from deprecated error::Error::description (#54)
* Replaced deprecated error::Error description with Display

* Make OriginNotAllowed and MethodNotAllowed error messages more useful
2018-12-12 22:53:44 +01:00
Sergio Benitez d880c2a111 Bump both Rocket and this library to 0.4.0 (#56)
* Bump to Rocket 0.4.0

* Bump to 0.4.0

Fixes #55
2018-12-12 22:23:51 +01:00
Yong Wen Chua 495317bd9e
Bump to Rocket 0.4.0-rc.2 (#53)
* Bump to Rocket 0.4.0-rc.2

* Update strings

* Bump minimum Rust version
2018-12-04 12:01:29 +08:00
Yong Wen Chua 02c7fcf519
Bump to 0.4.0-rc.2 2018-11-21 12:18:58 +08:00
Yong Wen Chua 13a3f7368e
Upgrade to Rust 2018 to fix Macro use and import issues (#52)
* Upgrade to Rust 2018 to fix Macro use and import issues

Fixes #51

* Cargo fmt
2018-11-21 12:17:40 +08:00
Yong Wen Chua 9cb16ba01d
Use request local cache for fairing implementation (#50) 2018-11-01 14:44:28 +08:00
Yong Wen Chua 21444e90c4
Update README 2018-11-01 09:21:50 +08:00
Yong Wen Chua a0d31cf498
Bump to Rocket 0.4.0-rc.1 (#49) 2018-11-01 09:20:24 +08:00
Yong Wen Chua d993082991
docs.rs now builds nightly docs properly 🎉 2018-10-31 10:59:52 +08:00
Yong Wen Chua b80c1939d4
Remove `macro_use` on `extern crate` (#47)
* Remove macro_use from examples

* Remove macro_use from log and rocket

* Remove macro_use for serde_derive

* Remove from examples

* Fix no-default features build failure
2018-10-31 10:59:01 +08:00
Yong Wen Chua 086f018bb9
cargo fix --edition 2018-10-31 10:31:16 +08:00
Yong Wen Chua 4dda14373a
cargo fmt 2018-10-31 10:30:10 +08:00
Eric Dattore 0b73773692 Update library to 0.4 and support Rocket 0.4 (#46)
* Update Cargo.toml for Rocket `master`

* Prepare library for Rocket 0.4

TODO: check line 62 in `fairing.rs` to find better way than unwrapping

* Bump minimum nightly for Rocket 0.4
2018-10-31 10:25:10 +08:00
Yong Wen Chua 351f0f945f
Bump Rocket and minimum Rust version (#45) 2018-09-17 09:46:50 +08:00
Tal Garfinkel f4858e1029 Fix various warnings generated by build: (#43)
-removed conservative_impl_trait as it is no longer needed with the current compiler.
-removed allow(unmounted_route) as rocket no longer provides this linter.
2018-07-19 10:03:03 +08:00
Yong Wen Chua e11e973da8 Update Cargo.toml with dual license 2018-07-18 14:39:28 +08:00
Yong Wen Chua 096930ebfa v0.3.0 Release 2018-07-18 13:34:21 +08:00
Yong Wen Chua b133d19465 Bump minimum Rocket version 2018-07-18 13:31:11 +08:00
Yong Wen Chua e45b618c4f Fix copy paste embarassing mistake 2018-07-18 13:30:54 +08:00