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

BlenderBIM: Possible to change the path of the 'data' folder? #976

Closed
theoryshaw opened this issue Sep 4, 2020 · 6 comments
Closed

BlenderBIM: Possible to change the path of the 'data' folder? #976

theoryshaw opened this issue Sep 4, 2020 · 6 comments

Comments

@theoryshaw
Copy link
Member

theoryshaw commented Sep 4, 2020

Possible to change the path of the 'data' folder?

That is, change the path AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\data to somewhere else?

Helpful, obviously, for project specific documentation that you can save to a repo.

@Moult
Copy link
Contributor

Moult commented Sep 4, 2020

Yes, in theory, it can be done here - however, I think there were one or two places in the code where I do not correctly read the user-defined parameter... so keep a very close eye out for bugs if you do change it. I expect there to be bugs.

image

@Moult Moult closed this as completed Sep 4, 2020
@theoryshaw
Copy link
Member Author

theoryshaw commented Sep 5, 2020

once such bug after trying to create a drawing...

Traceback (most recent call last):
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\operator.py", line 2224, in execute
    svg_writer.write()
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\svgwriter.py", line 55, in write
    self.add_stylesheet()
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\svgwriter.py", line 73, in add_stylesheet
    with open('{}styles/{}.css'.format(self.ifc_cutter.data_dir, self.ifc_cutter.vector_style), 'r') as stylesheet:
FileNotFoundError: [Errno 2] No such file or directory: 'D:\\Dropbox\\GitHub\\OD_Library\\BIM\\BlenderBIM\\datastyles/default.css'

location: <unknown location>:-1


@theoryshaw
Copy link
Member Author

another one..

Traceback (most recent call last):
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\operator.py", line 2223, in execute
    ifc_cutter.cut()
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\cut_ifc.py", line 197, in cut
    self.get_product_shapes()
  File "C:\Users\ryan\AppData\Roaming\Blender Foundation\Blender\2.83\scripts\addons\blenderbim\bim\cut_ifc.py", line 336, in get_product_shapes
    with open(shape_pickle, 'wb') as shape_file:
FileNotFoundError: [Errno 2] No such file or directory: 'D:\\Dropbox\\GitHub\\OD_Library\\BIM\\BlenderBIM\\data\\OD_BlenderBIM_Template.blend\\cache\\shapes\\OD_BlenderBIM_Template.blend.ifc.pickle'

location: <unknown location>:-1


@Moult
Copy link
Contributor

Moult commented Sep 5, 2020

@theoryshaw when you change the data_dir, for now, you need to copy over all relevant default settings. The easiest way to do this is to copy the entire default data dir to a new location prior to changing.

I am slowly cleaning up the data_dir to make it leaner, which would make it easier to switch to an almost blank folder. Hope it makes sense.

@theoryshaw
Copy link
Member Author

theoryshaw commented Sep 5, 2020

I did, I ended up copying everything in the data directory over to the new location. These errors still resulted.

@Moult
Copy link
Contributor

Moult commented Sep 5, 2020

D:\\Dropbox\\GitHub\\OD_Library\\BIM\\BlenderBIM\\datastyles/default.css - looks like it has a missing "/" after data - try add that.

@Moult Moult reopened this Sep 5, 2020
@Moult Moult closed this as completed in 478612b May 28, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants