url
stringlengths
53
56
repository_url
stringclasses
1 value
labels_url
stringlengths
67
70
comments_url
stringlengths
62
65
events_url
stringlengths
60
63
html_url
stringlengths
41
46
id
int64
450k
1.69B
node_id
stringlengths
18
32
number
int64
1
2.72k
title
stringlengths
1
209
user
dict
labels
list
state
stringclasses
1 value
locked
bool
2 classes
assignee
null
assignees
list
milestone
null
comments
list
created_at
timestamp[s]
updated_at
timestamp[s]
closed_at
timestamp[s]
author_association
stringclasses
3 values
active_lock_reason
stringclasses
2 values
body
stringlengths
0
104k
reactions
dict
timeline_url
stringlengths
62
65
performed_via_github_app
null
state_reason
stringclasses
2 values
draft
bool
2 classes
pull_request
dict
https://api.github.com/repos/coleifer/peewee/issues/1818
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1818/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1818/comments
https://api.github.com/repos/coleifer/peewee/issues/1818/events
https://github.com/coleifer/peewee/issues/1818
393,637,118
MDU6SXNzdWUzOTM2MzcxMTg=
1,818
SQLite not respecting CharField or FixedCharField max_length
{ "login": "stigok", "id": 952936, "node_id": "MDQ6VXNlcjk1MjkzNg==", "avatar_url": "https://avatars.githubusercontent.com/u/952936?v=4", "gravatar_id": "", "url": "https://api.github.com/users/stigok", "html_url": "https://github.com/stigok", "followers_url": "https://api.github.com/users/stigok/follow...
[]
closed
false
null
[]
null
[ "> Values that exceed length are not truncated automatically.\r\n\r\nAs that says, values that exceed length **are not truncated**.\r\n\r\nI'd suggest that you should familiarize yourself with the database you're using, sqlite in this case: https://sqlite.org/datatype3.html\r\n\r\nSqlite has the following data-type...
2018-12-22T02:57:25
2018-12-22T21:16:06
2018-12-22T16:50:39
NONE
null
```python from peewee import * database = SqliteDatabase(':memory:') class User(Model): class Meta: database = database username = CharField(max_length=21) database.create_tables([User]) username = 'a' * 42 assert len(username) == 42 u = User.create(username=username) assert u.usern...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1818/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1818/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1817
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1817/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1817/comments
https://api.github.com/repos/coleifer/peewee/issues/1817/events
https://github.com/coleifer/peewee/issues/1817
392,958,318
MDU6SXNzdWUzOTI5NTgzMTg=
1,817
Do I need additional steps to use ArrayField?
{ "login": "msdos", "id": 489034, "node_id": "MDQ6VXNlcjQ4OTAzNA==", "avatar_url": "https://avatars.githubusercontent.com/u/489034?v=4", "gravatar_id": "", "url": "https://api.github.com/users/msdos", "html_url": "https://github.com/msdos", "followers_url": "https://api.github.com/users/msdos/followers"...
[]
closed
false
null
[]
null
[ "See 04aa7a0 for the fix.", "Is this planned to a 3.8.1 release? The fix was really fast, thanks.", "I'll release this fix along with 3.8.1 at some point in the coming days/weeks.\r\n\r\nIn the meantime there are a number of workarounds. The simplest being instead of using `.get()` with keyword arguments, use e...
2018-12-20T09:28:47
2018-12-20T16:35:39
2018-12-20T15:34:58
NONE
null
I'm trying to use the `ArrayField` from Postgresql but I can't use your `get` method. Here is a proof of concept of the problem I'm facing it (I adapted the sample code from an old issue here in the repository): ```python #!/usr/bin/env python from peewee import Model from peewee import TextField from playhous...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1817/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1817/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1816
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1816/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1816/comments
https://api.github.com/repos/coleifer/peewee/issues/1816/events
https://github.com/coleifer/peewee/issues/1816
392,595,972
MDU6SXNzdWUzOTI1OTU5NzI=
1,816
Unable to create model with ManyToManyField
{ "login": "skopz356", "id": 36794259, "node_id": "MDQ6VXNlcjM2Nzk0MjU5", "avatar_url": "https://avatars.githubusercontent.com/u/36794259?v=4", "gravatar_id": "", "url": "https://api.github.com/users/skopz356", "html_url": "https://github.com/skopz356", "followers_url": "https://api.github.com/users/sko...
[]
closed
false
null
[]
null
[ "Read the docs: http://docs.peewee-orm.com/en/latest/peewee/relationships.html#manytomany\r\n\r\nAnd: http://docs.peewee-orm.com/en/latest/peewee/relationships.html#manytomanyfield", "I read the docs many times, but i still did not find what am i doing bad?" ]
2018-12-19T13:13:06
2018-12-19T13:50:46
2018-12-19T13:43:35
NONE
null
Hi, I am using mysql version 5.7.24 and when i try to create Model with ManyToMany relations i got error: ``` raise errorclass(errno, errval) peewee.IntegrityError: (1048, "Column 'chat_id' cannot be null") ``` Here is my code: ``` class User(BaseModel): name = peewee.CharField() surname ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1816/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1816/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1815
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1815/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1815/comments
https://api.github.com/repos/coleifer/peewee/issues/1815/events
https://github.com/coleifer/peewee/issues/1815
392,387,733
MDU6SXNzdWUzOTIzODc3MzM=
1,815
.on_conflict() update parameter does not adapt dicts (Postgres)
{ "login": "lohrmann", "id": 5954956, "node_id": "MDQ6VXNlcjU5NTQ5NTY=", "avatar_url": "https://avatars.githubusercontent.com/u/5954956?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lohrmann", "html_url": "https://github.com/lohrmann", "followers_url": "https://api.github.com/users/lohrm...
[]
closed
false
null
[]
null
[ "As a temporary workaround, try using the actual field objects instead of the field-names as strings, e.g.:\r\n\r\n```python\r\nrecord = {\r\n Session.someid: 'textid',\r\n Session.tstp: datetime.datetime(2018, 12, 12),\r\n Session.data: {},\r\n}\r\n```", "Fixed by f59ee6d" ]
2018-12-19T00:06:54
2018-12-19T03:34:01
2018-12-19T03:31:49
NONE
null
When a record includes dictionary data for a JSONB column in postgres, the data is correctly adapted in insert or update statements, but fails to be adapted as part of the .on_conflict() clause's update parameter. The following (simplified) record = {'someid': 'textid', 'tstp': datetime(2018, 12, 12, 15, 30, ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1815/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1815/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1814
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1814/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1814/comments
https://api.github.com/repos/coleifer/peewee/issues/1814/events
https://github.com/coleifer/peewee/issues/1814
392,253,014
MDU6SXNzdWUzOTIyNTMwMTQ=
1,814
Slower insert_many performance relative to sqlite3 executemany
{ "login": "rpadmanabhan", "id": 7334318, "node_id": "MDQ6VXNlcjczMzQzMTg=", "avatar_url": "https://avatars.githubusercontent.com/u/7334318?v=4", "gravatar_id": "", "url": "https://api.github.com/users/rpadmanabhan", "html_url": "https://github.com/rpadmanabhan", "followers_url": "https://api.github.com...
[]
closed
false
null
[]
null
[ "Only 2x is really not as bad as I might have thought.\r\n\r\nYes, it's because peewee contains logic for converting python data-types to data-types that can be handled by the database. For example, if you're using `TimestampField` you work with `datetime` objects in Python code, but when it comes to interacting wi...
2018-12-18T17:10:08
2018-12-18T21:00:29
2018-12-18T17:18:24
NONE
null
Thank you for developing peewee, it is a great lightweight ORM ! I am inserting batches in peewee like this : ```python import peewee db = peewee.SqliteDatabase('test_db.sqlite3',pragmas={'synchronous': 0,' 'journal_mode':'wal'}) with db.atomic(): # 10000 rows in this transaction for batch in peewee.ch...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1814/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1814/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1813
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1813/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1813/comments
https://api.github.com/repos/coleifer/peewee/issues/1813/events
https://github.com/coleifer/peewee/pull/1813
390,864,550
MDExOlB1bGxSZXF1ZXN0MjM4NTM1ODEx
1,813
setdefault added to playhouse kv, for dict like setdefault behavior
{ "login": "ascourge21", "id": 9159496, "node_id": "MDQ6VXNlcjkxNTk0OTY=", "avatar_url": "https://avatars.githubusercontent.com/u/9159496?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ascourge21", "html_url": "https://github.com/ascourge21", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "Thnx." ]
2018-12-13T21:20:12
2018-12-23T01:15:16
2018-12-14T10:33:15
CONTRIBUTOR
null
To make KeyValue behave more like the regular python dict, a setdefault is also added. This is a feature that we regularly use in our team when the db isn't initialized with any value, especially for settings and config items.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1813/reactions", "total_count": 1, "+1": 1, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1813/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1813", "html_url": "https://github.com/coleifer/peewee/pull/1813", "diff_url": "https://github.com/coleifer/peewee/pull/1813.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1813.patch", "merged_at": "2018-12-14T10:33:15" }
https://api.github.com/repos/coleifer/peewee/issues/1812
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1812/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1812/comments
https://api.github.com/repos/coleifer/peewee/issues/1812/events
https://github.com/coleifer/peewee/issues/1812
390,404,721
MDU6SXNzdWUzOTA0MDQ3MjE=
1,812
Broken DeferredForeignKey inheritance
{ "login": "NicolasCaous", "id": 24411365, "node_id": "MDQ6VXNlcjI0NDExMzY1", "avatar_url": "https://avatars.githubusercontent.com/u/24411365?v=4", "gravatar_id": "", "url": "https://api.github.com/users/NicolasCaous", "html_url": "https://github.com/NicolasCaous", "followers_url": "https://api.github.c...
[]
closed
false
null
[]
null
[ "Thanks for the report, I will look into it.", "I would like to contribute in a solution as well, but it's hard to understand how the project is structured. Do you have any tips for where to begin?", "The code's only a few thousand lines, definitely readable in one sitting. You can ignore everything except `pee...
2018-12-12T20:54:40
2018-12-13T15:00:18
2018-12-13T14:54:31
NONE
null
This is quite a complicated issue. I will try to do my best to give as much information as possible. ## The code ``` from peewee import * from models.base_model import BaseModel, BaseHistory class Company(BaseModel): teste = TextField() user = DeferredForeignKey('User', null=True) class CompanyH...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1812/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1812/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1811
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1811/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1811/comments
https://api.github.com/repos/coleifer/peewee/issues/1811/events
https://github.com/coleifer/peewee/issues/1811
390,149,673
MDU6SXNzdWUzOTAxNDk2NzM=
1,811
Update requirements.txt
{ "login": "denysthegitmenace", "id": 10329935, "node_id": "MDQ6VXNlcjEwMzI5OTM1", "avatar_url": "https://avatars.githubusercontent.com/u/10329935?v=4", "gravatar_id": "", "url": "https://api.github.com/users/denysthegitmenace", "html_url": "https://github.com/denysthegitmenace", "followers_url": "https...
[]
closed
false
null
[]
null
[ "+ add `micawber` dependency", "thx, updated." ]
2018-12-12T10:02:53
2018-12-13T12:37:20
2018-12-13T12:37:15
NONE
null
Hi! Thank you so much for this useful repo. `Beautifulsoup` in `examples/blog/requirements.txt` should be udpated to `beautifulsoup4`.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1811/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1811/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1810
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1810/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1810/comments
https://api.github.com/repos/coleifer/peewee/issues/1810/events
https://github.com/coleifer/peewee/issues/1810
390,144,544
MDU6SXNzdWUzOTAxNDQ1NDQ=
1,810
Different result with 'or' - '|'
{ "login": "BreX900", "id": 44398785, "node_id": "MDQ6VXNlcjQ0Mzk4Nzg1", "avatar_url": "https://avatars.githubusercontent.com/u/44398785?v=4", "gravatar_id": "", "url": "https://api.github.com/users/BreX900", "html_url": "https://github.com/BreX900", "followers_url": "https://api.github.com/users/BreX90...
[]
closed
false
null
[]
null
[ "Read the docs:\r\n\r\nhttp://docs.peewee-orm.com/en/latest/peewee/query_operators.html\r\n" ]
2018-12-12T09:50:20
2018-12-12T13:02:45
2018-12-12T13:02:45
NONE
null
I'm not very good at English. I will show the error with two examples. The same examples should show the same result but it is not... `#first example f = (Product.asin_product=="NameOne") f = f | (Product.asin_product=="NameTwo") Product.select().where(f).execute() #peewee - DEBUG - ('SELECT "t1"."asin_product" ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1810/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1810/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1809
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1809/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1809/comments
https://api.github.com/repos/coleifer/peewee/issues/1809/events
https://github.com/coleifer/peewee/issues/1809
389,533,616
MDU6SXNzdWUzODk1MzM2MTY=
1,809
Common Table Expressions and .count()
{ "login": "christopherhesse", "id": 440336, "node_id": "MDQ6VXNlcjQ0MDMzNg==", "avatar_url": "https://avatars.githubusercontent.com/u/440336?v=4", "gravatar_id": "", "url": "https://api.github.com/users/christopherhesse", "html_url": "https://github.com/christopherhesse", "followers_url": "https://api....
[]
closed
false
null
[]
null
[ "Ahh, yeah, `count()` appears not to be taking into consideration the fact that the query has a CTE. This is a usage I hadn't considered.\r\n\r\nI'd suggest just modifying your own SQL in the meantime as a workaround, e.g., to get the count, just write a query that looks like `.select(fn.COUNT(...))`.", "Thanks f...
2018-12-10T23:35:29
2019-01-30T20:37:15
2019-01-30T18:26:17
NONE
null
Hey, thank for writing this great library! I'm trying to use a CTE and .count() and it's not clear to me if this is supposed to work: ```py from peewee import * import datetime db = PostgresqlDatabase('peeweetest') class BaseModel(Model): class Meta: database = db # the user model specifi...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1809/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1809/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1808
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1808/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1808/comments
https://api.github.com/repos/coleifer/peewee/issues/1808/events
https://github.com/coleifer/peewee/issues/1808
389,410,427
MDU6SXNzdWUzODk0MTA0Mjc=
1,808
Migrator missing not null column during column removal
{ "login": "frdfsnlght", "id": 417767, "node_id": "MDQ6VXNlcjQxNzc2Nw==", "avatar_url": "https://avatars.githubusercontent.com/u/417767?v=4", "gravatar_id": "", "url": "https://api.github.com/users/frdfsnlght", "html_url": "https://github.com/frdfsnlght", "followers_url": "https://api.github.com/users/f...
[]
closed
false
null
[]
null
[ "Oh, I should have mentioned, I'm using SQLite.", "Ahh, yeah, its these lines that are causing the issue:\r\n\r\nhttps://github.com/coleifer/peewee/blob/3634aea5ece71e21a2ac5cdb2b74b194e8257960/playhouse/migrate.py#L682-L685", "It appears that if I rename my 'primaryName' column, the problem goes away (as long ...
2018-12-10T17:35:47
2018-12-10T22:28:09
2018-12-10T22:28:09
NONE
null
I have a model I've been using successfully for while: ```python class Drink(Model): primaryName = CharField() secondaryName = CharField(null = True) glass = ForeignKeyField(Glass, backref = 'drinks') instructions = TextField(null = True) isFavorite = BooleanField(default = False) isAl...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1808/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1808/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1807
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1807/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1807/comments
https://api.github.com/repos/coleifer/peewee/issues/1807/events
https://github.com/coleifer/peewee/issues/1807
388,782,292
MDU6SXNzdWUzODg3ODIyOTI=
1,807
Backref of ManyToManyField does not respect through_model foreign keys
{ "login": "albireox", "id": 568775, "node_id": "MDQ6VXNlcjU2ODc3NQ==", "avatar_url": "https://avatars.githubusercontent.com/u/568775?v=4", "gravatar_id": "", "url": "https://api.github.com/users/albireox", "html_url": "https://github.com/albireox", "followers_url": "https://api.github.com/users/albireo...
[]
closed
false
null
[]
null
[ "Not sure if it's the correct solution but it seems that making\r\n\r\n```python\r\n return (ManyToManyQuery(instance, self, self.rel_model)\r\n .join(self.through_model)\r\n .join(self.model)\r\n .where(self.src_fk == getattr(insta...
2018-12-07T19:22:54
2018-12-07T22:33:13
2018-12-07T22:33:13
NONE
null
I have a database with two tables, `GaiaDR2Source` and `TwoMassPsc`, and a cross-match/relation table, `GaiaDR2TmassBestNeighbour`. In `GaiaDR2Source` I create a many-to-many relation using `GaiaDR2TmassBestNeighbour` as through model. The match happens using `GaiaDR2Source.source_id` (which is the pk) and `TwoMassPsc....
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1807/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1807/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1806
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1806/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1806/comments
https://api.github.com/repos/coleifer/peewee/issues/1806/events
https://github.com/coleifer/peewee/issues/1806
388,526,357
MDU6SXNzdWUzODg1MjYzNTc=
1,806
DeferredManyToManyField
{ "login": "albireox", "id": 568775, "node_id": "MDQ6VXNlcjU2ODc3NQ==", "avatar_url": "https://avatars.githubusercontent.com/u/568775?v=4", "gravatar_id": "", "url": "https://api.github.com/users/albireox", "html_url": "https://github.com/albireox", "followers_url": "https://api.github.com/users/albireo...
[]
closed
false
null
[]
null
[ "As you noticed, there's no such thing as a `DeferredManyToManyField`, nor do I think there needs to be. Remember that a many-to-many is just a junction table with foreign-keys to the table(s) being related via many-to-many. To use my favorite example,\r\n\r\n```python\r\n\r\nclass Student(Model):\r\n name = Tex...
2018-12-07T06:44:54
2018-12-07T21:32:48
2018-12-07T21:32:47
NONE
null
I hit a case in which I'd have liked to be able to use a `DeferredManyToManyField` with a `DeferredThroughModel`. In my case I was able to fix it rearranging the order of the model classes so that the `ManyToManyField` would not need to point to a deferred model, but I wonder if that will always be the case. Ultimat...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1806/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1806/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1805
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1805/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1805/comments
https://api.github.com/repos/coleifer/peewee/issues/1805/events
https://github.com/coleifer/peewee/issues/1805
388,467,967
MDU6SXNzdWUzODg0Njc5Njc=
1,805
ManyToManyField and backref='+' fails
{ "login": "albireox", "id": 568775, "node_id": "MDQ6VXNlcjU2ODc3NQ==", "avatar_url": "https://avatars.githubusercontent.com/u/568775?v=4", "gravatar_id": "", "url": "https://api.github.com/users/albireox", "html_url": "https://github.com/albireox", "followers_url": "https://api.github.com/users/albireo...
[]
closed
false
null
[]
null
[ "From the [documentation](http://docs.peewee-orm.com/en/latest/peewee/relationships.html#manytomany):\r\n\r\n> Peewee provides a field for representing many-to-many relationships, much like Django does. This feature was added due to many requests from users, but I strongly advocate against using it, since it confla...
2018-12-07T01:28:07
2018-12-07T21:25:16
2018-12-07T21:25:16
NONE
null
It seems that if you have a `ManyToManyField` that uses a through model in which the foreign keys are defined with `backref='+'` it fails when trying to access the many-to-many field because it still tries to access the backref. The error is ```python ~/.pyenv/versions/3.7.1/Python.framework/Versions/3.7/lib/python...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1805/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1805/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1804
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1804/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1804/comments
https://api.github.com/repos/coleifer/peewee/issues/1804/events
https://github.com/coleifer/peewee/issues/1804
388,122,545
MDU6SXNzdWUzODgxMjI1NDU=
1,804
AttributeError: 'ValuesList' object has no attribute '_hash'
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "What's the actual error? \"ValuesList has no attribute source\"?\r\n\r\nedit: nevermind, replicated \"AttributeError: 'ValuesList' object has no attribute '_hash'\"" ]
2018-12-06T09:20:29
2018-12-06T15:46:45
2018-12-06T15:46:45
NONE
null
I'm trying to filter valid ids from a list of ids like this: ```python ids = [(1,), (2,), (3,)] values = ValuesList(ids, ('id',), alias='ids') list(Users.select(values.c.id) .join(values, p.JOIN.RIGHT_OUTER, cls.id == values.c.id) .where(cls.id.is_null())) ``` Produced SQL is OK but as soon as t...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1804/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1804/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1803
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1803/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1803/comments
https://api.github.com/repos/coleifer/peewee/issues/1803/events
https://github.com/coleifer/peewee/pull/1803
387,626,821
MDExOlB1bGxSZXF1ZXN0MjM2MDcyMzU4
1,803
Support order by in aggregate function
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "My own sense is that this is a niche usage and not widely supported.\r\n\r\nRather than implement a special-case for this, I'll suggest using `NodeList` and `SQL` to compose the appropriate \"ORDER BY\" clause.", "Could you give an example on how to use NodeList with `fn`? Because for me:\r\n+ `fn` wraps its arg...
2018-12-05T07:29:52
2018-12-05T22:27:23
2018-12-05T14:31:33
NONE
null
PostgreSQL support ORDER BY in aggregate function (e.g `json_agg`, `array_agg`, etc.) like this: ```SQL SELECT array_agg( "t1"."name" ORDER BY "t1"."name" ASC, "t1"."created_at" DESC ) AS "users" FROM "users" AS "t1" ``` This PR extend `fn` API to support this kind of query. ``` fn.array_agg(User.na...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1803/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1803/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1803", "html_url": "https://github.com/coleifer/peewee/pull/1803", "diff_url": "https://github.com/coleifer/peewee/pull/1803.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1803.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1802
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1802/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1802/comments
https://api.github.com/repos/coleifer/peewee/issues/1802/events
https://github.com/coleifer/peewee/issues/1802
387,549,037
MDU6SXNzdWUzODc1NDkwMzc=
1,802
how to select a random row with a group by clause in peewee
{ "login": "Colaplusice", "id": 29660460, "node_id": "MDQ6VXNlcjI5NjYwNDYw", "avatar_url": "https://avatars.githubusercontent.com/u/29660460?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Colaplusice", "html_url": "https://github.com/Colaplusice", "followers_url": "https://api.github.com/...
[]
closed
false
null
[]
null
[ "the question has been asked in stackoverflow : [link](https://stackoverflow.com/questions/28514736/how-to-select-a-random-row-with-a-group-by-clause) ,but i don't know how to translate it to peewee. please help me...\r\ni am stuck in there for a long time.\r\n", "It can be done like this:\r\n\r\n```python\r\nobj...
2018-12-05T01:07:55
2018-12-05T14:34:13
2018-12-05T10:09:48
NONE
null
like this: select object_id, name, image_path from (SELECT images.image_path AS image_path, objects.id AS object_id, objects.name FROM objects LEFT JOIN images ON images.object_id = objects.id ORDER BY RAND()) as z group by z.object_id, z.name
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1802/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1802/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1801
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1801/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1801/comments
https://api.github.com/repos/coleifer/peewee/issues/1801/events
https://github.com/coleifer/peewee/issues/1801
387,308,767
MDU6SXNzdWUzODczMDg3Njc=
1,801
Using sub-select as operand in expression applies a table alias to the sub-select
{ "login": "iksteen", "id": 1001206, "node_id": "MDQ6VXNlcjEwMDEyMDY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001206?v=4", "gravatar_id": "", "url": "https://api.github.com/users/iksteen", "html_url": "https://github.com/iksteen", "followers_url": "https://api.github.com/users/iksteen/...
[]
closed
false
null
[]
null
[ "Hmm, it seems that if I use `CompoundSelectQuery` (which isn't imported using `from peewee import *`), it does work.\r\n\r\nIs that the intended way to solve the problem?\r\n\r\nEdit: I guess not, because trying to use a correlated subquery will create a new alias for the original table,", "Is there a situation ...
2018-12-04T14:21:00
2018-12-14T12:16:46
2018-12-14T11:57:54
NONE
null
Consider the following (simplified) example where I want to divide a value by the result of a subquery (in the actual use case the points will decay based on how many teams solved a challenge correctly): ``` import logging from peewee import * logging.basicConfig(level=logging.DEBUG) database = PostgresqlDatab...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1801/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1801/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1800
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1800/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1800/comments
https://api.github.com/repos/coleifer/peewee/issues/1800/events
https://github.com/coleifer/peewee/pull/1800
386,373,809
MDExOlB1bGxSZXF1ZXN0MjM1MTMzODc5
1,800
Introspector: Don't strip _id unless foreign key
{ "login": "cognifloyd", "id": 1558590, "node_id": "MDQ6VXNlcjE1NTg1OTA=", "avatar_url": "https://avatars.githubusercontent.com/u/1558590?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cognifloyd", "html_url": "https://github.com/cognifloyd", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "Closing as a roughly equivalent patch was merged instead." ]
2018-11-30T22:27:17
2018-12-02T18:11:47
2018-12-02T18:11:47
NONE
null
This avoids stripping _id from a field name when introspecting a table, unless that column is a foreign key. Resolves #1799 This is a quick hack and should probably also change the interface of `introspect()` and `generate_models()` to include some new parameter.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1800/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1800/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1800", "html_url": "https://github.com/coleifer/peewee/pull/1800", "diff_url": "https://github.com/coleifer/peewee/pull/1800.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1800.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1799
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1799/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1799/comments
https://api.github.com/repos/coleifer/peewee/issues/1799/events
https://github.com/coleifer/peewee/issues/1799
386,341,173
MDU6SXNzdWUzODYzNDExNzM=
1,799
feature request: Introspector.make_column_name should have different logic for foreign key fields
{ "login": "cognifloyd", "id": 1558590, "node_id": "MDQ6VXNlcjE1NTg1OTA=", "avatar_url": "https://avatars.githubusercontent.com/u/1558590?v=4", "gravatar_id": "", "url": "https://api.github.com/users/cognifloyd", "html_url": "https://github.com/cognifloyd", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "In some databases people don't use actual foreign-key constraints, especially SQLite and MySQL. Additionally, introspecting a column named \"foo_id\", regardless of whether or not its a foreign-key, I think it's a reasonable assumption that we assume the Pythonic name should be \"foo\".\r\n\r\nThat being said, the...
2018-11-30T20:36:34
2018-12-02T18:11:19
2018-12-02T18:10:32
NONE
null
I'm using peewee to access another application's database. To avoid writing the models for the db, I'm using `playhouse.reflection.Introspector.generate_models()`. In this database, some of the tables use the suffix `_id` on the primary key column. Then, other tables that have a foreign key reference to that table use ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1799/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1799/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1798
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1798/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1798/comments
https://api.github.com/repos/coleifer/peewee/issues/1798/events
https://github.com/coleifer/peewee/issues/1798
386,180,594
MDU6SXNzdWUzODYxODA1OTQ=
1,798
Specify charset on CharField
{ "login": "tarlogic-osint", "id": 22524341, "node_id": "MDQ6VXNlcjIyNTI0MzQx", "avatar_url": "https://avatars.githubusercontent.com/u/22524341?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tarlogic-osint", "html_url": "https://github.com/tarlogic-osint", "followers_url": "https://api.gi...
[]
closed
false
null
[]
null
[ "I'd typically think it would be better to use UTF8 when creating the database, e.g.:\r\n\r\n```sql\r\nCREATE DATABASE foobar CHARACTER SET utf8 COLLATE utf8_unicode_ci;\r\n```\r\n\r\nI understand the storage concerns, though. You should be able to add the charset as peewee supports arbitrary constraints:\r\n\r\n``...
2018-11-30T13:07:55
2018-12-13T15:18:19
2018-11-30T15:14:33
NONE
null
Peewee doesn't allow to specify the charset of CharField. I want to specify an utf8 charset in some name fields for which I don't need the utf8mb4 charset used by default in Mysql. This also generates problems with Unique indexes generated cause the length of varchars (utf8mb4 makes a char be 4 bytes in size). It t...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1798/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1798/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1797
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1797/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1797/comments
https://api.github.com/repos/coleifer/peewee/issues/1797/events
https://github.com/coleifer/peewee/issues/1797
385,671,189
MDU6SXNzdWUzODU2NzExODk=
1,797
MySQL Error 1059(FK identifier name is too long) on migrator.add_column
{ "login": "Dushyant7", "id": 9477918, "node_id": "MDQ6VXNlcjk0Nzc5MTg=", "avatar_url": "https://avatars.githubusercontent.com/u/9477918?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Dushyant7", "html_url": "https://github.com/Dushyant7", "followers_url": "https://api.github.com/users/Du...
[]
closed
false
null
[]
null
[ "Peewee contains code that correctly truncates long index names. I've added a new patch that truncates long foreign-key constraint names, which will be included in the next release.\r\n\r\nYou're using an ancient version, I suggest upgrading." ]
2018-11-29T10:37:53
2018-12-14T19:03:00
2018-11-29T15:54:47
NONE
null
peewee==2.8.1 I am using MySQLMigrator to migrate my tables. When I am creating new column using add_column which is ForeignKeyField. It throws `peewee.InternalError (1059, Identifier name ... is too long)`. The reason behind this is MySQL has limit of 64 characters for FK identifier and identifier name which...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1797/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1797/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1796
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1796/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1796/comments
https://api.github.com/repos/coleifer/peewee/issues/1796/events
https://github.com/coleifer/peewee/pull/1796
385,542,543
MDExOlB1bGxSZXF1ZXN0MjM0NDg5MzQ1
1,796
Fix cast chaining
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "Nice catch, thanks." ]
2018-11-29T02:34:27
2018-11-29T15:24:55
2018-11-29T15:24:55
NONE
null
Will resolve #1795 Please suggest where should I put the test for this.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1796/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1796/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1796", "html_url": "https://github.com/coleifer/peewee/pull/1796", "diff_url": "https://github.com/coleifer/peewee/pull/1796.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1796.patch", "merged_at": "2018-11-29T15:24:54" }
https://api.github.com/repos/coleifer/peewee/issues/1795
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1795/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1795/comments
https://api.github.com/repos/coleifer/peewee/issues/1795/events
https://github.com/coleifer/peewee/issues/1795
385,540,472
MDU6SXNzdWUzODU1NDA0NzI=
1,795
Can not do cast chaining
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "Thanks, nice catch. Merged your patch." ]
2018-11-29T02:25:40
2018-11-29T15:25:06
2018-11-29T15:24:54
NONE
null
Reproducible snippet: ```python import peewee as p node = p.ColumnBase() node.cast('TEXT').cast('JSONB') # Will throw TypeError: 'str' object is not callable ``` I will make a PR soon for this.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1795/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1795/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1794
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1794/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1794/comments
https://api.github.com/repos/coleifer/peewee/issues/1794/events
https://github.com/coleifer/peewee/issues/1794
384,023,723
MDU6SXNzdWUzODQwMjM3MjM=
1,794
get raw sql without parameters
{ "login": "dridk", "id": 1911063, "node_id": "MDQ6VXNlcjE5MTEwNjM=", "avatar_url": "https://avatars.githubusercontent.com/u/1911063?v=4", "gravatar_id": "", "url": "https://api.github.com/users/dridk", "html_url": "https://github.com/dridk", "followers_url": "https://api.github.com/users/dridk/follower...
[]
closed
false
null
[]
null
[ "At present Peewee's schema manager does not have support for views.\r\n\r\nJust write out the SQL. In the time you took to type up your issue, and for me to respond, surely you could have typed out the SQL?\r\n\r\nIf you insist, you can implement a custom query component.\r\n\r\nHere's a complete example:\r\n\r\n`...
2018-11-24T21:32:18
2018-11-24T23:00:38
2018-11-24T22:15:11
NONE
null
I would like to create a view from a select statement. Actually, I m trying this : rawsql = Variant.select().where(Variant.pos > 3000).sql()[0] db.execute_sql(f"CREATE VIEW test AS {rawsql}" ) Unfortunally, with SQLITE it returns OperationalError: parameters are not allowed in views How c...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1794/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1794/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1793
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1793/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1793/comments
https://api.github.com/repos/coleifer/peewee/issues/1793/events
https://github.com/coleifer/peewee/issues/1793
383,053,357
MDU6SXNzdWUzODMwNTMzNTc=
1,793
Heuristics for determining whether to use python_value is incorrect if uses with CTE having same column with model
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "I believe the relevant changes are here: ecfa98c9f2d5d6b30f238d97928662d909f769e2\r\n\r\nAlthough I would point out that changing the above to \"raw_node\" does not affect the outcome of the query in any case. Change the line and try it for yourself -- the value is still an int.\r\n\r\nThere is no connection, inte...
2018-11-21T10:32:15
2018-11-22T15:34:39
2018-11-21T16:37:59
NONE
null
Reproducible snippet: ```python class Products(Model): id = IntegerField() tmp = Products.select(Products.id.cast('text')).cte('tmp', columns=('id',)) # Normally, we will #join with tmp here but use #from_ instead just for demonstration purpose Products.select(tmp.c.id).with_cte(tmp).from_(tmp) # => ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1793/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1793/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1792
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1792/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1792/comments
https://api.github.com/repos/coleifer/peewee/issues/1792/events
https://github.com/coleifer/peewee/pull/1792
382,929,854
MDExOlB1bGxSZXF1ZXN0MjMyNTIwNjE2
1,792
In an expression, don't use left hand side's converter if right hand side's is a function
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "I chose to implement this a bit differently -- the result is equivalent for your test-case, however. Rather than checking the rhs inside expression, I thought it made sense to simply not apply a conversion to the arguments of a function at all.\r\n\r\n178bc0155bf569c9245296e90ba5066901e208bc" ]
2018-11-21T02:34:45
2018-11-21T03:00:13
2018-11-21T03:00:13
NONE
null
Should fix #1791
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1792/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1792/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1792", "html_url": "https://github.com/coleifer/peewee/pull/1792", "diff_url": "https://github.com/coleifer/peewee/pull/1792.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1792.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1791
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1791/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1791/comments
https://api.github.com/repos/coleifer/peewee/issues/1791/events
https://github.com/coleifer/peewee/issues/1791
382,920,940
MDU6SXNzdWUzODI5MjA5NDA=
1,791
Peewee incorrectly uses json.dumps on parameters in edge-case
{ "login": "lephuongbg", "id": 1001176, "node_id": "MDQ6VXNlcjEwMDExNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/1001176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/lephuongbg", "html_url": "https://github.com/lephuongbg", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "Thanks for this, and for the patch. I chose to implement the fix a bit differently than your suggested fix, but they should be equivalent. The solution I merged is more general, and avoids applying conversion to function arguments in any case.\r\n\r\n178bc0155bf569c9245296e90ba5066901e208bc", "Thanks. I also did...
2018-11-21T01:49:45
2018-11-21T04:25:59
2018-11-21T02:58:52
NONE
null
Not sure how to make the title better but here is a small reproducible snippet: ```python import peewee as p from playhouse.postgres_ext import * db = PostgresqlExtDatabase( # The usual config ) class TestModel(p.Model): class Meta: database = db metadata = BinaryJSONField() # OK ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1791/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1791/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1790
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1790/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1790/comments
https://api.github.com/repos/coleifer/peewee/issues/1790/events
https://github.com/coleifer/peewee/issues/1790
382,488,729
MDU6SXNzdWUzODI0ODg3Mjk=
1,790
How's graphene-peewee going?
{ "login": "yanghg-basefx", "id": 29534214, "node_id": "MDQ6VXNlcjI5NTM0MjE0", "avatar_url": "https://avatars.githubusercontent.com/u/29534214?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yanghg-basefx", "html_url": "https://github.com/yanghg-basefx", "followers_url": "https://api.githu...
[]
closed
false
null
[]
null
[ "I'm not pursuing it, nor am I in a position to recommend an alternative.", "I ported @insolite’s [graphene-peewee-async](https://github.com/insolite/graphene-peewee-async) to the regular Peewee. Check it out here:\r\n\r\n[graphene-peewee](https://github.com/emperorplatform/graphene-peewee)\r\n\r\nThis is my firs...
2018-11-20T03:48:09
2020-05-10T21:09:53
2018-11-21T03:01:12
NONE
null
I see [this ticket](https://github.com/graphql-python/graphene/issues/289), and I want to use peewee with graphql, but I didn't find any other info. How's it going? Or I must switch to sqlalchemy to use graphene-sqlalchemy?
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1790/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1790/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1789
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1789/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1789/comments
https://api.github.com/repos/coleifer/peewee/issues/1789/events
https://github.com/coleifer/peewee/issues/1789
382,035,232
MDU6SXNzdWUzODIwMzUyMzI=
1,789
logger.debug
{ "login": "adontz", "id": 829414, "node_id": "MDQ6VXNlcjgyOTQxNA==", "avatar_url": "https://avatars.githubusercontent.com/u/829414?v=4", "gravatar_id": "", "url": "https://api.github.com/users/adontz", "html_url": "https://github.com/adontz", "followers_url": "https://api.github.com/users/adontz/follow...
[]
closed
false
null
[]
null
[ "The logger statements are intended to log the tuple. Interpolation/parameterization wouldn't work, anyways, as not all databases necessarily use \"%s\" to signify parameters...sqlite uses \"?\" for instance. The idea is that we log both the SQL and the params as a tuple rather than trying to interpolate.", "I un...
2018-11-19T02:35:51
2018-11-19T16:39:08
2018-11-19T03:58:13
NONE
null
I am pretty sure logger.debug is called wrong way all across the code I have found lines like this logger.debug((sql, params)) in peewee.py and playhouse/apsw_ext.py, but it really should be logger.debug(sql, params) because method signature is debug(msg, *args, **kwargs) and one should p...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1789/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1789/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1788
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1788/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1788/comments
https://api.github.com/repos/coleifer/peewee/issues/1788/events
https://github.com/coleifer/peewee/issues/1788
382,000,012
MDU6SXNzdWUzODIwMDAwMTI=
1,788
[Request] Raise exception on missing parens for field type definitions
{ "login": "ghost", "id": 10137, "node_id": "MDQ6VXNlcjEwMTM3", "avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ghost", "html_url": "https://github.com/ghost", "followers_url": "https://api.github.com/users/ghost/followers", "f...
[]
closed
false
null
[]
null
[ "Going to pass." ]
2018-11-18T21:03:15
2018-11-19T02:08:55
2018-11-19T02:08:55
NONE
null
When one forgets to add parentheses to a field type definition. e.g. mtype = IntegerField instead of mtype = IntegerField () and create_tables executes, tables from the models get built, but columns do not get created for fields w/o parentheses. Exceptions aren't raised either. It would be nice, if peewee ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1788/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1788/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1787
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1787/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1787/comments
https://api.github.com/repos/coleifer/peewee/issues/1787/events
https://github.com/coleifer/peewee/issues/1787
381,895,992
MDU6SXNzdWUzODE4OTU5OTI=
1,787
OperationalError when creating table with schema in SQLite
{ "login": "belidzs", "id": 7085801, "node_id": "MDQ6VXNlcjcwODU4MDE=", "avatar_url": "https://avatars.githubusercontent.com/u/7085801?v=4", "gravatar_id": "", "url": "https://api.github.com/users/belidzs", "html_url": "https://github.com/belidzs", "followers_url": "https://api.github.com/users/belidzs/...
[]
closed
false
null
[]
null
[ "Schemas, in SQLite, refer to attached databases. Therefore, to use \"schemas\" in SQLite you will need to attach databases with the given names. This is an advanced usage and probably not what you want, so I recommend avoiding the use of schema with sqlite unless you know what you're doing.", "Thanks for the qui...
2018-11-17T20:00:33
2018-11-17T21:07:48
2018-11-17T20:58:46
NONE
null
I have the following model: ```python db = Proxy() class BaseModel(Model): class Meta: database = db schema = 'api' class Koltseg(BaseModel): id = CharField(primary_key=True, max_length=8) kotesszam = CharField(max_length=10) fokonyv = CharField(max_length=50) ko...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1787/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1787/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1786
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1786/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1786/comments
https://api.github.com/repos/coleifer/peewee/issues/1786/events
https://github.com/coleifer/peewee/pull/1786
381,861,144
MDExOlB1bGxSZXF1ZXN0MjMxNzI2NzM5
1,786
Fixed deprecation warning for importing Callable ABC's from collections
{ "login": "AVOstap", "id": 9307922, "node_id": "MDQ6VXNlcjkzMDc5MjI=", "avatar_url": "https://avatars.githubusercontent.com/u/9307922?v=4", "gravatar_id": "", "url": "https://api.github.com/users/AVOstap", "html_url": "https://github.com/AVOstap", "followers_url": "https://api.github.com/users/AVOstap/...
[]
closed
false
null
[]
null
[ "Merged equivalent patch." ]
2018-11-17T13:00:51
2018-11-17T16:23:42
2018-11-17T16:23:42
NONE
null
to avoid: ```bash .../peewee.py:169: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working from collections import Callable ```
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1786/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1786/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1786", "html_url": "https://github.com/coleifer/peewee/pull/1786", "diff_url": "https://github.com/coleifer/peewee/pull/1786.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1786.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1785
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1785/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1785/comments
https://api.github.com/repos/coleifer/peewee/issues/1785/events
https://github.com/coleifer/peewee/issues/1785
381,704,675
MDU6SXNzdWUzODE3MDQ2NzU=
1,785
model_to_dict fails to process disabled backrefs
{ "login": "adontz", "id": 829414, "node_id": "MDQ6VXNlcjgyOTQxNA==", "avatar_url": "https://avatars.githubusercontent.com/u/829414?v=4", "gravatar_id": "", "url": "https://api.github.com/users/adontz", "html_url": "https://github.com/adontz", "followers_url": "https://api.github.com/users/adontz/follow...
[]
closed
false
null
[]
null
[ "Nice, thanks.", "You response speed in incredible! Thank you!\r\n\r\nCan you please clarify why you have \"not in '!+'\" in one place and \"== '+'\" in another place?\r\nAre not backref='+' and backref='!' the same?", "Sorry for the lack of documentation on this... \"!\" is retained for backwards-compatibility...
2018-11-16T18:06:16
2018-11-19T04:17:34
2018-11-16T19:55:46
NONE
null
If there is a model with disabled backref "ForeignKeyField(OtherModel, backref='+')" then model_to_dict fails to convert such model to dict, because model has no '+' attribute File ".../site-packages/playhouse/shortcuts.py", line 105, in model_to_dict descriptor = getattr(model_class, foreign_key.backre...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1785/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1785/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1784
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1784/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1784/comments
https://api.github.com/repos/coleifer/peewee/issues/1784/events
https://github.com/coleifer/peewee/issues/1784
381,166,070
MDU6SXNzdWUzODExNjYwNzA=
1,784
model_to_dict backrefs=True, but exclude_autogenerated, i.e. *_set
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "There is no \"exclude_autogenerated\" option. You can, however, use the \"exclude\" option to specify the foreign-key of the backref you wish to exclude." ]
2018-11-15T13:41:54
2018-11-15T19:59:36
2018-11-15T19:59:35
NONE
null
Is this possible? Otherwise, I would have to `backrefs=False` altogether, and manually `extra_attrs`.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1784/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1784/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1783
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1783/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1783/comments
https://api.github.com/repos/coleifer/peewee/issues/1783/events
https://github.com/coleifer/peewee/issues/1783
381,144,713
MDU6SXNzdWUzODExNDQ3MTM=
1,783
Documentation on advanced connection management
{ "login": "DaanVanVugt", "id": 35944, "node_id": "MDQ6VXNlcjM1OTQ0", "avatar_url": "https://avatars.githubusercontent.com/u/35944?v=4", "gravatar_id": "", "url": "https://api.github.com/users/DaanVanVugt", "html_url": "https://github.com/DaanVanVugt", "followers_url": "https://api.github.com/users/Daan...
[]
closed
false
null
[]
null
[ "That information is outdated and was likely removed when 3.0 was released... I don't see any references to that from within Peewee.\r\n\r\nFor multiprocess, just be sure not to connect until after the fork." ]
2018-11-15T12:43:12
2018-11-15T16:20:14
2018-11-15T16:20:14
NONE
null
Hi, Thanks for this cool package. I've been trying to work with multiple processes, and find references here and there to http://docs.peewee-orm.com/en/latest/peewee/database.html#advanced-connection-management but can't seem to find this page anymore. Is this not supported anymore? Thanks, Daan
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1783/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1783/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1782
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1782/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1782/comments
https://api.github.com/repos/coleifer/peewee/issues/1782/events
https://github.com/coleifer/peewee/issues/1782
380,495,779
MDU6SXNzdWUzODA0OTU3Nzk=
1,782
Doc improvement
{ "login": "ghost", "id": 10137, "node_id": "MDQ6VXNlcjEwMTM3", "avatar_url": "https://avatars.githubusercontent.com/u/10137?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ghost", "html_url": "https://github.com/ghost", "followers_url": "https://api.github.com/users/ghost/followers", "f...
[]
closed
false
null
[]
null
[ "`fields` is not something you assign, it is inferred from the fields declared on the model. It is a metadata attribute and should be considered read-only." ]
2018-11-14T01:24:53
2018-11-14T03:05:14
2018-11-14T03:05:14
NONE
null
The 'fields' option is missing from the Meta attributes table in the docs (even though it is mentioned immediately above the table)
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1782/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1782/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1781
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1781/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1781/comments
https://api.github.com/repos/coleifer/peewee/issues/1781/events
https://github.com/coleifer/peewee/issues/1781
380,175,617
MDU6SXNzdWUzODAxNzU2MTc=
1,781
Aliases, group by and count
{ "login": "ak4nv", "id": 73960, "node_id": "MDQ6VXNlcjczOTYw", "avatar_url": "https://avatars.githubusercontent.com/u/73960?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ak4nv", "html_url": "https://github.com/ak4nv", "followers_url": "https://api.github.com/users/ak4nv/followers", "f...
[]
closed
false
null
[]
null
[ "I see -- good work on finding a workaround.\r\n\r\nLooks to me like a bug. Peewee is being too aggressive about stripping out the selected columns. The logic in the code reads:\r\n\r\n```python\r\n clone = self.order_by().alias('_wrapped')\r\n if clear_limit:\r\n clone._limit = clone._offs...
2018-11-13T11:15:04
2018-11-13T15:32:32
2018-11-13T15:32:32
NONE
null
Hi @coleifer ! I have a little bit complex query with some joins, aliases, and group by clause (generates a query on the fly). And I found when I try to call a `qs.count()` method I've got an exception: ``` peewee.ProgrammingError: ОШИБКА: столбец "external_source" не существует LINE 1: ...ROUP BY "t1"."id", "t1...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1781/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1781/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1780
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1780/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1780/comments
https://api.github.com/repos/coleifer/peewee/issues/1780/events
https://github.com/coleifer/peewee/pull/1780
378,504,393
MDExOlB1bGxSZXF1ZXN0MjI5MTk1NTA1
1,780
fix InterfaceError when postgresql connection is closed
{ "login": "velom", "id": 6709156, "node_id": "MDQ6VXNlcjY3MDkxNTY=", "avatar_url": "https://avatars.githubusercontent.com/u/6709156?v=4", "gravatar_id": "", "url": "https://api.github.com/users/velom", "html_url": "https://github.com/velom", "followers_url": "https://api.github.com/users/velom/follower...
[]
closed
false
null
[]
null
[ "I'm unclear on why this patch is necessary. Granted, Peewee could do a lot more introspection to detect whether the connection is closed or not, but this method is intended more to refer to the \"peewee\" connection state rather than the \"driver\" connection state.", "I'm going to pass on this -- connections dy...
2018-11-07T22:53:24
2018-11-08T20:45:50
2018-11-08T03:47:49
NONE
null
when `self._state.closed is False` and `self._state.conn.closed != 0`
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1780/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1780/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1780", "html_url": "https://github.com/coleifer/peewee/pull/1780", "diff_url": "https://github.com/coleifer/peewee/pull/1780.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1780.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1779
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1779/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1779/comments
https://api.github.com/repos/coleifer/peewee/issues/1779/events
https://github.com/coleifer/peewee/pull/1779
378,501,566
MDExOlB1bGxSZXF1ZXN0MjI5MTkzMzIz
1,779
rollback only if connection is not closed
{ "login": "velom", "id": 6709156, "node_id": "MDQ6VXNlcjY3MDkxNTY=", "avatar_url": "https://avatars.githubusercontent.com/u/6709156?v=4", "gravatar_id": "", "url": "https://api.github.com/users/velom", "html_url": "https://github.com/velom", "followers_url": "https://api.github.com/users/velom/follower...
[]
closed
false
null
[]
null
[ "I'm unclear on when this would occur? Take a look at the code to `execute_sql()`:\r\n\r\n```python\r\n def execute_sql(self, sql, params=None, commit=SENTINEL):\r\n logger.debug((sql, params))\r\n if commit is SENTINEL:\r\n if self.in_transaction():\r\n commit = False\r\n...
2018-11-07T22:43:55
2018-11-08T12:33:45
2018-11-08T03:46:55
NONE
null
this fix prevent next error ``` File "contrib/python/peewee/peewee.py", line 5952, in __iter__ self.execute() File "contrib/python/peewee/peewee.py", line 1604, in inner return method(self, database, *args, **kwargs) File "contrib/python/peewee/peewee.py", line 1675, in execute return self._exe...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1779/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1779/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1779", "html_url": "https://github.com/coleifer/peewee/pull/1779", "diff_url": "https://github.com/coleifer/peewee/pull/1779.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1779.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1778
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1778/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1778/comments
https://api.github.com/repos/coleifer/peewee/issues/1778/events
https://github.com/coleifer/peewee/issues/1778
378,290,310
MDU6SXNzdWUzNzgyOTAzMTA=
1,778
peewee order_by failed
{ "login": "hanvanos", "id": 18707141, "node_id": "MDQ6VXNlcjE4NzA3MTQx", "avatar_url": "https://avatars.githubusercontent.com/u/18707141?v=4", "gravatar_id": "", "url": "https://api.github.com/users/hanvanos", "html_url": "https://github.com/hanvanos", "followers_url": "https://api.github.com/users/han...
[]
closed
false
null
[]
null
[ "The update from 2.x to 3.x has a lot more changes than just that:\r\n\r\nhttp://docs.peewee-orm.com/en/latest/peewee/changes.html" ]
2018-11-07T13:36:27
2018-11-07T14:38:25
2018-11-07T14:38:25
NONE
null
I installed a new version of Ubuntu and with that also peewee version3.7.1 Now the order_by meta declaration in the models does not work anymore. I had to add order_by statements in the queries.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1778/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1778/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1777
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1777/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1777/comments
https://api.github.com/repos/coleifer/peewee/issues/1777/events
https://github.com/coleifer/peewee/issues/1777
378,210,627
MDU6SXNzdWUzNzgyMTA2Mjc=
1,777
RecursionError on large select queries
{ "login": "conqp", "id": 3766192, "node_id": "MDQ6VXNlcjM3NjYxOTI=", "avatar_url": "https://avatars.githubusercontent.com/u/3766192?v=4", "gravatar_id": "", "url": "https://api.github.com/users/conqp", "html_url": "https://github.com/conqp", "followers_url": "https://api.github.com/users/conqp/follower...
[]
closed
false
null
[]
null
[ "The recursion error is because you are creating a stack whose length exceeds the stack depth set by the interpreter. Of course you can always manually extend this: https://docs.python.org/3/library/sys.html#sys.setrecursionlimit\r\n\r\nThe problem here:\r\n\r\n```pycon\r\n>>> expression = False\r\n>>> from termina...
2018-11-07T09:42:13
2018-11-07T14:37:47
2018-11-07T14:37:47
CONTRIBUTOR
null
I have a terminals database with ~ 1000 records at the moment. I use it in python programs programatically using peewee ORM models. When I try to filter for a huge number of records, I get a recursion error: ``` >>> len(terminals) 576 >>> terminals [('1', '1000'), <snip>] >>> expression = False >>> from term...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1777/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1777/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1776
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1776/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1776/comments
https://api.github.com/repos/coleifer/peewee/issues/1776/events
https://github.com/coleifer/peewee/pull/1776
377,148,281
MDExOlB1bGxSZXF1ZXN0MjI4MTc0MDg3
1,776
PostgreSQL UPDATE statement with FROM clause with subquery support
{ "login": "nilp0inter", "id": 1224006, "node_id": "MDQ6VXNlcjEyMjQwMDY=", "avatar_url": "https://avatars.githubusercontent.com/u/1224006?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nilp0inter", "html_url": "https://github.com/nilp0inter", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "I merged a similar patch that is roughly equivalent: 2018e579ac81db5113a26e55ce9078cc80bab446\r\n\r\nI have also removed all references to QualifiedNames in the tests -- the helper is no longer needed as the query-builder handles it correctly now. ", "Awesome, thanks! " ]
2018-11-04T12:34:39
2018-11-06T18:27:06
2018-11-06T17:08:16
CONTRIBUTOR
null
This is a second try on #1775 , because the request was accepted and then reverted I am opening this. The changes with master are: 1. I reverted the SET part in the UPDATE test queries. 2. I wrote a helper function to recursively qualify only ColumnBase member of Expressions. 3. I applied this helper to the RHS...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1776/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1776/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1776", "html_url": "https://github.com/coleifer/peewee/pull/1776", "diff_url": "https://github.com/coleifer/peewee/pull/1776.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1776.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1775
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1775/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1775/comments
https://api.github.com/repos/coleifer/peewee/issues/1775/events
https://github.com/coleifer/peewee/pull/1775
377,050,981
MDExOlB1bGxSZXF1ZXN0MjI4MTE2MzM4
1,775
Correct format for PostgreSQL UPDATE statement with FROM clause.
{ "login": "nilp0inter", "id": 1224006, "node_id": "MDQ6VXNlcjEyMjQwMDY=", "avatar_url": "https://avatars.githubusercontent.com/u/1224006?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nilp0inter", "html_url": "https://github.com/nilp0inter", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "The build is passing, which builds against python 2.x/3.x across postgres/mysql/sqlite, so that's fantastic.\r\n\r\nI'm happy to merge this patch and will probably add some regression tests in `tests/regressions.py`. I'm not sure if there are any weird, unintended effects that will crop up from wrapping the WHERE ...
2018-11-03T12:38:32
2018-11-03T22:53:15
2018-11-03T16:50:31
CONTRIBUTOR
null
Hi, I tried to use **UPDATE ... FROM** clause using peewee+PostgreSQL without luck. After seeing #1321 I made this patch to fix it. I'll explain the problem and my solution. **The Problem** Consider the following model: ```python class Race(Model): name = CharField() gold_bonus = IntegerFie...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1775/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1775/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1775", "html_url": "https://github.com/coleifer/peewee/pull/1775", "diff_url": "https://github.com/coleifer/peewee/pull/1775.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1775.patch", "merged_at": "2018-11-03T16:50:31" }
https://api.github.com/repos/coleifer/peewee/issues/1774
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1774/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1774/comments
https://api.github.com/repos/coleifer/peewee/issues/1774/events
https://github.com/coleifer/peewee/issues/1774
376,805,687
MDU6SXNzdWUzNzY4MDU2ODc=
1,774
Could/Should BinaryUUID field attempt str -> uuid conversion
{ "login": "Allu2", "id": 644641, "node_id": "MDQ6VXNlcjY0NDY0MQ==", "avatar_url": "https://avatars.githubusercontent.com/u/644641?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Allu2", "html_url": "https://github.com/Allu2", "followers_url": "https://api.github.com/users/Allu2/followers"...
[]
closed
false
null
[]
null
[ "Merged a fix that allows:\r\n\r\n* 32-character hexadecimal string representation\r\n* 16-byte raw binary representation\r\n\r\nThis should solve your problem!" ]
2018-11-02T13:15:51
2018-11-02T14:39:01
2018-11-02T14:38:27
NONE
null
Given model such as: ```python class Product(Model): id = BinaryUUIDField(primary_key=True) ``` If I then attempt to create new `Product` from a dict containing: ```python data_dict = {'id': '74db9954-97c4-4947-941d-42b3fa33be3c'} ``` by something akin to : ```python product = Product(**data_dict) produ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1774/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1774/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1773
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1773/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1773/comments
https://api.github.com/repos/coleifer/peewee/issues/1773/events
https://github.com/coleifer/peewee/issues/1773
376,215,332
MDU6SXNzdWUzNzYyMTUzMzI=
1,773
text field type when using mysql/mariadb database
{ "login": "hegusung", "id": 7390383, "node_id": "MDQ6VXNlcjczOTAzODM=", "avatar_url": "https://avatars.githubusercontent.com/u/7390383?v=4", "gravatar_id": "", "url": "https://api.github.com/users/hegusung", "html_url": "https://github.com/hegusung", "followers_url": "https://api.github.com/users/hegus...
[]
closed
false
null
[]
null
[ "Apologies -- the docs are incorrect. Peewee used \"longtext\" up until 3.x, at which point it changed to just plain old \"text\".\r\n\r\nTo have a longtext field:\r\n\r\n```python\r\nclass LongTextField(TextField):\r\n field_type = 'LONGTEXT'\r\n```\r\n\r\nThen just use it as you would a regular `TextField`." ]
2018-11-01T01:05:29
2018-11-01T02:53:47
2018-11-01T02:53:47
NONE
null
Hi, According to the documentation, TextField should use MySQL longtext column type but it uses the text column type. Is this the desired behavior and the documentation has not been changed? If so, how can I change my code to make sure it uses a longtext and not a text field type?
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1773/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1773/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1772
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1772/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1772/comments
https://api.github.com/repos/coleifer/peewee/issues/1772/events
https://github.com/coleifer/peewee/issues/1772
375,564,269
MDU6SXNzdWUzNzU1NjQyNjk=
1,772
Add update_or_create() helper method
{ "login": "willyhakim", "id": 5633805, "node_id": "MDQ6VXNlcjU2MzM4MDU=", "avatar_url": "https://avatars.githubusercontent.com/u/5633805?v=4", "gravatar_id": "", "url": "https://api.github.com/users/willyhakim", "html_url": "https://github.com/willyhakim", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "No. `get_or_create` is a hack and I don't advise anyone to use it under any circumstances. It's vulnerable to race-conditions and weird behavior. Just write the extra 2-3 lines of code and do it right. Wrap it up in a classmethod on the model it pertains to. You can thank me later." ]
2018-10-30T15:55:36
2018-10-30T20:56:12
2018-10-30T20:56:12
NONE
null
get_or_create is amazing! Could we add some more super powers by implementing update_or_create()
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1772/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1772/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1771
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1771/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1771/comments
https://api.github.com/repos/coleifer/peewee/issues/1771/events
https://github.com/coleifer/peewee/issues/1771
375,558,485
MDU6SXNzdWUzNzU1NTg0ODU=
1,771
ArrayField of ForeignKeyFields, is it possible?
{ "login": "droserasprout", "id": 10263434, "node_id": "MDQ6VXNlcjEwMjYzNDM0", "avatar_url": "https://avatars.githubusercontent.com/u/10263434?v=4", "gravatar_id": "", "url": "https://api.github.com/users/droserasprout", "html_url": "https://github.com/droserasprout", "followers_url": "https://api.githu...
[]
closed
false
null
[]
null
[ "I wouldn't call that trickery, I'd call it ... well, nevermind.\r\n\r\nJust use an actual junction table. Play to the strengths of your relational database.", "Sorry to resurrect an old thread, but if anyone (like me) is looking for a similar thing: have a look at the [ManyToManyField](http://docs.peewee-orm.com...
2018-10-30T15:44:19
2022-03-03T22:49:53
2018-10-30T20:54:12
NONE
null
Hi! I'm working with postgresql and peewee 3.7.1 and trying to initialize model's field as an array of ForeignKeyFields this way: ```python PreviousTasks = ArrayField(ForeignKeyField, {'model': 'self', 'column_name': 'previous_tasks', 'field': 'ID', 'backref': 'TaskPreviousTasks'}) ``` Docs say ArrayField argume...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1771/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1771/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1770
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1770/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1770/comments
https://api.github.com/repos/coleifer/peewee/issues/1770/events
https://github.com/coleifer/peewee/issues/1770
375,370,895
MDU6SXNzdWUzNzUzNzA4OTU=
1,770
choices are not working!
{ "login": "surajano", "id": 10608802, "node_id": "MDQ6VXNlcjEwNjA4ODAy", "avatar_url": "https://avatars.githubusercontent.com/u/10608802?v=4", "gravatar_id": "", "url": "https://api.github.com/users/surajano", "html_url": "https://github.com/surajano", "followers_url": "https://api.github.com/users/sur...
[]
closed
false
null
[]
null
[ "* http://docs.peewee-orm.com/en/latest/peewee/api.html?highlight=choices#Field\r\n* http://docs.peewee-orm.com/en/latest/peewee/models.html?highlight=choices#some-fields-take-special-parameters\r\n\r\n> Both default and choices could be implemented at the database level as DEFAULT and CHECK CONSTRAINT respectively...
2018-10-30T08:26:02
2018-10-30T14:08:12
2018-10-30T14:04:14
NONE
null
In the following code the choices for Task tables are not working, while creating the instance of Task with status="Success", its not adding the choices value(ie "S") in the task DB table. Its adding the "Success" as it is in the task table. ``` from datetime import datetime import peewee db = peewee.SqliteDatab...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1770/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1770/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1769
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1769/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1769/comments
https://api.github.com/repos/coleifer/peewee/issues/1769/events
https://github.com/coleifer/peewee/issues/1769
374,408,268
MDU6SXNzdWUzNzQ0MDgyNjg=
1,769
Model field name and the same name for subquery column
{ "login": "ak4nv", "id": 73960, "node_id": "MDQ6VXNlcjczOTYw", "avatar_url": "https://avatars.githubusercontent.com/u/73960?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ak4nv", "html_url": "https://github.com/ak4nv", "followers_url": "https://api.github.com/users/ak4nv/followers", "f...
[]
closed
false
null
[]
null
[ "So peewee sees that you're aliasing a column value to an attribute that is a field on the given model (e.g., you're aliasing a string to the name \"genus\"), which happens to be a foreign-key. Peewee assumes that the value you're storing in the foreign-key field attribute is of the same type as the field would usu...
2018-10-26T14:26:02
2018-10-27T16:46:48
2018-10-26T16:27:27
NONE
null
Hi there! Three (simplifed) models: ```python class Tax(db.Model): id = pw.AutoField(db_column='tax_id') class TaxName(db.Model): tax = pw.ForeignKeyField(Tax) name = pw.CharField(400, null=True) name_class = pw.CharField(100, null=True) class Host(db.Model): id = IDField() name =...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1769/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1769/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1768
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1768/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1768/comments
https://api.github.com/repos/coleifer/peewee/issues/1768/events
https://github.com/coleifer/peewee/issues/1768
372,556,039
MDU6SXNzdWUzNzI1NTYwMzk=
1,768
prefetch not work when joining same model
{ "login": "1xinghuan", "id": 33982538, "node_id": "MDQ6VXNlcjMzOTgyNTM4", "avatar_url": "https://avatars.githubusercontent.com/u/33982538?v=4", "gravatar_id": "", "url": "https://api.github.com/users/1xinghuan", "html_url": "https://github.com/1xinghuan", "followers_url": "https://api.github.com/users/...
[]
closed
false
null
[]
null
[]
2018-10-22T14:56:13
2018-10-22T16:01:07
2018-10-22T16:01:07
NONE
null
I have some models like this: ``` class Version(BaseModel): name = CharField() @property def sources(self): return [i.from_version for i in self.sources_connection] @property def destinations(self): return [i.to_version for i in self.destinations_connection] class...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1768/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1768/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1767
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1767/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1767/comments
https://api.github.com/repos/coleifer/peewee/issues/1767/events
https://github.com/coleifer/peewee/issues/1767
372,545,456
MDU6SXNzdWUzNzI1NDU0NTY=
1,767
prefetch doesn't work when join same model
{ "login": "1xinghuan", "id": 33982538, "node_id": "MDQ6VXNlcjMzOTgyNTM4", "avatar_url": "https://avatars.githubusercontent.com/u/33982538?v=4", "gravatar_id": "", "url": "https://api.github.com/users/1xinghuan", "html_url": "https://github.com/1xinghuan", "followers_url": "https://api.github.com/users/...
[]
closed
false
null
[]
null
[ "wrong submit." ]
2018-10-22T14:30:00
2018-10-22T14:59:20
2018-10-22T14:58:20
NONE
null
I have some models like this: ``` class Version(BaseModel): name = CharField() @property def sources(self): return [i.from_version for i in self.sources_connection] @property def destinations(self): return [i.to_version for i in self.destinations_connection] class...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1767/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1767/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1766
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1766/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1766/comments
https://api.github.com/repos/coleifer/peewee/issues/1766/events
https://github.com/coleifer/peewee/issues/1766
372,544,044
MDU6SXNzdWUzNzI1NDQwNDQ=
1,766
prefetch not work when join to same model
{ "login": "1xinghuan", "id": 33982538, "node_id": "MDQ6VXNlcjMzOTgyNTM4", "avatar_url": "https://avatars.githubusercontent.com/u/33982538?v=4", "gravatar_id": "", "url": "https://api.github.com/users/1xinghuan", "html_url": "https://github.com/1xinghuan", "followers_url": "https://api.github.com/users/...
[]
closed
false
null
[]
null
[]
2018-10-22T14:26:36
2018-10-22T14:57:57
2018-10-22T14:57:57
NONE
null
I have some models like this: ``` class Version(BaseModel): name = CharField() @property def sources(self): return [i.from_version for i in self.sources_connection] @property def destinations(self): return [i.to_version for i in self.destinations_connection] class V...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1766/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1766/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1765
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1765/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1765/comments
https://api.github.com/repos/coleifer/peewee/issues/1765/events
https://github.com/coleifer/peewee/issues/1765
372,194,255
MDU6SXNzdWUzNzIxOTQyNTU=
1,765
query result to python list
{ "login": "michalchrzastek", "id": 38867528, "node_id": "MDQ6VXNlcjM4ODY3NTI4", "avatar_url": "https://avatars.githubusercontent.com/u/38867528?v=4", "gravatar_id": "", "url": "https://api.github.com/users/michalchrzastek", "html_url": "https://github.com/michalchrzastek", "followers_url": "https://api...
[]
closed
false
null
[]
null
[ "It's returning a list of tag instances...you need to:\r\n\r\n```python\r\ndef get_tagsID(self):\r\n tagQ = tag_list.select(tag_list.id)\r\n return [tl.id for tl in tagQ]\r\n```\r\n\r\nAlso python typically prefers lower case w/underscores instead of that camelCase just fyi.", "By the way, try reading the e...
2018-10-20T09:47:03
2018-10-21T07:44:42
2018-10-20T22:56:23
NONE
null
Hello, I'm trying to return a list with integers (ID column) like so: `my list = [1,2,3,4,...]` but get this error, what am I missing? `TypeError: <modelFinance.tag_list object at 0x759703d0> is not JSON serializable` my query: `def get_tagsID(self): tagQ = tag_list.select(tag_list.id) return ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1765/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1765/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1764
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1764/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1764/comments
https://api.github.com/repos/coleifer/peewee/issues/1764/events
https://github.com/coleifer/peewee/issues/1764
372,014,868
MDU6SXNzdWUzNzIwMTQ4Njg=
1,764
Diferent results when unit testing one unit test file and unit testing a folder with several files with unit tests
{ "login": "fmors", "id": 1216208, "node_id": "MDQ6VXNlcjEyMTYyMDg=", "avatar_url": "https://avatars.githubusercontent.com/u/1216208?v=4", "gravatar_id": "", "url": "https://api.github.com/users/fmors", "html_url": "https://github.com/fmors", "followers_url": "https://api.github.com/users/fmors/follower...
[]
closed
false
null
[]
null
[ "Have you tried with a file-based database? That might provide a clue.\r\n\r\nNo idea but it's certainly not a peewee issue." ]
2018-10-19T15:48:19
2018-10-20T22:54:50
2018-10-20T22:54:50
NONE
null
Here is the context... I have implemented a simple test for a project I'm working on, where this test instantiates a SQLite database on memory, creates a table based on a model and adds some rows to that table, later asserting that my Tornado application GET the rows correctly. The peewee version I'm using is 3.7.0, bu...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1764/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1764/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1763
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1763/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1763/comments
https://api.github.com/repos/coleifer/peewee/issues/1763/events
https://github.com/coleifer/peewee/issues/1763
371,782,633
MDU6SXNzdWUzNzE3ODI2MzM=
1,763
Extending JSONField to rename-able keys
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "I don't understand the code.\r\n\r\nFor sqlite json, I imagine it is possible but not sure off the top of my head." ]
2018-10-19T02:27:03
2018-10-19T13:54:48
2018-10-19T13:54:48
NONE
null
I am thinking of doing something like this: class JSONValueField(JSONField): def __init__(json_key, *args, **kwargs): super().__init__(*args, **kwargs) self.ref = json_key def db_value(self, value): d = dict() for k, v in value.items...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1763/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1763/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1762
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1762/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1762/comments
https://api.github.com/repos/coleifer/peewee/issues/1762/events
https://github.com/coleifer/peewee/issues/1762
371,646,820
MDU6SXNzdWUzNzE2NDY4MjA=
1,762
Native support for json_group_array() and json_group_object()
{ "login": "brandond", "id": 370103, "node_id": "MDQ6VXNlcjM3MDEwMw==", "avatar_url": "https://avatars.githubusercontent.com/u/370103?v=4", "gravatar_id": "", "url": "https://api.github.com/users/brandond", "html_url": "https://github.com/brandond", "followers_url": "https://api.github.com/users/brandon...
[]
closed
false
null
[]
null
[ "FWIW, what I really want in this case is probably something closer to Postgres's `array_agg`, but postgres also has `json_agg`, `json_object_agg`, etc that have their own use case with regards to returning dicts. Also, I'm pretty tied to using sqlite.", "I've made a patch which somewhat addresses this issue... T...
2018-10-18T18:06:16
2018-10-18T21:59:44
2018-10-18T19:55:20
NONE
null
Ref: https://www.sqlite.org/json1.html#jgrouparray Right now I'm using these via `fn`, but I have to manually load the resulting JSON. What's the best way to have these come out as native Python lists or dicts? Example of current usage: ```python name, messages = (User.select(User.name, ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1762/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1762/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1761
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1761/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1761/comments
https://api.github.com/repos/coleifer/peewee/issues/1761/events
https://github.com/coleifer/peewee/issues/1761
371,499,498
MDU6SXNzdWUzNzE0OTk0OTg=
1,761
model_to_dict + ManyToManyField shows abthrough_set instead of bs
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "You should use `manytomany=True`:\r\n\r\nhttp://docs.peewee-orm.com/en/latest/peewee/playhouse.html#model_to_dict" ]
2018-10-18T12:10:50
2018-10-18T17:17:00
2018-10-18T17:16:59
NONE
null
>>> model_to_dict(db['card'].select()[1], backrefs=True) {'id': 1520716970993, 'note': {'id': 1520716965129, 'data': {'中文': '我们现在没有钱。', 'Pinyin': 'Wǒmen xiànzài méiyǒu qián.', 'English': "We don't have money now.", 'Notes': '', 'Example Type': '', 'Article T...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1761/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1761/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1760
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1760/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1760/comments
https://api.github.com/repos/coleifer/peewee/issues/1760/events
https://github.com/coleifer/peewee/issues/1760
371,338,160
MDU6SXNzdWUzNzEzMzgxNjA=
1,760
dont support comment?
{ "login": "mouday", "id": 24365682, "node_id": "MDQ6VXNlcjI0MzY1Njgy", "avatar_url": "https://avatars.githubusercontent.com/u/24365682?v=4", "gravatar_id": "", "url": "https://api.github.com/users/mouday", "html_url": "https://github.com/mouday", "followers_url": "https://api.github.com/users/mouday/fo...
[]
closed
false
null
[]
null
[ "Nope, not at present anyways." ]
2018-10-18T02:37:12
2018-10-18T17:15:20
2018-10-18T17:15:20
NONE
null
```sql create table table_name ( id int comment "this is field comment" ) comment "this is table comment" ``` peewee not support this help_text?
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1760/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1760/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1759
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1759/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1759/comments
https://api.github.com/repos/coleifer/peewee/issues/1759/events
https://github.com/coleifer/peewee/issues/1759
371,030,938
MDU6SXNzdWUzNzEwMzA5Mzg=
1,759
.delete_instance() does not delete ManyToManyField's relationship, causing duplicate key on next create
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "You have a couple options.\r\n\r\nYou can specify `on_delete='cascade'`, which will automatically delete the DataTag objects when a Data or Tag gets deleted:\r\n\r\n```python\r\ntags = ManyToManyField(Tag, backref='data', on_delete='cascade')\r\n```\r\n\r\nOr, you can specify ``recursive=True`` when calling `delet...
2018-10-17T11:42:24
2018-10-17T12:48:48
2018-10-17T12:48:48
NONE
null
class Tag(BaseModel): name = TextField() class Data(BaseModel): tags = ManyToManyField(Tag, backref='data') DataTag = Data.tags.get_through_model() db_data = Data.create() Tag.get_or_create(name='foo')[0].data.add(db_data) Tag.get_or_create(name='bar')[0].data.add(db...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1759/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1759/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1758
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1758/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1758/comments
https://api.github.com/repos/coleifer/peewee/issues/1758/events
https://github.com/coleifer/peewee/issues/1758
370,890,346
MDU6SXNzdWUzNzA4OTAzNDY=
1,758
A curious key represent and a little prob
{ "login": "piperck", "id": 8776176, "node_id": "MDQ6VXNlcjg3NzYxNzY=", "avatar_url": "https://avatars.githubusercontent.com/u/8776176?v=4", "gravatar_id": "", "url": "https://api.github.com/users/piperck", "html_url": "https://github.com/piperck", "followers_url": "https://api.github.com/users/piperck/...
[]
closed
false
null
[]
null
[ "For scalar aggregations, you can:\r\n\r\n```\r\nmax_id, min_id = User.select(fn.MAX(User.id), fn.MIN(User.id)).scalar(as_tuple=True)\r\n```\r\n\r\nIf you want \"User\" instances, then assign an alias to disambiguate the selected columns:\r\n\r\n```\r\nquery = User.select(fn.MAX(User.id).alias('max_id'), fn.MIN(Use...
2018-10-17T04:04:51
2018-10-17T12:42:30
2018-10-17T12:42:30
CONTRIBUTOR
null
```python In [1]: from apps.models.offline.user import * In [2]: from peewee import * In [16]: User.select(fn.MAX(User.id), fn.MIN(User.id)).sql() Out[16]: ('SELECT MAX(`t1`.`id`), MIN(`t1`.`id`) FROM `user` AS `t1`', []) In [17]: User.select(fn.MAX(User.id), fn.MIN(User.id)).__dict__ Out[17]: {'_alias': N...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1758/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1758/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1757
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1757/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1757/comments
https://api.github.com/repos/coleifer/peewee/issues/1757/events
https://github.com/coleifer/peewee/issues/1757
370,728,878
MDU6SXNzdWUzNzA3Mjg4Nzg=
1,757
peewee.OperationalError: SSL error: bad decrypt
{ "login": "maxcountryman", "id": 74351, "node_id": "MDQ6VXNlcjc0MzUx", "avatar_url": "https://avatars.githubusercontent.com/u/74351?v=4", "gravatar_id": "", "url": "https://api.github.com/users/maxcountryman", "html_url": "https://github.com/maxcountryman", "followers_url": "https://api.github.com/user...
[]
closed
false
null
[]
null
[ "I'm guessing you're opening the database connection before the fork? Try opening the connection after forking. ", "Actually no, I’m not. The connection is initialized in the function the executor handles. ", "Can you share a minimal example?", "If you could please let me know:\r\n\r\n* What database engine /...
2018-10-16T17:54:32
2018-10-18T17:17:09
2018-10-18T17:17:09
NONE
null
Running into this issue when spawning processes with `concurrent.futures.ProcessPoolExecutor`.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1757/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1757/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1756
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1756/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1756/comments
https://api.github.com/repos/coleifer/peewee/issues/1756/events
https://github.com/coleifer/peewee/issues/1756
370,720,751
MDU6SXNzdWUzNzA3MjA3NTE=
1,756
`object has no attribute` error on join
{ "login": "skatenerd", "id": 880217, "node_id": "MDQ6VXNlcjg4MDIxNw==", "avatar_url": "https://avatars.githubusercontent.com/u/880217?v=4", "gravatar_id": "", "url": "https://api.github.com/users/skatenerd", "html_url": "https://github.com/skatenerd", "followers_url": "https://api.github.com/users/skat...
[]
closed
false
null
[]
null
[ "Is the `joinrow` a `ForeignKeyField`? Which model is the foreign-key on?", "It's an `IntegerField` on both tables", "I tried to replicate it, but it seems to be working correctly in my test:\r\n\r\n```python\r\nclass PetType(TestModel):\r\n name = TextField()\r\n flags = IntegerField(default=0)\r\n ty...
2018-10-16T17:33:18
2018-10-16T21:03:15
2018-10-16T21:00:55
NONE
null
Suppose I have a many-to-one relationship between `products` and `departments`, where both tables have a `joinrow_id` column. Suppose that we only have one product and its `name` is `"chair"`. The chair is in the only department, whose name is "all products", and whose "priority" is null. I'm seeing inconsistent b...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1756/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1756/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1755
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1755/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1755/comments
https://api.github.com/repos/coleifer/peewee/issues/1755/events
https://github.com/coleifer/peewee/pull/1755
370,350,089
MDExOlB1bGxSZXF1ZXN0MjIzMDQ4MDUx
1,755
[Docs] Update models.rst
{ "login": "MinchinWeb", "id": 1548809, "node_id": "MDQ6VXNlcjE1NDg4MDk=", "avatar_url": "https://avatars.githubusercontent.com/u/1548809?v=4", "gravatar_id": "", "url": "https://api.github.com/users/MinchinWeb", "html_url": "https://github.com/MinchinWeb", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "replaced by 05a1b468e1b5f885496015e2c749f09eeb7dcd1d\r\n\r\nthanks!", "Awesome!" ]
2018-10-15T21:25:02
2018-10-15T21:33:50
2018-10-15T21:31:26
NONE
null
datetime import is required to be able to copy and paste this code example
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1755/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1755/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1755", "html_url": "https://github.com/coleifer/peewee/pull/1755", "diff_url": "https://github.com/coleifer/peewee/pull/1755.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1755.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1754
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1754/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1754/comments
https://api.github.com/repos/coleifer/peewee/issues/1754/events
https://github.com/coleifer/peewee/pull/1754
370,341,931
MDExOlB1bGxSZXF1ZXN0MjIzMDQxNTgy
1,754
show how to combine .tuples() and .iterate()
{ "login": "iurly", "id": 20878097, "node_id": "MDQ6VXNlcjIwODc4MDk3", "avatar_url": "https://avatars.githubusercontent.com/u/20878097?v=4", "gravatar_id": "", "url": "https://api.github.com/users/iurly", "html_url": "https://github.com/iurly", "followers_url": "https://api.github.com/users/iurly/follow...
[]
closed
false
null
[]
null
[]
2018-10-15T21:00:39
2018-10-15T21:11:40
2018-10-15T21:11:40
CONTRIBUTOR
null
From the original description, it sounded like using .tuples(), .dicts() etc would imply .iterate(), which is not the case. Explicitly state that for maximum performance you might want to do both, and show how you should do it.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1754/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1754/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1754", "html_url": "https://github.com/coleifer/peewee/pull/1754", "diff_url": "https://github.com/coleifer/peewee/pull/1754.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1754.patch", "merged_at": "2018-10-15T21:11:40" }
https://api.github.com/repos/coleifer/peewee/issues/1753
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1753/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1753/comments
https://api.github.com/repos/coleifer/peewee/issues/1753/events
https://github.com/coleifer/peewee/pull/1753
370,322,061
MDExOlB1bGxSZXF1ZXN0MjIzMDI2MTA2
1,753
Update models.rst
{ "login": "Walicen", "id": 19557339, "node_id": "MDQ6VXNlcjE5NTU3MzM5", "avatar_url": "https://avatars.githubusercontent.com/u/19557339?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Walicen", "html_url": "https://github.com/Walicen", "followers_url": "https://api.github.com/users/Walice...
[]
closed
false
null
[]
null
[ "This is incorrect. Fields are non-null by default. So the documentation shows the field parameter with its default value, which is False.", "OH Sorry!" ]
2018-10-15T20:03:50
2018-10-16T00:33:06
2018-10-15T20:32:40
NONE
null
Allow null values in the fields
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1753/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1753/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1753", "html_url": "https://github.com/coleifer/peewee/pull/1753", "diff_url": "https://github.com/coleifer/peewee/pull/1753.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1753.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1752
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1752/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1752/comments
https://api.github.com/repos/coleifer/peewee/issues/1752/events
https://github.com/coleifer/peewee/pull/1752
369,409,964
MDExOlB1bGxSZXF1ZXN0MjIyMzU3NjM4
1,752
fix bug group by extend
{ "login": "nhatHero", "id": 44079687, "node_id": "MDQ6VXNlcjQ0MDc5Njg3", "avatar_url": "https://avatars.githubusercontent.com/u/44079687?v=4", "gravatar_id": "", "url": "https://api.github.com/users/nhatHero", "html_url": "https://github.com/nhatHero", "followers_url": "https://api.github.com/users/nha...
[]
closed
false
null
[]
null
[ "Thank you!" ]
2018-10-12T05:58:27
2018-10-12T13:59:06
2018-10-12T13:59:02
NONE
null
I fixed bug group by extend - Examples: users table have columns: id and username Tweet table have contain user_id column. user_id is foreign key of users table ```sql query = (User .select(User, fn.COUNT(Tweet.id).alias('tweet_count')) .join(Tweet, JOIN.LEFT_OUTER) ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1752/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1752/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1752", "html_url": "https://github.com/coleifer/peewee/pull/1752", "diff_url": "https://github.com/coleifer/peewee/pull/1752.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1752.patch", "merged_at": "2018-10-12T13:59:02" }
https://api.github.com/repos/coleifer/peewee/issues/1751
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1751/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1751/comments
https://api.github.com/repos/coleifer/peewee/issues/1751/events
https://github.com/coleifer/peewee/issues/1751
369,281,758
MDU6SXNzdWUzNjkyODE3NTg=
1,751
elastic-apm intrumentation
{ "login": "claygorman", "id": 4524500, "node_id": "MDQ6VXNlcjQ1MjQ1MDA=", "avatar_url": "https://avatars.githubusercontent.com/u/4524500?v=4", "gravatar_id": "", "url": "https://api.github.com/users/claygorman", "html_url": "https://github.com/claygorman", "followers_url": "https://api.github.com/users...
[]
closed
false
null
[]
null
[ "I'm glad you like the library.\r\n\r\nSorry, never heard of this project." ]
2018-10-11T19:58:21
2018-10-11T20:02:58
2018-10-11T20:02:58
NONE
null
Hey there, Great library by the way! I use it quite a bit. I was wondering what your thoughts are on integrating with https://github.com/elastic/apm-agent-python/blob/master/elasticapm/instrumentation/register.py as a built in? Thanks in advance!
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1751/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1751/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1750
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1750/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1750/comments
https://api.github.com/repos/coleifer/peewee/issues/1750/events
https://github.com/coleifer/peewee/issues/1750
368,045,313
MDU6SXNzdWUzNjgwNDUzMTM=
1,750
1. Cannot create unique index on large text fields 2. Documentation regarding PostGresQL full-text search is unclear
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "What are you asking? The title of the issue says one thing, but the question within your post seems to be about adding a `unique` constraint to a `TextField`?", "In the example, \"query\" is a text search query. I'll rename to make it more clear.", "aa12e607e1b8d073875afbc761c55a2b572271aa", "> In the exampl...
2018-10-09T05:24:10
2018-10-11T00:31:05
2018-10-09T12:43:00
NONE
null
What is `query` in `blog_search(query)` in http://docs.peewee-orm.com/en/latest/peewee/playhouse.html#full-text-search ? As a matter of fact, I am trying to do: class Cell(BaseModel): content = pv.TextField(unique=True) db_cell = Cell.get_or_none(Cell.content.contains(new_data)) if db...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1750/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1750/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1749
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1749/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1749/comments
https://api.github.com/repos/coleifer/peewee/issues/1749/events
https://github.com/coleifer/peewee/issues/1749
367,717,962
MDU6SXNzdWUzNjc3MTc5NjI=
1,749
Edit field type with Migrator
{ "login": "bastiendonjon", "id": 3437591, "node_id": "MDQ6VXNlcjM0Mzc1OTE=", "avatar_url": "https://avatars.githubusercontent.com/u/3437591?v=4", "gravatar_id": "", "url": "https://api.github.com/users/bastiendonjon", "html_url": "https://github.com/bastiendonjon", "followers_url": "https://api.github....
[]
closed
false
null
[]
null
[ "Using peewee's migrating tools you'd need to drop the field and recreate it. Performing column changes requires (sometimes) changing any data present within the column, and that's left to the application rather than being handled by the library." ]
2018-10-08T10:02:06
2018-10-08T17:24:49
2018-10-08T17:24:48
NONE
null
Hello, It's not possible to change field type with migrator ? I want edit DateField to DateTimeField Thanks
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1749/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1749/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1748
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1748/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1748/comments
https://api.github.com/repos/coleifer/peewee/issues/1748/events
https://github.com/coleifer/peewee/issues/1748
367,552,583
MDU6SXNzdWUzNjc1NTI1ODM=
1,748
DeprecationWarning Using or importing the ABCs from 'collections'
{ "login": "trim21", "id": 13553903, "node_id": "MDQ6VXNlcjEzNTUzOTAz", "avatar_url": "https://avatars.githubusercontent.com/u/13553903?v=4", "gravatar_id": "", "url": "https://api.github.com/users/trim21", "html_url": "https://github.com/trim21", "followers_url": "https://api.github.com/users/trim21/fo...
[]
closed
false
null
[]
null
[ "49ca301f319a6a70d7acd1425b66fa5cbdf75d8e" ]
2018-10-07T13:01:22
2018-10-07T15:50:49
2018-10-07T15:50:49
NONE
null
peewee.py:2256: DeprecationWarning: Using or importing the ABCs from 'collections' instead of from 'collections.abc' is deprecated, and in 3.8 it will stop working is_dict = isinstance(row, collections.Mapping) python version 3.7.0 peewee version 3.7.1
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1748/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1748/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1747
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1747/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1747/comments
https://api.github.com/repos/coleifer/peewee/issues/1747/events
https://github.com/coleifer/peewee/issues/1747
366,937,366
MDU6SXNzdWUzNjY5MzczNjY=
1,747
TimestampField appears to strip milliseconds
{ "login": "tbaxter-18f", "id": 32077682, "node_id": "MDQ6VXNlcjMyMDc3Njgy", "avatar_url": "https://avatars.githubusercontent.com/u/32077682?v=4", "gravatar_id": "", "url": "https://api.github.com/users/tbaxter-18f", "html_url": "https://github.com/tbaxter-18f", "followers_url": "https://api.github.com/...
[]
closed
false
null
[]
null
[ "Well, here's the thing. Peewee's `TimestampField` is designed to work with python `datetime` objects, which is typically what you want in your application code -- it just uses an integer timestamp for storage. That being said, you still *can* specify integer / floating-point timestamps. For sub-second resolutions ...
2018-10-04T19:31:40
2018-10-04T20:04:24
2018-10-04T20:04:24
NONE
null
given a timestamp like 1419440770.000058 when I create the object, the timestamp appears to be stored as 1419440770, with no milliseconds present any longer.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1747/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1747/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1746
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1746/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1746/comments
https://api.github.com/repos/coleifer/peewee/issues/1746/events
https://github.com/coleifer/peewee/issues/1746
366,161,434
MDU6SXNzdWUzNjYxNjE0MzQ=
1,746
Consistency between `Dataset.insert` / `Dataset.update` and `Model.insert` / `Model.update`
{ "login": "patarapolw", "id": 21255931, "node_id": "MDQ6VXNlcjIxMjU1OTMx", "avatar_url": "https://avatars.githubusercontent.com/u/21255931?v=4", "gravatar_id": "", "url": "https://api.github.com/users/patarapolw", "html_url": "https://github.com/patarapolw", "followers_url": "https://api.github.com/use...
[]
closed
false
null
[]
null
[ "@patarapolw -- I think you may misunderstand the point of `dataset`. The `dataset` library is strictly a convenience API -- although it exposes a lot of functionality, it is not intended to implement all the features you might expect to find using standard Peewee APIs.\r\n\r\nAlso, your upsert implementation is wi...
2018-10-03T03:30:56
2018-10-04T03:40:22
2018-10-03T03:45:21
NONE
null
It's not consistent in that making transferring from Dataset to SqliteExtDatabase harder. Furthermore, there is no upsert function. I have to create my own. class BaseModel(pv.Model): @classmethod def upsert(cls, columns, **kwargs): query = (getattr(cls, columns[0]) == kwargs.ge...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1746/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1746/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1745
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1745/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1745/comments
https://api.github.com/repos/coleifer/peewee/issues/1745/events
https://github.com/coleifer/peewee/issues/1745
365,537,810
MDU6SXNzdWUzNjU1Mzc4MTA=
1,745
FTSModel associated to table with non-integer primary key
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "There's no good reason to use a non-integer primary key in SQLite (unless you're also using `WITHOUT ROWID` in your table). SQLite's btree uses a 64-bit integer internally to store the rowid of a given row. If you use an integer primary key, then it will utilize that internal rowid automatically.\r\n\r\nIf you wan...
2018-10-01T16:18:49
2018-10-02T07:02:01
2018-10-01T16:27:28
NONE
null
I'm working on a database for notes. The Notes table uses a non-integer primary key with hash text ids. I would like to do fulltext search on the notes, so I wanted to use the FTS functionality of SQLite, but I see that the main id there is an integer. The typical peewee example proceeds like: ``` query = (Entry...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1745/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1745/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1744
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1744/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1744/comments
https://api.github.com/repos/coleifer/peewee/issues/1744/events
https://github.com/coleifer/peewee/issues/1744
365,177,166
MDU6SXNzdWUzNjUxNzcxNjY=
1,744
NameError: name 'EnclosedClause' is not defined
{ "login": "jberkel", "id": 18891, "node_id": "MDQ6VXNlcjE4ODkx", "avatar_url": "https://avatars.githubusercontent.com/u/18891?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jberkel", "html_url": "https://github.com/jberkel", "followers_url": "https://api.github.com/users/jberkel/follower...
[]
closed
false
null
[]
null
[ "Oversight on my part -- fixed. Thanks for reporting!" ]
2018-09-30T00:03:57
2018-09-30T12:40:37
2018-09-30T12:40:03
CONTRIBUTOR
null
After upgrading to 3.x some FTS-related code stopped working: ``` ---------------------------------------------------------------------- Traceback (most recent call last): File "/Users/jan/projects/lexi/importer/src/test/python/test_search.py", line 8, in setUp self.reindex() File "/Users/jan/projects/l...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1744/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1744/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1743
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1743/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1743/comments
https://api.github.com/repos/coleifer/peewee/issues/1743/events
https://github.com/coleifer/peewee/pull/1743
365,155,331
MDExOlB1bGxSZXF1ZXN0MjE5MTYyMjg2
1,743
Adds support for MySQL SSL connection kwargs
{ "login": "jwilner", "id": 1879661, "node_id": "MDQ6VXNlcjE4Nzk2NjE=", "avatar_url": "https://avatars.githubusercontent.com/u/1879661?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jwilner", "html_url": "https://github.com/jwilner", "followers_url": "https://api.github.com/users/jwilner/...
[]
closed
false
null
[]
null
[]
2018-09-29T18:23:43
2018-09-30T12:27:28
2018-09-30T12:27:28
NONE
null
Addresses https://github.com/coleifer/peewee/issues/1742 To configure SSL connections with MySQL,`MySQLdb.connect` expects a dictionary of SSL params. Currently, `playhouse.db_url` logic provides no way of parameterizing an SSL connection via the URI. This pull request apes `SQLAlchemy` by letting users specify nes...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1743/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1743/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1743", "html_url": "https://github.com/coleifer/peewee/pull/1743", "diff_url": "https://github.com/coleifer/peewee/pull/1743.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1743.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1742
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1742/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1742/comments
https://api.github.com/repos/coleifer/peewee/issues/1742/events
https://github.com/coleifer/peewee/issues/1742
365,153,762
MDU6SXNzdWUzNjUxNTM3NjI=
1,742
support sqlalchemy-style MySQL URI parameters
{ "login": "jwilner", "id": 1879661, "node_id": "MDQ6VXNlcjE4Nzk2NjE=", "avatar_url": "https://avatars.githubusercontent.com/u/1879661?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jwilner", "html_url": "https://github.com/jwilner", "followers_url": "https://api.github.com/users/jwilner/...
[]
closed
false
null
[]
null
[ "I think I'm going to pass. MySQL-Connector uses different arguments: https://dev.mysql.com/doc/connector-python/en/connector-python-connectargs.html\r\n\r\nI think this is going a bit above and beyond what the db url module was intended to do." ]
2018-09-29T18:01:31
2018-09-30T12:27:17
2018-09-30T12:27:17
NONE
null
The MySQL driver expects a dictionary of SSL parameters -- `{"cert": cert, "key": pkey, "ca": ca}`. SQLAlchemy supports these as URI components prefixed with `ssl` -- e.g. `?ssl_cert={cert}&ssl_key={pkey}&ssl_ca={ca}`. Currently, `playhouse.db_uri` has no comparable behavior, because although it parses out many types f...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1742/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1742/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1741
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1741/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1741/comments
https://api.github.com/repos/coleifer/peewee/issues/1741/events
https://github.com/coleifer/peewee/pull/1741
365,152,584
MDExOlB1bGxSZXF1ZXN0MjE5MTYwNTQx
1,741
Add support for quoted creds
{ "login": "jwilner", "id": 1879661, "node_id": "MDQ6VXNlcjE4Nzk2NjE=", "avatar_url": "https://avatars.githubusercontent.com/u/1879661?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jwilner", "html_url": "https://github.com/jwilner", "followers_url": "https://api.github.com/users/jwilner/...
[]
closed
false
null
[]
null
[ "Merged an equivalent patch, thanks for providing this. I didn't think it was sensible to unquote the username so I removed that logic and changed the parameter to \"unquote_password\" (vs \"unquote_creds\")." ]
2018-09-29T17:46:42
2018-09-30T12:22:22
2018-09-30T12:22:22
NONE
null
Addresses https://github.com/coleifer/peewee/issues/1740 - Maintains backwards compatibility by defaulting to current behavior - Adds flag to all entry points. - Tests default behavior is preserved but flag provides new behavior.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1741/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1741/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1741", "html_url": "https://github.com/coleifer/peewee/pull/1741", "diff_url": "https://github.com/coleifer/peewee/pull/1741.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1741.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1740
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1740/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1740/comments
https://api.github.com/repos/coleifer/peewee/issues/1740/events
https://github.com/coleifer/peewee/issues/1740
365,150,969
MDU6SXNzdWUzNjUxNTA5Njk=
1,740
`playhouse.db_uri.connect` doesn't support db passwords requiring escape
{ "login": "jwilner", "id": 1879661, "node_id": "MDQ6VXNlcjE4Nzk2NjE=", "avatar_url": "https://avatars.githubusercontent.com/u/1879661?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jwilner", "html_url": "https://github.com/jwilner", "followers_url": "https://api.github.com/users/jwilner/...
[]
closed
false
null
[]
null
[ "Merged an equivalent patch, with the difference being that it does not include logic to unquote the username -- just the password." ]
2018-09-29T17:26:14
2018-09-30T12:21:10
2018-09-30T12:20:33
NONE
null
## the problem To provide a password (or username) with characters unsafe for a URI, users must escape them to include them in the authority of a URI. However, the standard python password url parse logic -- `urllib.parse(uri).password` -- doesn't automatically unquote a password; clients of that code must . As it i...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1740/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1740/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1739
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1739/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1739/comments
https://api.github.com/repos/coleifer/peewee/issues/1739/events
https://github.com/coleifer/peewee/issues/1739
365,134,432
MDU6SXNzdWUzNjUxMzQ0MzI=
1,739
3.x index renaming
{ "login": "jberkel", "id": 18891, "node_id": "MDQ6VXNlcjE4ODkx", "avatar_url": "https://avatars.githubusercontent.com/u/18891?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jberkel", "html_url": "https://github.com/jberkel", "followers_url": "https://api.github.com/users/jberkel/follower...
[]
closed
false
null
[]
null
[ "I'm not seeing that, actually. I added a testcase which to me validates that the behavior in 3.x respects the table name as the prefix.\r\n\r\n47170c381329057f26ee5fb121eef54dbb7944e3", "Thanks for investigating, found the issue. I wasn't using `legacy_table_names = False`.", "When using legacy table names, Pe...
2018-09-29T13:55:40
2018-09-30T22:05:25
2018-09-30T12:10:45
CONTRIBUTOR
null
I'm not sure if this is working as intended, but after upgrading to 3.x I get a different schema because of index renames. I use `table_name` to set the table name, but the index name seems to use the automatic table name as prefix, e.g. ```python class Foo some_text = TextField(index=True) class Met...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1739/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1739/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1738
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1738/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1738/comments
https://api.github.com/repos/coleifer/peewee/issues/1738/events
https://github.com/coleifer/peewee/issues/1738
364,534,534
MDU6SXNzdWUzNjQ1MzQ1MzQ=
1,738
Incorrect sql generated by custom field
{ "login": "fy0", "id": 1579850, "node_id": "MDQ6VXNlcjE1Nzk4NTA=", "avatar_url": "https://avatars.githubusercontent.com/u/1579850?v=4", "gravatar_id": "", "url": "https://api.github.com/users/fy0", "html_url": "https://github.com/fy0", "followers_url": "https://api.github.com/users/fy0/followers", "f...
[]
closed
false
null
[]
null
[ "In 3.x you need to use `field_type` instead of `db_field`. The docs are pretty clear:\r\n\r\nhttp://docs.peewee-orm.com/en/latest/peewee/models.html#creating-a-custom-field", "@coleifer Sorry, in fact I had read the document before, but copy & paste my old code in the same file when I programming..." ]
2018-09-27T15:33:52
2018-09-27T16:55:08
2018-09-27T16:07:02
NONE
null
My database is PostgreSQL. Field: ``` class INETField(peewee.Field): db_field = 'inet' ``` Model: ``` reputation = IntegerField(default=0) ip_registered = INETField(default=None, null=True) ``` Error: ``` cursor.execute(sql, params or ()) peewee.ProgrammingError: syntax error at or n...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1738/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1738/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1737
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1737/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1737/comments
https://api.github.com/repos/coleifer/peewee/issues/1737/events
https://github.com/coleifer/peewee/issues/1737
364,439,523
MDU6SXNzdWUzNjQ0Mzk1MjM=
1,737
Postgres ON CONFLICT for a named index
{ "login": "Nelluk", "id": 2545428, "node_id": "MDQ6VXNlcjI1NDU0Mjg=", "avatar_url": "https://avatars.githubusercontent.com/u/2545428?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Nelluk", "html_url": "https://github.com/Nelluk", "followers_url": "https://api.github.com/users/Nelluk/foll...
[]
closed
false
null
[]
null
[ "I have no clue why that is, because Postgres will infer the correct unique index if the columns are provided.\r\n\r\nFor example:\r\n\r\n```python\r\n\r\nclass KV(Model):\r\n key = TextField()\r\n value = TextField()\r\n extra = TextField(default='')\r\n class Meta:\r\n database = db\r\n ...
2018-09-27T11:57:31
2018-09-27T19:39:14
2018-09-27T19:37:15
NONE
null
I have a table Player with a unique index on two columns. I am trying to do an UPSERT with this index as the ON CONFLICT target. ```python class Player(BaseModel): discord_member = ForeignKeyField(DiscordMember, unique=False, null=False) guild_id = BitField(unique=False, null=False) nick = TextField(...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1737/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1737/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1736
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1736/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1736/comments
https://api.github.com/repos/coleifer/peewee/issues/1736/events
https://github.com/coleifer/peewee/issues/1736
364,246,221
MDU6SXNzdWUzNjQyNDYyMjE=
1,736
`sqlall()`gone missing in 3.x
{ "login": "jberkel", "id": 18891, "node_id": "MDQ6VXNlcjE4ODkx", "avatar_url": "https://avatars.githubusercontent.com/u/18891?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jberkel", "html_url": "https://github.com/jberkel", "followers_url": "https://api.github.com/users/jberkel/follower...
[]
closed
false
null
[]
null
[ "> I could easily reproduce this with some extra lines of code\r\n\r\nGo for it.\r\n\r\nUpdated the changes documentation to reflect the removal of this. Apologies for the confusion." ]
2018-09-26T23:08:19
2018-09-27T03:09:46
2018-09-27T03:09:46
CONTRIBUTOR
null
I'm just migrating a bunch of code from 2.x to 3.x. Nice job! My code previously used `Model.sqlall()` to create a file with the current SQL schema. This method is gone in 3.x, and I don't see a replacement for it. I could easily reproduce this with some extra lines of code but I still think it's a worthwhile method t...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1736/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1736/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1735
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1735/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1735/comments
https://api.github.com/repos/coleifer/peewee/issues/1735/events
https://github.com/coleifer/peewee/issues/1735
362,861,466
MDU6SXNzdWUzNjI4NjE0NjY=
1,735
How to use TO_CHAR function
{ "login": "Maheshkumar094", "id": 39484115, "node_id": "MDQ6VXNlcjM5NDg0MTE1", "avatar_url": "https://avatars.githubusercontent.com/u/39484115?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Maheshkumar094", "html_url": "https://github.com/Maheshkumar094", "followers_url": "https://api.gi...
[]
closed
false
null
[]
null
[ "To translate:\r\n\r\n```sql\r\nTO_CHAR(created_at at time zone 'Asia/Kolkata','DD-MON-YYYY') as date\r\n```\r\n\r\nYou'll probably need to use NodeList:\r\n\r\n```python\r\nexpr = NodeList((Txn.created_at, SQL('at time zone'), 'Asia/Kolkata'))\r\ndate_expr = fn.TO_CHAR(expr, 'DD-MON-YYYY')\r\n\r\n...select(Txn.id,...
2018-09-22T14:30:21
2018-09-22T17:55:51
2018-09-22T16:39:50
NONE
null
@coleifer How to use postgress TO_CHAR function in peewee In native sql query `SELECT id, TO_CHAR(created_at at time zone 'Asia/Kolkata','DD-MON-YYYY') as date from txn order by id desc limit 5` -------------------------------- result ------------------------------ **id date** 131; "19-SEP-2018"...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1735/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1735/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1734
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1734/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1734/comments
https://api.github.com/repos/coleifer/peewee/issues/1734/events
https://github.com/coleifer/peewee/issues/1734
362,752,110
MDU6SXNzdWUzNjI3NTIxMTA=
1,734
Psycopg2 warning
{ "login": "yabirgb", "id": 5068010, "node_id": "MDQ6VXNlcjUwNjgwMTA=", "avatar_url": "https://avatars.githubusercontent.com/u/5068010?v=4", "gravatar_id": "", "url": "https://api.github.com/users/yabirgb", "html_url": "https://github.com/yabirgb", "followers_url": "https://api.github.com/users/yabirgb/...
[]
closed
false
null
[]
null
[ "That doesn't sound correct at all. `psycopg2-binary` should install a psycopg2 package normally. It's just a binary package rather than a source package.", "See:\r\n\r\n```\r\n$ pip freeze | grep psycopg2\r\n65:psycopg2-binary==2.7.5\r\n\r\n$ ipython\r\nPython 3.7.0 (default, Jul 15 2018, 18:17:02) \r\nType 'cop...
2018-09-21T19:49:24
2018-09-22T16:48:39
2018-09-21T22:48:04
NONE
null
I get this warning when running peewee with postgresql: `UserWarning: The psycopg2 wheel package will be renamed from release 2.8; in order to keep installing from binary please use "pip install psycopg2-binary" instead. For details see: <http://initd.org/psycopg/docs/install.html#binary-install-from-pypi>.` If I...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1734/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1734/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1733
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1733/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1733/comments
https://api.github.com/repos/coleifer/peewee/issues/1733/events
https://github.com/coleifer/peewee/issues/1733
362,606,901
MDU6SXNzdWUzNjI2MDY5MDE=
1,733
id field value is None
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "Uh... I know for a fact that something as fundamental as retrieving a column value from a select query is working -- it's covered quite thoroughly in the tests.\r\n\r\nPerhaps you can provide a test-case or complete script so I can replicate the issue?", "Ok, you are fully right. Your mention of tests gave me an...
2018-09-21T13:05:41
2018-09-21T15:19:19
2018-09-21T15:19:18
NONE
null
I'm trying to get the id field of a SQLite table but I always get None: # Model: ``` class Document(BaseModel): id = IntegerField(db_column='id', primary_key=True, null=False, index=True) class Meta: db_table = 'Documents' ``` # Query: ``` query = Document.select() with db.atomic(): ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1733/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1733/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1732
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1732/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1732/comments
https://api.github.com/repos/coleifer/peewee/issues/1732/events
https://github.com/coleifer/peewee/issues/1732
362,567,158
MDU6SXNzdWUzNjI1NjcxNTg=
1,732
sqlite database stores 'true'/'false' in INT type
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "> I'm not very familiar with databases, so I don't know if this that Mendeley does is a very unusual behavior, or why wouldn't they just store 0/1, but this is out of my control. So I was wondering which could be the best approach to deal with this issue.\r\n\r\nThis is very bad behavior, in my opinion.\r\n\r\nYou...
2018-09-21T11:08:50
2018-09-22T02:21:45
2018-09-22T02:21:45
NONE
null
I'm using peewee to handle the database stored by the Mendeley app. It turns out in its database Mendeley defines binary fields as INT but populate its values with 'true'/'false' strings. As a result, when reading this database through the models automatically imported by pwiz (which parses these fields as 'IntegerFi...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1732/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1732/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1731
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1731/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1731/comments
https://api.github.com/repos/coleifer/peewee/issues/1731/events
https://github.com/coleifer/peewee/pull/1731
362,520,733
MDExOlB1bGxSZXF1ZXN0MjE3MjE2ODc2
1,731
Match FLOAT and CHAR[...] in sqlite reflection.
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "So SQLite only supports the following data-types:\r\n\r\n* TEXT\r\n* BLOB\r\n* INTEGER\r\n* REAL\r\n* NULL\r\n\r\nI think I'm going to pass on the square bracket change, but will add support for float along with some others:\r\n\r\nd31e7bf972e69e227c10694fac71b966959e715f" ]
2018-09-21T09:02:40
2018-09-21T13:35:10
2018-09-21T13:35:10
NONE
null
Fix issue related to https://github.com/coleifer/peewee/issues/1730#issuecomment-423461785
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1731/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1731/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1731", "html_url": "https://github.com/coleifer/peewee/pull/1731", "diff_url": "https://github.com/coleifer/peewee/pull/1731.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1731.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1730
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1730/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1730/comments
https://api.github.com/repos/coleifer/peewee/issues/1730/events
https://github.com/coleifer/peewee/issues/1730
362,068,299
MDU6SXNzdWUzNjIwNjgyOTk=
1,730
VARCHAR not correctly parsed in pwiz
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "Thanks, I've fixed the issue where VARCHAR without a length constraint is now recognized correctly with Sqlite -- fdeb92c1639c1dc9301ae501b95e36d83a63ee74\r\n\r\nRegarding the max_length parameter, this has no effect in Sqlite and so it is fine to ignore it:\r\n\r\n```sql\r\nsqlite> create table kv (key varchar(4)...
2018-09-20T08:12:23
2018-09-23T01:40:45
2018-09-20T14:10:06
NONE
null
Hi, I was using pwiz in python3 with sqlite and it seems VARCHAR fields are not correctly parsed: If no max length is provided, the field is not recognized: ``` CREATE TABLE COMPANY( ID INT PRIMARY KEY NOT NULL, NAME VARCHAR NOT NULL, AGE INT NOT NULL, ADDRESS T...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1730/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1730/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1729
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1729/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1729/comments
https://api.github.com/repos/coleifer/peewee/issues/1729/events
https://github.com/coleifer/peewee/issues/1729
362,060,895
MDU6SXNzdWUzNjIwNjA4OTU=
1,729
Different syntax for python2 and python3
{ "login": "jbriales", "id": 6850478, "node_id": "MDQ6VXNlcjY4NTA0Nzg=", "avatar_url": "https://avatars.githubusercontent.com/u/6850478?v=4", "gravatar_id": "", "url": "https://api.github.com/users/jbriales", "html_url": "https://github.com/jbriales", "followers_url": "https://api.github.com/users/jbria...
[]
closed
false
null
[]
null
[ "Uhh, it sounds like in one case you are running an old version of Peewee.\r\n\r\nYou can verify by running\r\n\r\n```\r\npython2 -c \"import peewee; print(peewee.__version__)\"\r\npython3 -c \"import peewee; print(peewee.__version__)\"\r\n```" ]
2018-09-20T07:51:50
2018-09-20T13:48:35
2018-09-20T13:48:35
NONE
null
Hi, I'm just starting to use peewee and pwiz, and it took a while to figure out this error: TypeError: __init__() got an unexpected keyword argument 'column_name' Apparently the syntax is different in the python2 and python3 versions, so I got different results calling: `python2 -m pwiz -e sqlite "testDB.sqlite" > ...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1729/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1729/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1728
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1728/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1728/comments
https://api.github.com/repos/coleifer/peewee/issues/1728/events
https://github.com/coleifer/peewee/pull/1728
361,329,149
MDExOlB1bGxSZXF1ZXN0MjE2MzI2MTU4
1,728
Added frozenset as mutli type.
{ "login": "conqp", "id": 3766192, "node_id": "MDQ6VXNlcjM3NjYxOTI=", "avatar_url": "https://avatars.githubusercontent.com/u/3766192?v=4", "gravatar_id": "", "url": "https://api.github.com/users/conqp", "html_url": "https://github.com/conqp", "followers_url": "https://api.github.com/users/conqp/follower...
[]
closed
false
null
[]
null
[ "Cheers cfa2fa5f4f8ef170c802065fece3d828b7b6da24" ]
2018-09-18T14:21:10
2018-09-18T14:46:19
2018-09-18T14:46:18
CONTRIBUTOR
null
Fixes #1727.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1728/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1728/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1728", "html_url": "https://github.com/coleifer/peewee/pull/1728", "diff_url": "https://github.com/coleifer/peewee/pull/1728.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1728.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1727
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1727/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1727/comments
https://api.github.com/repos/coleifer/peewee/issues/1727/events
https://github.com/coleifer/peewee/issues/1727
361,326,560
MDU6SXNzdWUzNjEzMjY1NjA=
1,727
Support frozenset for IN / NOT IN queries
{ "login": "conqp", "id": 3766192, "node_id": "MDQ6VXNlcjM3NjYxOTI=", "avatar_url": "https://avatars.githubusercontent.com/u/3766192?v=4", "gravatar_id": "", "url": "https://api.github.com/users/conqp", "html_url": "https://github.com/conqp", "followers_url": "https://api.github.com/users/conqp/follower...
[]
closed
false
null
[]
null
[ "Fixed: cfa2fa5f4f8ef170c802065fece3d828b7b6da24\r\n\r\nI merged an equivalent patch which also includes tests. I appreciate the ticket and patch." ]
2018-09-18T14:15:54
2018-09-18T14:47:03
2018-09-18T14:46:03
CONTRIBUTOR
null
So, today I encountered, that `frozenset`s seems not to be supported as type for `<<` (`IN`) queries: ``` >>> list(BaseChart.select().join(GroupBaseChart).where((BaseChart.trashed == 0) & (GroupBaseChart.group << frozenset()))) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/us...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1727/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1727/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1726
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1726/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1726/comments
https://api.github.com/repos/coleifer/peewee/issues/1726/events
https://github.com/coleifer/peewee/issues/1726
360,437,680
MDU6SXNzdWUzNjA0Mzc2ODA=
1,726
Cannot have an object initialization on __init__()
{ "login": "GabrielSalla", "id": 15304514, "node_id": "MDQ6VXNlcjE1MzA0NTE0", "avatar_url": "https://avatars.githubusercontent.com/u/15304514?v=4", "gravatar_id": "", "url": "https://api.github.com/users/GabrielSalla", "html_url": "https://github.com/GabrielSalla", "followers_url": "https://api.github.c...
[]
closed
false
null
[]
null
[ "No, I have no plans to add such login in 3.x. You could always make the logger a lazy-loaded property...hell that's probably a lot better anyways, right?\r\n\r\n```\r\n@property\r\ndef _logger(self):\r\n if not hasattr(self, '_logger_obj'):\r\n self._logger_obj = logging.getLogger(...)\r\n return self...
2018-09-14T20:06:41
2018-09-14T21:17:43
2018-09-14T21:04:53
NONE
null
I want to criate a logger object to each one of my objects. In the 2.X versions overriding the `_prepare_instance()` to create the logger would work as in the `__init__()` method the object would not have the information yet. Here's an example: ```python class Alert(BaseModel): id = peewee.PrimaryKeyField()...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1726/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1726/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1725
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1725/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1725/comments
https://api.github.com/repos/coleifer/peewee/issues/1725/events
https://github.com/coleifer/peewee/pull/1725
359,925,485
MDExOlB1bGxSZXF1ZXN0MjE1MzA1ODI0
1,725
Fix example/blog time formatting
{ "login": "Susensio", "id": 11474625, "node_id": "MDQ6VXNlcjExNDc0NjI1", "avatar_url": "https://avatars.githubusercontent.com/u/11474625?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Susensio", "html_url": "https://github.com/Susensio", "followers_url": "https://api.github.com/users/Sus...
[]
closed
false
null
[]
null
[]
2018-09-13T14:37:47
2018-09-13T14:48:34
2018-09-13T14:48:34
CONTRIBUTOR
null
Just a minor bug found testing your blog example, timestamp was printing `YEAR:HOUR`, fixed it to `HOUR:MIN`
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1725/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1725/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1725", "html_url": "https://github.com/coleifer/peewee/pull/1725", "diff_url": "https://github.com/coleifer/peewee/pull/1725.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1725.patch", "merged_at": "2018-09-13T14:48:34" }
https://api.github.com/repos/coleifer/peewee/issues/1724
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1724/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1724/comments
https://api.github.com/repos/coleifer/peewee/issues/1724/events
https://github.com/coleifer/peewee/pull/1724
359,791,849
MDExOlB1bGxSZXF1ZXN0MjE1MjAxNDIw
1,724
Only validate if not backref
{ "login": "Susensio", "id": 11474625, "node_id": "MDQ6VXNlcjExNDc0NjI1", "avatar_url": "https://avatars.githubusercontent.com/u/11474625?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Susensio", "html_url": "https://github.com/Susensio", "followers_url": "https://api.github.com/users/Sus...
[]
closed
false
null
[]
null
[ "Thank you" ]
2018-09-13T08:23:45
2018-09-13T14:27:55
2018-09-13T14:27:49
CONTRIBUTOR
null
This validation was throwing an exception when creating the backref, because it has a through_model and also receives on_delete and on_update values. #1719
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1724/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1724/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1724", "html_url": "https://github.com/coleifer/peewee/pull/1724", "diff_url": "https://github.com/coleifer/peewee/pull/1724.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1724.patch", "merged_at": "2018-09-13T14:27:48" }
https://api.github.com/repos/coleifer/peewee/issues/1723
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1723/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1723/comments
https://api.github.com/repos/coleifer/peewee/issues/1723/events
https://github.com/coleifer/peewee/issues/1723
359,494,859
MDU6SXNzdWUzNTk0OTQ4NTk=
1,723
Peewee throw exception on 2nd time select query
{ "login": "Maheshkumar094", "id": 39484115, "node_id": "MDQ6VXNlcjM5NDg0MTE1", "avatar_url": "https://avatars.githubusercontent.com/u/39484115?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Maheshkumar094", "html_url": "https://github.com/Maheshkumar094", "followers_url": "https://api.gi...
[]
closed
false
null
[]
null
[ "PLEASE FORMAT YOUR CODE.", "Coleifer it is formated in my code base I copy past some part it that why its look unformatted. Ok I will comment code in more formatted way.", "FUCK MAN, CLICK \"Styling with Markdown is supported\" -- it will show you how to highlight your code. There's also a handy \"<>\" toolbar...
2018-09-12T14:00:10
2018-09-12T20:04:53
2018-09-12T18:03:33
NONE
null
``` class Usr(BaseModel): created_at = IntegerField(null=True) created_at1 = DateTimeField(null=True) created_by = IntegerField(null=True) created_by1 = IntegerField(null=True) email = CharField() is_email_verified = BooleanField(null=True) is_test = BooleanField(null=True) last...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1723/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1723/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1722
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1722/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1722/comments
https://api.github.com/repos/coleifer/peewee/issues/1722/events
https://github.com/coleifer/peewee/issues/1722
359,360,213
MDU6SXNzdWUzNTkzNjAyMTM=
1,722
Please support python 3 abstract methods
{ "login": "fluffy-critter", "id": 347162, "node_id": "MDQ6VXNlcjM0NzE2Mg==", "avatar_url": "https://avatars.githubusercontent.com/u/347162?v=4", "gravatar_id": "", "url": "https://api.github.com/users/fluffy-critter", "html_url": "https://github.com/fluffy-critter", "followers_url": "https://api.github...
[]
closed
true
null
[]
null
[ "bro-bro...Python is a dynamic language. Peewee uses this dynamism to provide such nice (if I do say so myself) APIs. There will be no ABCs.", "Hi, I'm rather disappointed in this response for a number of reasons.\r\n\r\nAt the very least I would like to be able to run pylint against peewee without getting a bunc...
2018-09-12T08:02:24
2018-09-12T20:12:11
2018-09-12T13:51:21
NONE
off-topic
Since Python 3.4, there has been a mechanism for declaring abstract base classes and methods thereof, from the [`abc` module](https://docs.python.org/3/library/abc.html). As of Python 3.7, pylint pretty much requires its use; for example, the line: self._query = model.Entry.select().where(self._where) results...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1722/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1722/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1721
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1721/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1721/comments
https://api.github.com/repos/coleifer/peewee/issues/1721/events
https://github.com/coleifer/peewee/issues/1721
359,071,556
MDU6SXNzdWUzNTkwNzE1NTY=
1,721
Slow performance of execute_sql()
{ "login": "ssrebelious", "id": 2326764, "node_id": "MDQ6VXNlcjIzMjY3NjQ=", "avatar_url": "https://avatars.githubusercontent.com/u/2326764?v=4", "gravatar_id": "", "url": "https://api.github.com/users/ssrebelious", "html_url": "https://github.com/ssrebelious", "followers_url": "https://api.github.com/us...
[]
closed
false
null
[]
null
[ "Since you're literally just using `execute_sql()` and not using any of the query-builder APIs, you should note that Peewee is just using `psycopg2` the Python driver.\r\n\r\nI'd suggest that you might raise this issue over on `psycopg2` since I don't think this reflects an actual Peewee performance issue.", "You...
2018-09-11T14:23:43
2018-09-13T13:14:17
2018-09-11T14:33:26
NONE
null
I have a table `Element` in PostgreSQL database that has over 60 000 records in it and I need to perform a full-text-search for the column `name`. ```sql CREATE TABLE public."element" ( id serial NOT NULL, "name" varchar(400) NOT NULL, CONSTRAINT element_pkey PRIMARY KEY (id) ); CREATE INDEX element_name_ts...
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1721/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1721/timeline
null
completed
null
null
https://api.github.com/repos/coleifer/peewee/issues/1720
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1720/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1720/comments
https://api.github.com/repos/coleifer/peewee/issues/1720/events
https://github.com/coleifer/peewee/pull/1720
358,850,003
MDExOlB1bGxSZXF1ZXN0MjE0NDg2MTIy
1,720
Connect to DB only if not connected already
{ "login": "mekanix", "id": 610855, "node_id": "MDQ6VXNlcjYxMDg1NQ==", "avatar_url": "https://avatars.githubusercontent.com/u/610855?v=4", "gravatar_id": "", "url": "https://api.github.com/users/mekanix", "html_url": "https://github.com/mekanix", "followers_url": "https://api.github.com/users/mekanix/fo...
[]
closed
false
null
[]
null
[ "I'll pass, because in my opinion an unclosed connection is a bug and this could lead to sloppy programming. You are welcome to subclass this in your own app and override the method as you like, however.", "Maybe I wasn't clear enough, so I apologize. If you use FlaskDB with `sqlite:///:memory:`, there is no test...
2018-09-11T01:14:15
2018-09-11T14:55:48
2018-09-11T14:00:52
NONE
null
When testing Flask apps, failure is "peewee.OperationalError: Connection already opened." I used the same logic inside connect_db as the one used in close_db.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1720/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1720/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1720", "html_url": "https://github.com/coleifer/peewee/pull/1720", "diff_url": "https://github.com/coleifer/peewee/pull/1720.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1720.patch", "merged_at": null }
https://api.github.com/repos/coleifer/peewee/issues/1719
https://api.github.com/repos/coleifer/peewee
https://api.github.com/repos/coleifer/peewee/issues/1719/labels{/name}
https://api.github.com/repos/coleifer/peewee/issues/1719/comments
https://api.github.com/repos/coleifer/peewee/issues/1719/events
https://github.com/coleifer/peewee/pull/1719
358,663,801
MDExOlB1bGxSZXF1ZXN0MjE0MzQ1MjA4
1,719
Feature/manytomanyfield-ondelete
{ "login": "Susensio", "id": 11474625, "node_id": "MDQ6VXNlcjExNDc0NjI1", "avatar_url": "https://avatars.githubusercontent.com/u/11474625?v=4", "gravatar_id": "", "url": "https://api.github.com/users/Susensio", "html_url": "https://github.com/Susensio", "followers_url": "https://api.github.com/users/Sus...
[]
closed
false
null
[]
null
[ "I've implemented this with additional support for on_update, plus some additional validation. Thanks." ]
2018-09-10T15:00:47
2018-09-10T15:32:19
2018-09-10T15:32:19
CONTRIBUTOR
null
#1718 IDK if I'm creating the pull request correctly. I have run tests and changes do not throw any errors.
{ "url": "https://api.github.com/repos/coleifer/peewee/issues/1719/reactions", "total_count": 0, "+1": 0, "-1": 0, "laugh": 0, "hooray": 0, "confused": 0, "heart": 0, "rocket": 0, "eyes": 0 }
https://api.github.com/repos/coleifer/peewee/issues/1719/timeline
null
null
false
{ "url": "https://api.github.com/repos/coleifer/peewee/pulls/1719", "html_url": "https://github.com/coleifer/peewee/pull/1719", "diff_url": "https://github.com/coleifer/peewee/pull/1719.diff", "patch_url": "https://github.com/coleifer/peewee/pull/1719.patch", "merged_at": null }