quobix
70f406b6cf
Added NodeMap to all low level objects.
...
this sync map tracks all the nodes that apply to this object.
2024-08-05 09:29:07 -04:00
quobix
425b25cdd0
Added a nill check to lookup.
...
was causing vacuum to crash during testing.
2024-07-09 13:44:55 -04:00
quobix
c2b58717b8
Addressed issue with anchors and merge nodes
...
Highlighted in https://github.com/daveshanley/vacuum/issues/508
The comment from @Jakousa annoyed me. Rude.
2024-07-08 10:14:32 -04:00
quobix
8506d1dc86
updated regex for path conversions
2024-07-08 10:14:32 -04:00
quobix
65422f0c58
Added coverage, removed dead code from path utils
2024-07-08 10:14:32 -04:00
quobix
cd5601e0d8
cleaned backslash failure on windows
2024-07-08 10:14:32 -04:00
quobix
1ba21e682f
added windows check for patch conversion
2024-07-08 10:14:32 -04:00
quobix
f33aa2fee0
Tuning up path -> component -> path tooling
2024-07-08 10:14:32 -04:00
quobix
7e86e991b2
Fix panic when ref is mis-used
2024-04-29 11:32:10 -04:00
Tristan Cartledge
9d9ff8a00c
chore: bump timeout on FindNodesWithoutDeserializing
2024-02-14 07:58:25 -05:00
quobix
43860f4e3c
Added some new getters to the index
...
Also added map conversion utilities based on reported vacuum error https://github.com/daveshanley/vacuum/issues/417
also prevented the bundler from inlining root references.
Signed-off-by: quobix <dave@quobix.com >
2024-01-18 15:11:39 -05:00
quobix
62ed25052a
Added of by one check and test
...
Signed-off-by: quobix <dave@quobix.com >
2024-01-18 15:11:39 -05:00
quobix
202ae3365a
updated coverage for timeout path lookup
...
Signed-off-by: quobix <dave@quobix.com >
2024-01-04 17:08:08 -05:00
quobix
cbdaac7374
cleaned up path handling a little
...
Signed-off-by: quobix <dave@quobix.com >
2024-01-04 17:08:08 -05:00
Tristan Cartledge
69ba5b875a
feat: add ordered json
2023-12-03 22:28:15 +00:00
quobix
6a6d6d6e31
Moved regex to precompile
...
I don’t know why I put this in the hotpath.
Signed-off-by: quobix <dave@quobix.com >
2023-11-09 06:37:36 -05:00
quobix
ff40cfad85
Off by one issue fixed https://github.com/daveshanley/vacuum/issues/356
...
Reported by vacuum issue, this use-case is now handled correctly and prevents a panic.
Signed-off-by: quobix <dave@quobix.com >
2023-11-05 09:21:29 -05:00
Nicholas Jackson
def8e997b2
Fix lint issues in util
...
Reduce execution time of ConvertComponentIdIntoFriendlyPathSearch by
50-60% and add benchmark
Signed-off-by: Nicholas Jackson <nickajacks1@gmail.com >
2023-11-04 12:00:19 -04:00
quobix
8f3f568e5f
Tuned some glitches with v3 doc creation.
...
all covered now
Signed-off-by: quobix <dave@quobix.com >
2023-10-31 15:31:19 -04:00
quobix
715bfc3052
Added support for configurable levels of circular reference checking #113 #130
...
Signed-off-by: quobix <dave@quobix.com >
2023-09-21 06:01:23 -04:00
Dave Shanley
25d8de9b0e
Added more support for YAML merge nodes, anchors and aliases
...
And added deeper support for Aliases. Also added in local file handling through renamed `FSHandler` configuration property for the index.
Also re-ran `go fmt`
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-07-16 11:45:18 -04:00
Dave Shanley
20ac2fb25a
Adding more test coverage
...
Fixing some outdated code as well.
Signed-off-by: Dave Shanley <dave@quobix.com >
Cleaning up more coverage issues
Signed-off-by: Dave Shanley <dave@quobix.com >
More test coverage updates.
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-06-17 14:12:27 -04:00
Dave Shanley
e1f0f69650
Original indention and text delimiter style retained when rendering #106
...
Now the original indention is captured and string delimiters are retained when rendering out documents.
Signed-off-by: Dave Shanley <dave@quobix.com >
# fixes 106
2023-06-17 14:12:27 -04:00
Dave Shanley
5b128c098a
Added support for original format rendering #105
...
Original input document types are now rendered automatically as JSON or YAML (vs always being YAML). This only operates at the `Document` level for rendering out entire documents.
Requested in #105
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-06-17 14:12:27 -04:00
Dave Shanley
148822fa2a
Added support for references with brackets #112
...
Brackets in names are now supported. For example `’#/components/schemas/CoffeeCup[Black]’
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-06-17 14:12:27 -04:00
Dmitry
fa337646da
Use EqualFold ti avoid memory reallocations
2023-06-17 13:13:15 -04:00
Derrick J. Wippler
a09916eb67
fix: Schema.Minimum and Schema.Maxmium are now float64
2023-06-17 13:12:50 -04:00
Dave Shanley
f629c0ff58
fix for resolving looping relative references
...
In vacuum, a usecase was reported where an infinite loop occurred due to re-parsing the same reference over and over in a loop. It was re-creatable and it was because the loop happened before the index was ready.
This should be resolved now, at least for this use case. To be sure, I have included the specs as a new test.
https://github.com/daveshanley/vacuum/issues/268
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-05-16 17:03:02 -04:00
Dave Shanley
8549b1547a
Added a stack overflow safe recursive variation of FindLastChildNode
...
Old method deprecated.
Signed-off-by: Dave Shanley <dave@quobix.com >
2023-04-30 09:01:15 -04:00
Dave Shanley
0e8ae7c548
rendering complex additionalProperties in place.
...
slices of maps were not rendered properly. Now corrected, coverage continues to rise, refactoring node generation into utils package.
2023-03-26 06:10:31 -04:00
Dave Shanley
2d536c884d
A few tiny non breaking changes.
...
just cleaning things up, preparing for online demo push for https://pb33f.io
2023-02-11 09:16:17 -05:00
Benjamin Nolan (TwoWholeWorms)
05d519c25f
chore: Removes unused function we added but replaced with isInfiniteCircularDependency
2023-01-11 05:47:06 -05:00
Benjamin Nolan (TwoWholeWorms)
cd63f66efe
fix: Check for direct reference in IsPropertyNodeRequired
2023-01-11 05:47:06 -05:00
Benjamin Nolan (TwoWholeWorms)
7338a614d0
refactor: FindKeyNode -> FindKeyNodeTop
2023-01-11 05:47:06 -05:00
Benjamin Nolan (TwoWholeWorms)
ee504c543a
feat: Allow circular references when the properties are not marked as required
2023-01-11 05:47:06 -05:00
Dave Shanley
8dff96ad90
Cleaning up some coverage and a few bits.
2022-12-15 16:31:32 -05:00
Dave Shanley
32f48385f2
(enhancement): Improved resolving/lookup code for #45
2022-12-15 16:31:32 -05:00
Dave Shanley
05eb4ffec9
(patch): Some crazy references are causing panics. #48 #45
...
This patch bumps up support for creating valid JSON paths from references. It addresses #48 and makes invalid specs, valid! This addresses issues #48 and #45 that report references cannot be found. Now `libopenapi` can support much more funky lookups.
2022-12-15 09:47:23 -05:00
Dave Shanley
f61e731567
(fix): An off-by-one issue caused by a value exactly mapping a key #43
...
Non breaking change fix for #43
2022-12-13 08:52:30 -05:00
Dave Shanley
59bf83c446
Supercharged test coverage back up to 99.9%
...
I can't test that one line in the index, so this will do.
Now to complete the document for what's changed.
2022-11-18 11:00:34 -05:00
Dave Shanley
77ecbd418f
Updated model builder to use lowercase checks only. **breaking change**
...
The case checking seems kinda dumb now looking back at this code. I am not sure why I felt the need to do that, however after being aware of it for some time and not being happy with the extra cycles it puts the code through.
This change removes ConvertCase from the utils package, as it's no longer used or needed right now. If it needs co come back, we can re-add the code, but deleting code always makes me happy.
It also removed a dependency from the project, which reduces the footprint, great!
2022-11-18 11:00:34 -05:00
Dave Shanley
61beb3ea2a
Schema what-changed almost complete.
...
Perhaps the biggest and most complex of all the models to determine what has changed.
2022-10-10 12:19:57 -04:00
Dave Shanley
647541cc77
Added in high document API
...
filling out documentation, looking at DX and how to consume things, re-shuffling and cleaning house.
2022-09-13 08:39:38 -04:00
Dave Shanley
0de0c16c0c
99.9 % coverage & full OpenAPI v3 support
...
A single line that tries to read an HTTP response body and fails is very hard to test without mocking, and the mock does not add value to a single line of code to check for an error that can rarely ever be triggered. Going to settle for 99.9% for now.
2022-08-31 10:04:39 -04:00
Dave Shanley
7c2a65f640
Added responses and response test
...
also added a new null check utility, not sure we need it right now however, but it's there.
2022-08-16 08:51:59 -04:00
Dave Shanley
248b4daa80
We-worked model to remove resolver.
...
lookups are performed inline now. keeps things simpler, however it has a performance knock, so it's time to refine async building were possible.
2022-08-11 14:54:25 -04:00
Dave Shanley
4bb6a9ad49
Additional properties now supported.
2022-08-05 13:20:29 -04:00
Dave Shanley
a4012594de
Building out model some more.
...
everything is holding up well.
2022-07-31 16:15:01 -04:00
Dave Shanley
2f60694047
Added tag model build out with tests.
...
Working through patterns and re-applying them as I go, cleaning things up as I cook.
2022-07-31 12:04:15 -04:00
Dave Shanley
7535cf568c
Working through the model builder
...
Shaping out the design as I go, what makes sence, what feels right, what do we need, how do we want to use it and how to we want to search it etc.
2022-07-30 15:27:21 -04:00