pisaiah / Vide

An simple IDE for V made in V.
https://discord.gg/NruVtYBf5g
MIT License
114 stars 10 forks source link

"iui.hc module not found" error when building Vide #7

Open Durobot opened 1 year ago

Durobot commented 1 year ago

V full version: V 0.3.2 d257e43.1cde554 OS: Windows 10 Enterprise 1809, build 17763.1935

What did you do?

What did you expect to see?

What did you see instead?

src/ide.v:6:1: builder error: cannot import module "iui.hc" (not found)
    4 | import iui as ui
    5 | import os
    6 | import iui.hc
      | ~~~~~~~~~~~~~
    7 |
    8 | const (
athrvvvv commented 1 year ago

It's causing issue because V installs the library inside the authorname For ex. (https://vpm.vlang.io/mod/IsaiahPatton.iui) this is the iui V module, now when you have to install it via:

v install IsaiahPatton.iui

So now, you will get such meesage...

image

So now to use in your project you have to do:

import isaiahpatton.iui as iui

// You can make use of module now

I solved the this error by the above method but I could'nt build the application.. got multiple errors!! @Durobot did you build it??

Durobot commented 1 year ago

@athrvvvv I have removed iui and ui modules I had installed, then installed iui with v install IsaiahPatton.iui. Then I had to replace import iui as ui with import isaiahpatton.iui as ui in code_suggest.v, config.v, draw_events.v and ide.v But now I'm getting this error:

src/ide.v:7:1: builder error: cannot import module "iui.hc" (not found)
    5 | import isaiahpatton.iui as ui
    6 | import os
    7 | import iui.hc
      | ~~~~~~~~~~~~~

I have tried several modifications of this import, e.g. import isaiahpatton.iui.hc as iui.hc, import ui.hc as iui.hc, import ui.hc, but nothing has worked so far. For example, the last variant gives this error:

src/ide.v:8:1: builder error: cannot import module "ui.hc" (not found)
    6 | import os
    7 | //import iui.hc
    8 | import ui.hc
      | ~~~~~~~~~~~~
athrvvvv commented 1 year ago

As I mentioned, I too got multiple errors. To be honest v modules are shitty now....

Durobot commented 1 year ago

Well, turns out I was using an old version of Vide. I have downloaded a snapshot of the project again, replaced every instance of import iui as ui with import isaiahpatton.iui as ui (these lines are in every .v file in the project), v run . spewed a bunch of warnings, but lo and behold - Vide is finally running!

athrvvvv commented 1 year ago

So now close this issue, you dumbass

Durobot commented 1 year ago

So now close this issue

Not before @IsaiahPatton fixes Vide, so that it builds without having to modify every .v file in the project.

you dumbass

Do we know each other in real life? Or you just enjoy being rude to people on the internet?

athrvvvv commented 1 year ago

Do we know each other in real life? Or you just enjoy being rude to people on the internet?

Iam really sorry batman

pisaiah commented 1 year ago

Not before @IsaiahPatton fixes Vide, so that it builds without having to modify every .v file in the project.

if you install iui via the Github url, you shouldn't have to modifiy every file. v install https://github.com/isaiahpatton/ui