Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error: <g> attribute transform: Expected number, "translate(Infinity,20)scale(1)". i @ d3.v3.min.js:1 #10

Open
ekaterina-lepunova opened this issue Jun 13, 2019 · 13 comments

Comments

@ekaterina-lepunova
Copy link

https://user-images.githubusercontent.com/23632733/59427977-a6ae2000-8de4-11e9-8242-d270c3266645.png

Hi! Can you please check it out? I'm not able to create nor html diagram neither json file of my database schema.

Thanks,
Kate

@perak
Copy link
Owner

perak commented Jun 13, 2019

Hi @KateKozlova can you please help to reproduce this issue?

@ekaterina-lepunova
Copy link
Author

@perak , thanks for the quick answer. Unfortunately I'm afraid I can't help. I just ran your app on my project with existing mongo db and it fails. I tried to run the app on a database with 1 and 2 schemas. It worked fine. However real db has 22 schemas. And it failed with empty html and empty json files. Probably you can give me a hint of a reason why it gave me an error to check schemas or something like this?

@ekaterina-lepunova
Copy link
Author

@perak , you know I also tried this app: https://www.dbschema.com. However this app even haven't seen my db at all. Probably it may help. However Mongo Db Compass Community app sucessfully finds and shows me my database.

@perak
Copy link
Owner

perak commented Jun 13, 2019

  • Did it show some errors while scanning database?
  • Can you share output files? (if output files are really empty, than no need to share)
  • when connected to the database, are you sure program has access to read database?
    ...
    Please provide as much info as you can

@perak
Copy link
Owner

perak commented Jun 13, 2019

Your last screenshot tells me that extract mongo schema package is not properly installed.
It is caused by dependency package used by this one.

I believe here is the solution of your trouble:

Screen Shot 2019-06-13 at 1 41 21 PM

It's something about compiling node-gyp under Windows. Do you have Linux or Mac somewhere (even in virtual machine?) - if so, please try running under Linux or Mac - it should work.

Hum... wait, you said that it worked with small database, but didn't work with "real" database? When it worked, did it worked on this machine? (the same machine where it cannot access "real" database)

@ekaterina-lepunova
Copy link
Author

@perak , yeah the last screenshot showed the error after my try of downloading the app's source code. I wanted to debug it myself but it failed during "npm install" command. the first two screenshots were made from CMD when I just installed the package and tried to run it against my database.

@perak
Copy link
Owner

perak commented Jun 13, 2019

I think I can't help.

@ekaterina-lepunova
Copy link
Author

ok, thanks.

@perak
Copy link
Owner

perak commented Jun 13, 2019

Sorry.

Problems on Windows are already reported before (and not fixed yet).

@ekaterina-lepunova
Copy link
Author

Hi, @perak , I found the issue. My mongo db was running in the docker container and the app couldn't connect to it. I ran the app inside container and it worked. However unfortunately no dependencies were shown. So it wan't informative for me.

@perak
Copy link
Owner

perak commented Jun 14, 2019

@KateKozlova program tries to automatically detects "links" by regex parsing the values, and it is made for specific case (I made it in need for one Meteor.js application). How your links look like? (I mean, is foreign key value numeric, or string... and if string, what length or format it is...). Maybe minimal change in the code can fit your needs.

@perak
Copy link
Owner

perak commented Jun 14, 2019

More specifically, this line: https://github.com/perak/extract-mongo-schema/blob/master/extract-mongo-schema.js#L51 tells program to check if string is foreign key only if it fits that regex rule. Wthout that condition, it will scan for links on each string (which could be slow, but functional).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants