grokability / jamf2snipe

Import and sync assets from a JAMFPro instance to Snipe-IT asset management.
MIT License
113 stars 55 forks source link

New Models get created, but assets do not get created in Snipe-IT #93

Closed bondurantdt closed 2 years ago

bondurantdt commented 2 years ago

When running the script finds the correct number of assets from JAMF, and will create a new model if needed in Snipe-IT, but it does not seem to create the asset.

INFO:root:Processing entry 1212 out of 1212 - JAMFID: 346 - NAME: ipad INFO:root:No assets match INFO:root:Creating a new asset in snipe for JAMF ID 346 - ipad

I'm using the current devel version.

Thanks!

bondurantdt commented 2 years ago

I spent a little time with this and it looks like the create_snipe_asset function is just not called unless an undocumented userarg is set, --auto_incrementing which does not seem to work either.

I worked around this for my own purpose and got it working for computers and devices, so I am good, but you will probably want to take a look at that block.

snipe commented 2 years ago

@inietov I don't know if you want to take a stab at this? It's python, so it's okay if it's not your jam. I can try to get @uberbrady to take a look instead.

nchester1151 commented 2 years ago

@bondurantdt How did you go about getting it to create assets? I am having the same issue?

bondurantdt commented 2 years ago

@nchester1151 I created/linked a PR that contains my edit/fix. Feel free to use.

senzou commented 2 years ago

Thanks @bondurantdt for the fix! Works like a charm.