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

Apiv1 fixes #34

Merged
merged 4 commits into from
May 17, 2013
Merged

Apiv1 fixes #34

merged 4 commits into from
May 17, 2013

Conversation

sneakypete81
Copy link
Contributor

Workarounds to support APIv1 properly.

Add OPENPHOTO_TEST_SERVER_API env var, to allow testing to be restricted to a specific maximum API version. This allows new API testcases to be skipped for old servers.

Explicitly remove tags from photos during tag testing. The tag create/delete API endpoints seem to be for internal use only, so these tests are a little contrived.

To allow testing to be restricted to a specific maximum API version.
This allows new API tests to be skipped for old servers.
Conflicts:
	tests/test_base.py
	tests/test_framework.py
@jmathai
Copy link
Member

jmathai commented May 11, 2013

Let me look into the create/delete API before confirming your assumption.

@sneakypete81
Copy link
Contributor Author

@jmathai: thanks, I raised a PR on the documentation to mark the tag create/delete endpoints as "Internal", since I'm not sure that they're actually useful for an API user. 

tag/create has no user-visible effect - the new tag doesn't appear in the tag list, since it's not associated with any photos. Better to just use photo/update?addTags.

From memory, tag/delete doesn't remove the tags from each photo. Better to use photo/update?removeTags on each photo. 

I've left these endpoints defined in the python bindings for completeness, but perhaps it would actually be best to remove them to avoid confusion?

@sneakypete81
Copy link
Contributor Author

@jmathai: is this still blocked?

I think photo/documentation#14 might be a better place to continue the tag API discussion.

@jmathai
Copy link
Member

jmathai commented May 17, 2013

As I suspected, the /tag/create.json API isn't used anymore. I've removed it from the development branch so we can clean up this lib up by removing support/tests for it as well.

jmathai added a commit that referenced this pull request May 17, 2013
@jmathai jmathai merged commit a2d103e into photo:master May 17, 2013
@sneakypete81 sneakypete81 deleted the apiv1_fixes branch May 18, 2013 11:54
@sneakypete81
Copy link
Contributor Author

As I suspected, the /tag/create.json API isn't used anymore. I've removed it from the development branch so we can clean up this lib up by removing support/tests for it as well.

@jmathai: /tag/create.json is still present on the development branch. Are you sure you deleted it?

What about /tag/delete.json - this also seems redundant - it apprears that tags can only be deleted by removing them from photos with photo/update.json.

See also /photo/frontend#986, /photo/frontend#987, #38, /photo/documentation#14

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

Successfully merging this pull request may close these issues.

2 participants