Git Product home page Git Product logo

hyp's People

Contributors

adregan avatar goodwritehq avatar kalasjocke avatar sloria avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

hyp's Issues

JSON API RC3 tracking

Hey there! I just wanted to let you know that JSON API has hit RC3, and we'd like client libraries to start implementing it like it was 1.0, as a final check that we're good for 1.0. I wanted to make this issue to let you know!

json-api/json-api#484

Doesn't work with Python 3; remove hard dependencies?

Currently, hyp is not useable on Python 3 due to its hard dependency on schematics, which is Py2-only.

Example test failure on Py34:

tests/test_schematics_adapter.py:2: in <module>
    from schematics.models import Model
../../../miniconda/envs/hyp/lib/python3.4/site-packages/schematics/models.py:6: in <module>
    from .types import BaseType
../../../miniconda/envs/hyp/lib/python3.4/site-packages/schematics/types/__init__.py:1: in <module>
    from .base import *
../../../miniconda/envs/hyp/lib/python3.4/site-packages/schematics/types/base.py:56: in <module>
    class BaseType(TypeMeta('BaseTypeBase', (object, ), {})):
../../../miniconda/envs/hyp/lib/python3.4/site-packages/schematics/types/base.py:47: in __new__
    for attr_name, attr in attrs.iteritems():
E   AttributeError: 'dict' object has no attribute 'iteritems'

Would it be possible to remove hyp's hard dependencies on schematics and marshmallow and instead have users opt in to their preferred serialization library?

Using the example from the Readme NameError

I was having trouble defining my own linked section, so I copied the example out of the README and received the same error:

    json = PostResponder().respond(post, linked={'comments': comments})
NameError: global name 'comments' is not defined

comments should be post['comments'] to avoid the error and properly access the object.

Submitting a pull request to update the README

hyp does not seem to have a Marshmallow package.

I just installed hyp and I'm trying to use it in conjunction with Marshmallow to serialize my models but the 'hyp.marshmallow' package doesn't exist. How should I proceed? For the record I'm using python 3, Marshmallow (2.4.2), hyp (1.0.0), and Flask (0.10.1).

Thanks,
Bill

What version of marshmallow tutorial releates to?

I am trying to learn Python, I want to make a simple JSON API backend for private project "PassMan" (yeah, a password manager)
In my virtualenv I have:

(env) C:\workspace\pyczarm>pip list
click (6.6)
Flask (0.11.1)
hyp (1.0.0)
inflection (0.3.1)
itsdangerous (0.24)
Jinja2 (2.8)
MarkupSafe (0.23)
marshmallow (2.10.1)
pip (7.1.0)
pymongo (3.3.0)
schematics (1.1.1)
setuptools (18.1)
six (1.10.0)
Werkzeug (0.11.11)

Running this code:

from marshmallow import Schema, fields
from hyp.responder import Responder


class PasswordSchema(Schema):
    _id = fields.String()
    portal = fields.String()
    login = fields.String()
    password = fields.String()
    note = fields.String()


class PasswordResponder(Responder):
    TYPE = 'passwords'
    SERIALIZER = PasswordSchema

Gives me error:

Traceback (most recent call last):
  File "C:/workspace/pyczarm/passman.py", line 2, in <module>
    import models.Password
  File "C:\workspace\pyczarm\models\Password.py", line 3, in <module>
    from hyp.responder import Responder
  File "C:\workspace\pyczarm\env\lib\site-packages\hyp\responder.py", line 5, in <module>
    from hyp.adapters.base import adapter_for
  File "C:\workspace\pyczarm\env\lib\site-packages\hyp\adapters\base.py", line 4, in <module>
    from marshmallow import Serializer as MarshmallowSerializer
ImportError: cannot import name 'Serializer'

Could You please make appropriate updates?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.