Skip to content

Circular Dependency  #927

Open
Open
@mahir-hs

Description

@mahir-hs

Can't log in anymore. Gives this error,

(node:14912) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created).

Activity

dotslash21

dotslash21 commented on Mar 7, 2024

@dotslash21

Same issue here :(

I'm using the cookie login but it's not working anymore.

login: (node:27208) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
cookie: - Retrieving user favorites
[WARN] Failed to retrieve user favorites: [object Object]
- Retrieving user profile
c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55
      let s = args.map(x => x.toString()).join(' ');
                              ^

TypeError: Cannot read properties of undefined (reading 'toString')
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:20)
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\commands\user.js:121:13
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:523:14
    at Request._callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:422:19)
    at self.callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:185:22)
    at Request.emit (node:events:514:28)
    at Request.<anonymous> (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:1161:10)
    at Request.emit (node:events:514:28)

Node.js v18.17.1

Update:

Also It seems other folks are facing this issue as well, #478 (comment)

lemonsher

lemonsher commented on Mar 7, 2024

@lemonsher

Same issue here :(

I'm using the cookie login but it's not working anymore.

login: (node:27208) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
cookie: - Retrieving user favorites
[WARN] Failed to retrieve user favorites: [object Object]
- Retrieving user profile
c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55
      let s = args.map(x => x.toString()).join(' ');
                              ^

TypeError: Cannot read properties of undefined (reading 'toString')
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:20)
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\commands\user.js:121:13
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:523:14
    at Request._callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:422:19)
    at self.callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:185:22)
    at Request.emit (node:events:514:28)
    at Request.<anonymous> (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:1161:10)
    at Request.emit (node:events:514:28)

Node.js v18.17.1

Update:

Also It seems other folks are facing this issue as well, #478 (comment)

Same

wangyerdfz

wangyerdfz commented on Mar 7, 2024

@wangyerdfz

Same issue here :(

I'm using the cookie login but it's not working anymore.

login: (node:27208) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
cookie: - Retrieving user favorites
[WARN] Failed to retrieve user favorites: [object Object]
- Retrieving user profile
c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55
      let s = args.map(x => x.toString()).join(' ');
                              ^

TypeError: Cannot read properties of undefined (reading 'toString')
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:20)
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\commands\user.js:121:13
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:523:14
    at Request._callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:422:19)
    at self.callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:185:22)
    at Request.emit (node:events:514:28)
    at Request.<anonymous> (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:1161:10)
    at Request.emit (node:events:514:28)

Node.js v18.17.1

Update:

Also It seems other folks are facing this issue as well, #478 (comment)

Node.js v20.11.0
login: (node:1480417) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
cookie: - Retrieving user favorites
[WARN] Failed to retrieve user favorites: [object Object]
- Retrieving user profile
/home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/log.js:55
      let s = args.map(x => x.toString()).join(' ');
                              ^

TypeError: Cannot read properties of undefined (reading 'toString')
    at /home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (/home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/log.js:55:20)
    at /home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/commands/user.js:121:13
    at /home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/plugins/leetcode.js:523:14
    at Request._callback (/home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/vsc-leetcode-cli/lib/plugins/leetcode.js:422:19)
    at self.callback (/home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/request/request.js:185:22)
    at Request.emit (node:events:518:28)
    at Request.<anonymous> (/home/**user**/.vscode/extensions/leetcode.vscode-leetcode-0.18.1/node_modules/request/request.js:1161:10)
    at Request.emit (node:events:518:28)

Node.js v20.11.0
- Waiting session result
(node:1505451) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
[ERROR] session expired, please login again [code=-1]

Same.

Ubuntu 20.04
Node v20.11.0
Vs Code 1.87.0
Extension version: 0.18.1

update 1: uploaded log

sff2578

sff2578 commented on Mar 7, 2024

@sff2578

same here, looks like when we try to access /accounts/login, server will give 403, maybe they have upgraded firewall or something. Also not sure why when I try to login with third party I got password incorrect

jasoncyu

jasoncyu commented on Mar 7, 2024

@jasoncyu

It's cloudflare, i printed out the response that I'm getting on some of the API calls and it says this:

 <p data-translate="blocked_why_detail">This website is using a security service to protect itself from online attacks. The action you just performed triggered the security solution. There are several actions that could trigger this block including submitting a certain word or phrase, a SQL command or malformed data.</p>
          </div>

          <div class="cf-column">
            <h2 data-translate="blocked_resolve_headline">What can I do to resolve this?</h2>

            <p data-translate="blocked_resolve_detail">You can email the site owner to let them know you were blocked. Please include what you were doing when this page came up and the Cloudflare Ray ID found at the bottom of this page.</p>

full html here: https://pastebin.com/cTTAf8cb

I got this a few months ago, I wasn't able to figure out a solution, it just ended up going away after a while

sff2578

sff2578 commented on Mar 7, 2024

@sff2578

It's cloudflare, i printed out the response that I'm getting on some of the API calls and it says this:

 <p data-translate="blocked_why_detail">This website is using a security service to protect itself from online attacks. The action you just performed triggered the security solution. There are several actions that could trigger this block including submitting a certain word or phrase, a SQL command or malformed data.</p>
          </div>

          <div class="cf-column">
            <h2 data-translate="blocked_resolve_headline">What can I do to resolve this?</h2>

            <p data-translate="blocked_resolve_detail">You can email the site owner to let them know you were blocked. Please include what you were doing when this page came up and the Cloudflare Ray ID found at the bottom of this page.</p>

full html here: https://pastebin.com/cTTAf8cb

I got this a few months ago, I wasn't able to figure out a solution, it just ended up going away after a while

How long did it take to work again?

ChenhaoranY

ChenhaoranY commented on Mar 8, 2024

@ChenhaoranY

same here, looks like when we try to access /accounts/login, server will give 403, maybe they have upgraded firewall or something. Also not sure why when I try to login with third party I got password incorrect

This is because if you try to use third party login, it will send a verify code to your mailbox. That's why it says password incorrect.

ChenhaoranY

ChenhaoranY commented on Mar 8, 2024

@ChenhaoranY

Same issue here :(

I'm using the cookie login but it's not working anymore.

login: (node:27208) Warning: Accessing non-existent property 'padLevels' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
cookie: - Retrieving user favorites
[WARN] Failed to retrieve user favorites: [object Object]
- Retrieving user profile
c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55
      let s = args.map(x => x.toString()).join(' ');
                              ^

TypeError: Cannot read properties of undefined (reading 'toString')
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:20)
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\commands\user.js:121:13
    at c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:523:14
    at Request._callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:422:19)
    at self.callback (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:185:22)
    at Request.emit (node:events:514:28)
    at Request.<anonymous> (c:\Users\XXXXX\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:1161:10)
    at Request.emit (node:events:514:28)

Node.js v18.17.1

Update:

Also It seems other folks are facing this issue as well, #478 (comment)

Have you solved this problem

jasoncyu

jasoncyu commented on Mar 8, 2024

@jasoncyu

It's cloudflare, i printed out the response that I'm getting on some of the API calls and it says this:

 <p data-translate="blocked_why_detail">This website is using a security service to protect itself from online attacks. The action you just performed triggered the security solution. There are several actions that could trigger this block including submitting a certain word or phrase, a SQL command or malformed data.</p>
          </div>

          <div class="cf-column">
            <h2 data-translate="blocked_resolve_headline">What can I do to resolve this?</h2>

            <p data-translate="blocked_resolve_detail">You can email the site owner to let them know you were blocked. Please include what you were doing when this page came up and the Cloudflare Ray ID found at the bottom of this page.</p>

full html here: https://pastebin.com/cTTAf8cb
I got this a few months ago, I wasn't able to figure out a solution, it just ended up going away after a while

How long did it take to work again?

I'm not sure, maybe a couple of days. I tried github sign in, linkedin signin, cookie signin, and all failed. I also tried this alternative: https://github.com/clearloop/leetcode-cli and I also had the exact same issue. Somehow Cloudflare is not letting me through. I also tried behind a VPN and also by manipulating my request headers so they are more similar to my browser's also no good.

fanzhangvivian

fanzhangvivian commented on Mar 8, 2024

@fanzhangvivian
TypeError: Cannot read properties of undefined (reading 'toString')
    at c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:31
    at Array.map (<anonymous>)
    at log.<computed> [as info] (c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\log.js:55:20)
    at c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\commands\user.js:121:13
    at c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:523:14
    at Request._callback (c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\vsc-leetcode-cli\lib\plugins\leetcode.js:422:19)
    at self.callback (c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:185:22)
    at Request.emit (node:events:519:28)
    at Request.<anonymous> (c:\Users\Fan Zhang\.vscode\extensions\leetcode.vscode-leetcode-0.18.1\node_modules\request\request.js:1161:10)
    at Request.emit (node:events:519:28)

Node.js v21.7.0``

I also met the problem. is there anybody solve it? I can't sign in leetcode in vscode for ten days.

berlinway

berlinway commented on Mar 8, 2024

@berlinway

same issue in Singapore, seems some day before, leetcode has been attacked and open some toggle.

garvit3835

garvit3835 commented on Mar 8, 2024

@garvit3835

Same issue. Can it be resolved by any way?

gregkonush

gregkonush commented on Mar 8, 2024

@gregkonush

maintainer has not been active, last commit was 2 years ago

berlinway

berlinway commented on Mar 8, 2024

@berlinway

find the root cause :) , leetcode website update http proto to allow HTTP/2, letcode-cli request still send http/1.1 request.

berlinway

berlinway commented on Mar 8, 2024

@berlinway

find the root cause :) , leetcode website update http proto to allow HTTP/2, letcode-cli request still send http/1.1 request.
if change all request to http/2, it should work well again. Will try to fix that.

57 remaining items

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

      Development

      No branches or pull requests

        Participants

        @robpodosek@jasoncyu@alexya@ryderfang@StevenJohnston

        Issue actions

          Circular Dependency · Issue #927 · LeetCode-OpenSource/vscode-leetcode