mirror of
https://github.com/netbox-community/devicetype-library.git
synced 2024-11-25 09:54:10 +01:00
15a3e7a9d1
* Pytest Optimizations (#1465) * Adding function to determin file changes from upstream via git * updated test env function to properly skip when files are empty * updating to use generated slug list * fixing if statement * added known slugs functionality to improve runtime * updating slugs for using git repo * adding final changes * updating library url to be correct * Update master-slugs.yml * commit to force pr merge (#1466) * Pytest pr (#1467) * commit to force pr merge * commit to force pr merge * Update master-slugs.yml * Regenerate master slug list after successful PR merge * Update master-slugs.yml * fianl changes to new master slug workflow (#1468) * Final pr test (#1469) * fianl changes to new master slug workflow * trying new branch push * changing to myself (#1470) * testing permission on github_token * testing permission on github_token * testing permission on github_token --------- Co-authored-by: NetBox Bot <info@netboxlabs.com>
15 lines
336 B
Python
15 lines
336 B
Python
import pickle
|
|
|
|
def write_pickle_data(data, file_path):
|
|
with open(file_path, 'wb') as pickle_file:
|
|
pickle.dump(data, pickle_file)
|
|
pickle_file.close()
|
|
|
|
|
|
def read_pickle_data(file_path):
|
|
with open(file_path, 'rb') as pickle_file:
|
|
data = pickle.load(pickle_file)
|
|
pickle_file.close()
|
|
|
|
return data
|