restify / restify/node-restify

[err_assertion]: path (string) is required in restify 8.5.1 version

Open
#1,865 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
10.7k
Forks
975
Avg merge
1d 6h
Merged PRs (30d)
5

Description

Current version: 6.3.4

We are using the below router to serve the index.html

server.get(/\/?.*/, restify.plugins.serveStatic({
    directory: path.join(__dirname, '../build'),
    default: 'index.html'
})
);

And we are planning to migrate to 8.5.1 version and getting [err_assertion]: path (string) is a required exception.

Would be a great help if you guys can share about the replacement for this.

Thanks,
Sreekanth

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the supplied server.get and serveStatic configuration while comparing Restify 6.3.4 with 8.5.1. Check the 8.5.1 routing and static-serving documentation or changelog for the path assertion and supported replacement; it is done when index.html is served without the exception.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, node.js
Domain
backend, web-dev
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.