Andrei Subbota
3e842a138b
Dependencies update ( #948 )
...
* Add spec route helper to complain with Grape >= 2.3.0
* Explicitly add ostruct gem in case of Ruby 3.5
* Update CHANGELOG
2025-02-19 09:25:58 -05:00
peter scholz
599712eb34
Prepare release 2.1.2 ( #946 )
...
* Drop ruby 3.0
* Prepare release 2.1.2
2025-01-07 23:09:02 +01:00
Grzegorz Jakubiak
7c74647b61
Add support for primitive data types in responses ( #945 )
...
* Add support for primitive data types in responses
* Use `format` option
* Handle `Hash` type
* Update CHANGELOG.md
2025-01-07 14:52:29 +01:00
Pieter Oliver
ecafd1f78f
Amend typoes ( #944 )
...
* Amend some documentation specific typoes
* Address some typoes in tests
* Amend source typo
* Fix typo in parameter call
* Pencil in contribution line
2024-10-23 08:20:03 -04:00
Andrey Viktorov
fddae76f8c
fix: Grape::Endpoint#merge_params now returns correct object ( #943 )
2024-10-18 11:43:10 -04:00
dblock
7ec7bed26f
Preparing for next developer iteration, 2.1.2.
2024-09-21 05:27:53 -04:00
dblock
4d96c4508f
Preparing for release, 2.1.1.
2024-09-21 05:26:35 -04:00
Patrick Oscity
a4190cf2d1
Grape 2.2.0 compatibility ( #940 )
...
* Run `rubocop -a`
* Update changelog
* Run CI against grape 2.1.x and 2.2.x
* Copy formatter and content type defaults from grape
* Use matrix to reduce duplication in CI workflow
2024-09-21 05:21:46 -04:00
Dhruv Paranjape
a5e2575a02
Document the min/max Items/Length fields if the attribute uses the length validator ( #934 )
...
* Document the min/max Items/Length fields if the attribute uses the length validator.
* restrict rack version to less than 3.0 when grape version 1.8 or lower
* fix spec
2024-06-28 09:16:20 +02:00
Eric Proulx
707b00b91b
Use `route.namespace` instead instance_variable_get(@options) ( #931 )
...
Rename `route_instance_variable_equals?` to `route_namespace_equals?`
Refactor route_path_start_with? and route_namespace_equals? with Enumerator instead of static Arrays
Refactor determine_namespaced_routes in positive logic (select over reject)
2024-06-11 01:33:41 +02:00
peter scholz
e7d6790f73
Prepare release 2.1.0 ( #930 )
2024-05-14 13:38:41 +02:00
Dhruv Paranjape
95be315986
Set query parameter for array of primitive types ( #929 )
...
* Set query parameter for array of primitive types
* Update PR number in changelog
* refactor param_type method to handle array params.
---------
Co-authored-by: Eugene Lim <limzhiweieugene@gmail.com>
2024-05-14 13:09:05 +02:00
Dhruv Paranjape
e7856de6d0
Set default parameter location based on consumes ( #927 )
...
* Set default parameter location based on consumes
* fix rubocop warnings and update todos.
* fix spec
* change rubocop fix
* correct PR number in changelog
---------
Co-authored-by: Eugene Lim <limzhiweieugene@gmail.com>
2024-05-10 12:42:54 +02:00
LeFnord
953075aa5b
Adds missing CHANGELOG entry.
2024-04-30 19:00:31 +02:00
Andrei Subbota
0b969bc25d
Avoid unnecessary `add_setup` calls ( #926 )
2024-04-30 17:28:46 +02:00
peter scholz
37fa45f4e2
Prepare release 2.0.3 ( #925 )
2024-04-26 07:50:16 +02:00
Suzuki Eiji
ceebbd3469
fix: Use mount_path to narrow down urls_for ( #924 )
2024-04-26 07:10:24 +02:00
Andrei Subbota
b75ce7f77d
Allow DELETE to have a params schema definition ( #923 )
2024-04-25 07:39:46 +02:00
Andrei Subbota
e2b50b347a
Force request body to be an schema object ( #922 )
...
* Force request body to be an schema object
* Require "OpenStruct" explicitly in specs
* Update changelog and upgrading documentation
2024-04-22 05:50:05 +02:00
LeFnord
262cdb9954
Makes rubocop happy.
2024-03-03 17:08:49 +01:00
David Chandek-Stark
ccdc2dd082
Fixes (restores) route ordering ( #859 )
...
* Fixes order
* Updates CHANGELOG
Satisfies rubocop
* I believe the removed test is not supported by grape and should not
be a blocker to making the changes in this PR.
While there does not appear to be a grape test with the same setup,
the spec at e3451c892a/spec/grape/api_spec.rb (L1025-L1045)
suggests that mounts do not overwrite.
---------
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2024-03-03 16:52:36 +01:00
peter scholz
7198a3abb2
Prepare release 2.0.2 ( #920 )
...
- removes unused dependencies: coverall and danger
2024-02-02 12:43:36 +01:00
Andrei Subbota
de6f094951
Add extension properties to schema for body params ( #918 )
2024-01-22 15:44:27 +01:00
peter scholz
cb92e17cc3
Prepare release 2.0.1 ( #917 )
2024-01-02 13:05:34 +01:00
Lin Jen-Shin (godfat)
46dc3f86ba
Restore support for Ruby 3.0 ( #916 )
...
Co-authored-by: Lin Jen-Shin <jen-shin@gitlab.com>
2024-01-02 12:47:47 +01:00
peter scholz
8aa342c9d4
Support Ruby 3.3 ( #914 )
...
* Adds ruby 3.3 to Actions.
* Adds CHANGELOG entry.
2023-12-29 11:03:59 +01:00
peter scholz
8e723c6383
Prepare Release 2.0.0 ( #912 )
...
* Allows to use grap v2.0 in dev.
* Aligns ruby and grape version with test matrix.
- removes allowing untested versions
* Prepare release 2.0.0
2023-11-17 11:51:25 +01:00
Manabu Niseki
69e91790a0
Allow using Grape v2 ( #910 )
...
* Allow using Grape v2
* Update CHANGELOG.md
2023-11-14 09:16:43 +01:00
x-yuri
dfc038476a
grape-swagger needs rack-test ( #909 )
2023-10-24 11:34:40 +02:00
Eric Proulx
c4c2dead28
Refactor gemspec files to include just the necessary ( #907 )
...
* Refactor gemspec files to include just the necessary
* Revert LOAD_PATH
* Replace MD Files by *.md
* Use require_relative to load version
2023-10-22 14:58:16 +02:00
Vladislav Momatau
a56b56aaf1
Assign :example param on array properties ( #903 )
...
* Assign :example param on array properties
* Update CHANGELOG
2023-09-11 09:54:22 +02:00
peter scholz
55267acd39
Some maintenance tasks. ( #906 )
...
* Improves rubocop config.
* Replaces grape 1.6 action job by grape 1.8.
* Removes 3.0 test in action.
* Bump actions/checkout from 3 to 4.
- closes #32
2023-09-06 20:14:08 +02:00
peter scholz
3a5da56fb3
Prepare release 1.6.1 ( #900 )
2023-05-21 00:58:40 +02:00
peter scholz
217d3ca3f9
Adjust spec matrix. ( #899 )
...
* Updates GH action matrix.
* Improves Actions.
* Loosens grape versions.
- fixes run matrix
- makes rubocop happy
2023-05-21 00:31:00 +02:00
Dhruv Paranjape
e5090b66ac
fix parsing endless range values ( #896 )
2023-05-08 14:36:46 +02:00
duffn
c0c1b74bc7
Fix README links ( #895 )
2023-04-07 11:38:39 +02:00
peter scholz
e3a15edff2
Prepare release 1.6.0 ( #893 )
...
* Updates GH action matrix.
* Improves Actions.
* Prepare release 1.6.0
2023-03-19 14:04:00 +01:00
Dhruv Paranjape
49fed72c65
Add Support for default response. ( #868 )
...
* Add Support for default response.
support default as a response code as specified in https://swagger.io/docs/specification/2-0/describing-responses/ Default Response section.
* add docs
2023-03-19 13:17:22 +01:00
Eugene Lim
3f309db2bb
Add consumes and produces options to add_swagger_documentation ( #872 )
...
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2023-02-19 15:26:57 +01:00
peter scholz
10d165ba53
Upgrades Rack. ( #890 )
...
* Updates GH action matrix.
* Improves Actions.
* Updates Rack to > 3.
2023-02-19 15:22:59 +01:00
peter scholz
557df89f82
Uses Ruby 3.2 ( #889 )
...
* Updates GH action matrix.
* Improves Actions.
* Updates matrix to use runy 3.2
2023-02-19 15:02:15 +01:00
peter scholz
1eb9fe6a86
Prepare release 1.5.0 ( #864 )
...
* Updates GH action matrix.
* Improves Actions.
* Prepapre release 1.5.0
- upgrades rubocop target to 3.1
2022-07-28 22:06:39 +02:00
dependabot[bot]
966b594726
Bump actions/checkout from 2 to 3 ( #863 )
...
Bumps [actions/checkout](https://github.com/actions/checkout ) from 2 to 3.
- [Release notes](https://github.com/actions/checkout/releases )
- [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md )
- [Commits](https://github.com/actions/checkout/compare/v2...v3 )
---
updated-dependencies:
- dependency-name: actions/checkout
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-07-27 00:08:08 +02:00
Naveen
43bcdb4c15
chore: Included githubactions in the dependabot config ( #860 )
...
This should help with keeping the GitHub actions updated on new releases. This will also help with keeping it secure.
Dependabot helps in keeping the supply chain secure https://docs.github.com/en/code-security/dependabot
GitHub actions up to date https://docs.github.com/en/code-security/dependabot/working-with-dependabot/keeping-your-actions-up-to-date-with-dependabot
https://github.com/ossf/scorecard/blob/main/docs/checks.md#dependency-update-tool
Signed-off-by: naveensrinivasan <172697+naveensrinivasan@users.noreply.github.com>
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-27 00:05:00 +02:00
Remco van 't Veer
fc9a18cc22
Syntax errors in README.md examples ( #843 )
...
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-26 10:16:51 +02:00
Halil Sen
013d2dacd9
Fixes the regexp used for parsing routes ( #844 )
...
* Fix: incorrect regexp character set definition
In a character set, vertical bars `|` are treated as a proper character and not as an OR.
They are not needed since character set applies the OR logic automatically.
* Update CHANGELOG.md
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-26 10:07:57 +02:00
Devin Moss
908a7a8912
Parse route_param type for nested endpoints ( #847 )
...
* Fix documentation of `route_param` type when used with nested endpoints
* Rubocop fixes
* Rubocop fixes
* grape 1.6
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-26 10:04:09 +02:00
Masayoshi Takahashi
d5766639d2
Remove unused methods in GrapeSwagger::DocMethods::BuildModelDefinition ( #856 )
...
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-26 09:57:09 +02:00
Naveen
c3a4bb333f
Set permissions for GitHub actions ( #858 )
...
- Included permissions for the action. https://github.com/ossf/scorecard/blob/main/docs/checks.md#token-permissions
https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#permissions
https://docs.github.com/en/actions/using-jobs/assigning-permissions-to-jobs
[Keeping your GitHub Actions and workflows secure Part 1: Preventing pwn requests](https://securitylab.github.com/research/github-actions-preventing-pwn-requests/ )
Restrict the GitHub token permissions only to the required ones; this way, even if the attackers will succeed in compromising your workflow, they won’t be able to do much.
Signed-off-by: naveensrinivasan <172697+naveensrinivasan@users.noreply.github.com>
Co-authored-by: peter scholz <pscholz.le@gmail.com>
2022-07-26 09:52:05 +02:00
Paul Padier
1a3e3f5889
Allow using nicknames for body definitions ( #862 )
...
* Fix typo
* Refactor MoveParams.parent_definition_of_params to use OperationId.build rather than OperationId.manipulate
This means it'll use route nicknames if those are available. It also means route parameters will be used in the definition names.
* Simplify MoveParams.build_body_parameter
MoveParams.build_definition returns the passed in name, so name and referenced_definition were always the same value.
* Fix Rubocop offenses
* Fix old reference to Travis CI in CONTRIBUTING
* Fix CHANGELOG
* Update CHANGELOG and UPGRADING
2022-07-26 09:44:42 +02:00