Steve Petterborg

  • Content Count

  • Joined

  • Last visited

  • Days Won


Everything posted by Steve Petterborg

  1. That's how mine looks in the browser too. That particular endpoint is only used by the legacy API for XML-RPC. Two angles of attack are either adding some debug output to what Deadline is running (and seeing whether it sets os.environ['LOGNAME'] in case your login username is different than your ftrack username) or avoiding Deadline for now. Both their plugins and our API which they vendor are editable as .py files, though do consider backing them up before altering them. Alternately, make sure ftrack Connect works (as the current version utilizes the legacy API as well as the newer one) and consider a small stand-alone script just to make sure you can connect with the legacy API and your API key.
  2. Hi Yating, The Deadline integration is created/owned by Thinkbox/AWS. They recently switched from the legacy API (which uses XMLRPC) to the newer Python API. I believe the switch happened in 10.1 and has been stable since Is it possible for you to upgrade versions? In either case, I don't recall where the Deadline integration is getting an ftrack username. Even when using a "global" API key, an API session but be initialized with the username of an enabled User. I believe we fall back to LOGNAME if nothing is set explicitly in the constructor. For the 404 error, can you access that URL with curl from the command line? Or from your browser?
  3. Hi Jen, We use Thumbor to dynamically create the thumbnails, so I think you'd have to edit the URL to include a fill filter. Unfortunately we don't really support that -- we can point to a different Thumbor server than the default, but the part where we format the string is hardcoded to just have the "fit-in" directive. Maybe there's a way to force Thumbor to always apply a filter? That may very well not be an option (quick browse of the Thumbor docs didn't turn up anything). I could see our exposing a config var along the lines of "extra_thumbor_url_bits".
  4. You're self-hosting, right? There are a couple things you'd have to do to make the server handle it "natively". One is create a setting, ftrack.image_conversion_formats, a comma-delimited list of supported formats. The other is update or replace the image-encoder service to handle .ai files. We use the ImageMagick tool, convert, which should support .ai files with some added dependencies. I have not personally tried the above steps.
  5. "show" and "task" are legacy identifiers, roughly corresponding to Project and TypedContext in the new API. session.get('Context', id) should return the most-specific class available for the given it. In my demo content, I have the following parent types: appointment asset assetversion asset_version dependency list note review_session review_session_object review_session_object_status show task One of the original designers might have to confirm, but I believe that we only persist to the db Events which trigger a notification/will be rendered in the UI. AFIAK, creating a user does not do this.
  6. Hi Jen, How are you uploading these files, and can you run the encoding client-side somehow? We have an example of using ftrack Connect to publish image sequences which are rendered as a movie by ffmpeg and then uploaded as the ftrackreview-mp4 component. If you're not using Connect, you could do something similar with an event listener watching for new publishes.
  7. You can do a subquery (bottom of the page here which would look like 'Event where created_at > (select created_at from Event where id is "{}")' As an aside, also take a look at the section on "projections". The two lines you pasted actually do three requests in the case where the "created_at" attribute wasn't yet cached. To avoid that automatic call, you can request all the attributes you'll need all at once like so: event = session.query('select created_at from Event where id is "{}"'.format(event_id)).first() events = session.query('Event where created_at > "{}"'.format(event['created_at']))
  8. Hi Johannes, Towards the bottom of this page (search for "subclass") we show some examples of casting a result to a single type: In your case, I believe you query string would be: "AssetVersion where task.assignments.resource[User] is {}"
  9. A Component can only be associated with a single AssetVersion. You might be able to re-use the resource_identifier in a ComponentLocation but I'm not sure I'd recommend it. What's your use case anyway?
  10. Hi Matthieu, you also need to set FTRACK_API_USER (or LOGNAME / whatever it takes to make getpass.getuser() return the right username).
  11. Hi Jen, I've just tagged your Zendesk / ftrack help center account so you should be able to access that link now. If you'd like any other members of your team to have access as well, please send us a list at -Steve
  12. Hi Fernando, Is it possible you have cached the old value for the status? You could clear the cached value and query again to ensure that you're getting the latest value from the server. See these two lines I've added above your "state = . . ." line. del link['from']['status'] link.session.populate(link['from'], 'status') state = link['from']['status']['state']['short']
  13. Hi Ozen, I wouldn't rely on their being a stable sort order in the internal review. (Consider the case of selecting multiple versions of an Asset. Then there will not even be as many items on the timeline as you had clicked.) Client reviews do have an ordering (which you can drag and drop to re-order or use the API to set the sort_order attribute directly). I'm afraid we might have to file it as a feature request, having an order-able list of clips in the experimental internal review tool.
  14. Indeed you currently have to filter in the callback.
  15. Cool! Take a look at this if you don't want to hand out that highly-provisioned API key to everyone,75:76,84,87,92,95,100,103
  16. How's the user running this tool? Is there one persistent process running in a central location or is it more like a short-lived command invoked on the command line? Are you using ftrack Connect? Just the web UI? Depending on your use-case, either running your tool as a plugin in Connect, pulling the API key from the config file written by Connect, or using the method demonstrated by Connect to use an authenticated browser session to generate a new API key all sound like good options. If you're exposing this tool as a web page or widget itself, you could embed that in a dashboard and pull API credentials there too. Also, and I don't necessarily suggest this, a global API key can have the permissions to manage User's API keys, so you could generate a new one for each of your users, store them, then create sessions as needed. Be careful not to revoke their existing keys as that will log them out of Connect.
  17. Hi Tony, What's your use case exactly? As you've found, the global API keys are not limited by the role(s) assigned to the user's whose username you use to instantiate your session.
  18. I've seen this exact error where some tool imports it's own version of (some portion of) backports, which then masks (maybe "masks" is not the correct word since it's encountered first) the particular portion that we (or our dependencies need). I'm glad the re-installation/downgrading solved it since I don't have a great general solution to the issue.
  19. Hi Peter, The simplest solution is to use session.ensure() if there's a chance the object exists already. In any case, that line alone won't implicitly create any parents, so I read the error as a not very clear version of "can't create Task, as one with the same name already exists with that same parent".
  20. del asset_version['notes'] session.populate(asset_version, 'notes') This missing piece here was clearing the cached value of the collection attribute.
  21. Hi Lise, Unfortunately not. You're looking to record or transfer from one Role to another Role? It may be the next thing we tackle now that ProjectSchemas are supported in the API.
  22. Hi Andriy, session.api_user is a username, not an id, so your line should instead read: target='applicationId=ftrack.client.web and user.username="{0}"'.format( Also, when setting "synchronous" to True, only the listeners registered with that specific local instance of Python (i.e. plugins whose register() methods were called when the session was created) will be notified--there is no communication across the network or even between processes. I hope that helps! Let us know if you have further questions.
  23. Hi Janis, Which browser/os/and part of ftrack are you seeing the issue with? I tried a quick test in Chrome on macOS and Windows 10 in the task spreadsheet and while editing a note and I didn't notice anything surprising.
  24. Hi Ozen, If you mean grouping by types, this might help: Unfortunately I don't believe you can limit a view to a particular type however.
  25. Hey Peter, nice work! I've been thinking about something like this myself--I love tab-completable everything and am excited to give this a try.