feathers-objection
feathers-objection copied to clipboard
Getting Ready for Feathers v5 Dove
The following changes are needed to fully prepare feathers-objection
for Feathers v5 Dove:
- [ ] Port to TypeScript
- [ ] Support the updated
@feathersjs/adapter-tests
suite. (includingparams.adapter
) - [ ] Publish compiled JS version
- [ ] Automate Postgres Tests
- [ ] Split Postgres-specific tests into their own file.
- [ ] Setup Postgres container in Github Actions
- [ ] Setup
test-local
environment for testing against local Postgres DB. - [ ] Setup
ci
environment for Github Actions.
Is this plugin still planned to be made fully compatible with Feathers v5 dove (and integrated back into feathers cli as an option when generating services)?
@ramsestom It might already work with Feather v5. I'm not aware of any breaking-changes and it seems that the list from @marshallswain is mostly about TypeScript and tests. I'm not using FeathersJS in my current projects, but any PRs are welcome.
While upgrading dependencies, I've tried running the tests with Feathers v5 and it didn't work. Looks like the AdapterService
class that it is extending doesn't exist anymore. As much as I'd like to help, I'm not into TypeScript development these days and also haven't used FeathersJS for the past 2 years, so unless I get a PR regarding this upgrade, this library will remain unsupported in FeathersJS v5 (same for other plugins that I contributed in the past - feathers-cassandra, feathers-service-tests-cassandra, feathers-http-disributed, feathers-opentracing, feathers-kong, feathers-stripe-webhooks, feathers-hubspot-webhooks).
@dekelev I think that it got moved to @feathersjs/adapter-commons
and renamed to AdapterBase
. Does this look like the right class? https://github.com/feathersjs/feathers/blob/dove/packages/adapter-commons/src/service.ts#L22-L29
Thanks @marshallswain , I tried that now and got this error on invalid service object that was trying to initialize for the tests. Any idea why it's failing?


I had to remove the underscore from the service method names. It works now, but some tests are failing on code related to the FeathersError class. This import is not defined anymore:
import errors from '@feathersjs/errors';
It works when importing each class in separate.
Any idea where's the filterQuery
base service method?
It's not defined in the old place (this.filterQuery
).
Try importing it from @feathersjs/adapter-commons
, as well. https://github.com/feathersjs/feathers/blob/dove/packages/adapter-commons/src/query.ts#L137
import errors from '@feathersjs/errors';
I think it's now
import * as errors from '@feathersjs/errors'
if you want them all.
Got it, thanks

Is the whitelist option deprecated? Was it replaced by something else?
@dekelev, Two solutions replaced it. If you're using @feathersjs/schema or @feathersjs/typebox, the query validators replace the need for whitelist. If you're not using the new validators, you can find the replacement for the whitelist here: https://feathersjs.com/guides/migrating.html#custom-filters-operators
Thanks! I'll check it out
@dekelev Can you push your branch? I’ll see if I can help 🙂
Sure, I'll push it soon. It's still a mess and I haven't got time to work on it since last week.
I pushed the feathers-dove branch.