akamai / akamai/NetStorageKit-Node

Unable to rename directories

Open
#22 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
JavaScript
Stars
18
Forks
14
PR merge metrics
No merged PRs in 30d

Description

I'm unable to rename directories.

The current documentation says it's possible to rename both directories and files.

const NETSTORAGE_TARGET = '/<cpcode>/temp_test/v0'
const NETSTORAGE_DESTINATION = '/<cpcode>/temp_test/v1'
console.log('source', NETSTORAGE_TARGET)
console.log('target', NETSTORAGE_DESTINATION)

ns.rename(NETSTORAGE_TARGET, NETSTORAGE_DESTINATION, (err, response, body) => {
  if (err) {
    console.error('err', err)
    throw err
  }
  console.log('err', err)

  console.log('statusCode: ', response.statusCode)
  console.log('statusMessage: ', response.statusMessage)
  console.log('body ', body)
})

logs

source /<cpcode>/temp_test/v0
target /<cpcode>/temp_test/v1
err null
statusCode:  404
statusMessage:  Not Found
body  { message: 'Source not found' }
  • the cpcode is part of the base path.
  • I've checked that the path is correct, as I've renamed a file that is in the same level of the directory I'm trying to rename.

I'll appreciate any help,
Cheers.

Contributor guide

No contributing guide indexed for this repository

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

No source file or test is named in the report. Locate the rename implementation and the documentation describing directory support, reproduce the shown directory rename request, and compare it with the working file case. Done means directory renames succeed and a regression test covers the behavior.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
api, backend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.