jonataslaw / get_cli

Official Getx CLI
Apache License 2.0
608 stars 179 forks source link

cannot create child page on module (windows) - NoSuchMethodError: The getter 'path' was called on null. #64

Open limsocheat opened 3 years ago

limsocheat commented 3 years ago

I want to create a child page on the parent page: get create page:takeaway_checkout on takeaway

But it created only empty folder with error message:

✖  + Folder .\lib\app\modules\takeaway\takeaway_checkout not found

Unhandled exception:
NoSuchMethodError: The getter 'path' was called on null.
Receiver: null
Tried calling: path
#0      Object.noSuchMethod (dart:core-patch/object_patch.dart:54:5)
#1      Structure.model (package:get_cli/core/structure.dart:68:20)
#2      handleFileCreate (package:get_cli/functions/create/create_single_file.dart:20:31)
#3      CreatePageCommand._writeFiles (package:get_cli/commands/impl/create/page/page.dart:76:26)
#4      CreatePageCommand.checkForAlreadyExists (package:get_cli/commands/impl/create/page/page.dart:69:7)
#5      CreatePageCommand.execute (package:get_cli/commands/impl/create/page/page.dart:33:5)
#6      main (file:///C:/Users/AKbalthom/AppData/Local/Pub/Cache/git/get_cli-c27ea6d11ec0efcd1c9f72ab3726467268ec0855/bin/get.dart:18:
23)
#7      _delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:281:32)
#8      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)

The page [takeaway_checkout] already exists, do you want to overwrite it?

  1) Yes!
  2) No
  3) I want to rename

Even I chose option 1(yes), it still creates an empty folder only.

na2axl commented 3 years ago

Hey, I've just installed get_cli today, but I have the same issue. Trying to run get create page:chats on home

✖  + Folder .\lib\app\modules\home\chats not found

Unhandled exception:
NoSuchMethodError: The getter 'path' was called on null.
Receiver: null
Tried calling: path
#0      Object.noSuchMethod (dart:core-patch/object_patch.dart:54:5)
#1      Structure.model (package:get_cli/core/structure.dart:68:20)
#2      handleFileCreate (package:get_cli/functions/create/create_single_file.dart:16:31)
#3      CreatePageCommand._writeFiles (package:get_cli/commands/impl/create/page/page.dart:67:26)
#4      CreatePageCommand.execute (package:get_cli/commands/impl/create/page/page.dart:51:13)
#5      main (file:///C:/Dev_Tools/flutter/.pub-cache/hosted/pub.dartlang.org/get_cli-1.4.5/bin/get.dart:15:23)
#6      _delayEntrypointInvocation.<anonymous closure> (dart:isolate-patch/isolate_patch.dart:281:32)
#7      _RawReceivePortImpl._handleMessage (dart:isolate-patch/isolate_patch.dart:184:12)
syw0602 commented 3 years ago

Me too

Cinux-Chosan commented 3 years ago

same error!

mma-amini commented 3 years ago

Me too

Charl0tter commented 3 years ago

Hasn't it been solved yet?

Charl0tter commented 3 years ago

@CpdnCristiano

CpdnCristiano commented 3 years ago

what's your version?

Charl0tter commented 3 years ago

你的版本是什么?

image

Charl0tter commented 3 years ago

你的版本是什么?

image

axu6705 commented 3 years ago

Not resolved yet

get create page:dialogview on home
✖  + Folder .\lib\app\data\home\dialogview not found

Time: 85 Milliseconds

The page [dialogview] already exists, do you want to overwrite it?

  1) Yes!
  2) No
  3) I want to rename
1
✖  + Folder .\lib\app\data\home\dialogview not found

Time: 55061 Milliseconds
CpdnCristiano commented 3 years ago

Hello, sorry for the delay in resolution, I currently have no windows to test

Shadiul commented 3 years ago

please fix it, pleaseeeeeeeee 😢

dragongesa commented 3 years ago

same here :(

dragongesa commented 3 years ago

any update guys?

airidwan commented 3 years ago

any update? Windows 10

shahidpharm commented 3 years ago

Same error to me. I am using windows 10

syssam commented 3 years ago

same here :(

agusprayogi02 commented 3 years ago

me too :(

deepss1 commented 3 years ago

This tool has been so great however I am facing the same error.

deepss1 commented 3 years ago

Alright, I have found a workaround.

get create page:'module_name'/sub_module_name

Eg.

You want to create a sub module takeaway_checkout in takeaway

The command will be as follows :

get create page:takeaway/takeaway_checkout

This was only tested on Windows 11.