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

pymkup throws 'column_data' error #29

Open
ghost opened this issue Dec 22, 2022 · 3 comments
Open

pymkup throws 'column_data' error #29

ghost opened this issue Dec 22, 2022 · 3 comments

Comments

@ghost
Copy link

ghost commented Dec 22, 2022

All of a sudden every time I try to use this I get a:

Exception has occurred: ModuleNotFoundError
No module named 'column_data'
File "\pymkupTest.py", line 1, in
from pymkup import *

The module is for sure in the packages folder...
pymkup\column_data.py

I'm not quite fancy enough to figure out what's going on since the column_data package is there.

@Ianshaw93
Copy link

Ianshaw93 commented Apr 19, 2023

I also ran into this error. I moved the files into my local directory and then commented out line 15 of pymkup.py, see below. Then it appears to work.

    def __init__(self, file):
        try:
            self.file = file
            self.inpfn = dirname(realpath(__file__)) +"\\" + self.file # added '+ "\\"' to allow for document name to be entered 
            self.fd = open(self.inpfn, "rb")
            self.template_pdf = PDFDocument(self.fd)
            # Checking if the PDF was authored by BB
            # "Bluebeam" in self.template_pdf.metadata['Creator'] # comment out this line

            self.all_pages = [p for p in self.template_pdf.pages()]
            self.spaces_path = {}
        except Exception:
            print(self.inpfn, "doesnt exist.")```

@lynchdkyle
Copy link

lynchdkyle commented Apr 19, 2023

What do you mean by Local directory? @Ianshaw93

I also ran into this error. I moved the files into my local directory and then commented out line 15 of pymkup.py, see below. Then it appears to work.

@EdaAkaltun
Copy link

EdaAkaltun commented Sep 29, 2023

I also ran into this error. I moved the files into my local directory and then commented out line 15 of pymkup.py, see below. Then it appears to work.

    def __init__(self, file):
        try:
            self.file = file
            self.inpfn = dirname(realpath(__file__)) +"\\" + self.file # added '+ "\\"' to allow for document name to be entered 
            self.fd = open(self.inpfn, "rb")
            self.template_pdf = PDFDocument(self.fd)
            # Checking if the PDF was authored by BB
            # "Bluebeam" in self.template_pdf.metadata['Creator'] # comment out this line

            self.all_pages = [p for p in self.template_pdf.pages()]
            self.spaces_path = {}
        except Exception:
            print(self.inpfn, "doesnt exist.")```

I've followed exactly this but I'm still getting the same error. I've tried everything at this point even manually importing only the 3 python files. For some reason I can't get column_data,py used within the other scripts.

Any ideas what could be causing this? I really want to use this package :(

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

3 participants